Closed erik-lance closed 7 months ago
Add a map_data.json under /src/data/.
map_data.json
/src/data/
This will be a json file consisting of all the premade maps that users can play on. Each map will have a string name and int[][] tile to determine its contents. Example:
string name
int[][] tile
[ { "id": 0, "name": "Classic", "tiles": [ [ 0, 1, 0, 0, 2, 0, 0, 1, 0], [ 0, 0, 0, 0, 0, 0, 0, 0, 0], [ 0, 0, 0, 0, 0, 0, 0, 0, 0], [ 0, 0, 0, 0, 0, 0, 0, 0, 0], [ 0, 1, 0, 0, 2, 0, 0, 1, 0], [ 0, 0, 0, 0, 0, 0, 0, 0, 0], [ 0, 0, 0, 0, 0, 0, 0, 0, 0], [ 0, 0, 0, 0, 0, 0, 0, 0, 0], [ 0, 1, 0, 0, 2, 0, 0, 1, 0] ] }, { "id": 1, "name": "Star", "tiles": [ [ 0, 0, 0, 0, 2, 0, 0, 0, 0], [ 0, 1, 0, 0, 0, 0, 0, 1, 0], [ 0, 1, 0, 0, 1, 0, 1, 1, 0], [ 0, 0, 1, 1, 1, 1, 1, 0, 0], [ 0, 1, 1, 1, 2, 1, 1, 1, 0], [ 0, 0, 0, 1, 1, 1, 0, 0, 0], [ 0, 0, 1, 0, 0, 0, 1, 0, 0], [ 0, 1, 0, 0, 0, 0, 0, 1, 0], [ 0, 0, 0, 0, 0, 0, 0, 0, 0] ] }, ]
added in 88529ccfac556e323e6ef40032fb55d3a082337b
Add a
map_data.json
under/src/data/
.This will be a json file consisting of all the premade maps that users can play on. Each map will have a
string name
andint[][] tile
to determine its contents. Example: