tilegame / TileExperiments

experiments with tiling systems for web games.
https://tilegame.github.io/TileExperiments/
0 stars 0 forks source link

improve json #3

Closed fractalbach closed 6 years ago

fractalbach commented 6 years ago

change the way layers are defined. Shouldn't be an array, should be a named object like "ground" or "above Player". Something flexible.

before:

{ 
  "data": [ [[1]], [[2]] ] 
}

after:

{ 
   "data": { "ground": [[1]], "above": [[2]] } 
}

Then, fix it in the way it's decoded.

fractalbach commented 6 years ago

closing for now because this isn't necessarily better, and it works fine right now.