Adding tile info to tilemaps?

0 favourites
  • 1 posts
From the Asset Store
Kids Game
$49 USD
New Sounds Added Update: 115 new sound effects added for no additional cost!
  • I've got a quick question for everyone using tilemaps. It seems that Tilemap is primarily concerned with the rendering aspect of a map. What is everyone doing to encode additional information on a tile by tile basis? Example, let's say you wanted a property called "IsBurning" on any tile position. Eg, Tile ID 1 at position (5, 8) is burning, all other tiles of ID 1 IsBurning is set to false. So each instance of a tile in the map would have a set of properties.

    The only thing I can think is that I'll need to create a separate 2d TileProperties array with each value set as a lookup for the UID of a TileDictionary for all the properties. I could also optionally use string concatenation in order to use a single dictionary, so something like:

    TileDictionary["Tile_" & TileX & "_" & TileY & "_" & PropertyName] = Value

    That would let me avoid having to create an array.

    Thoughts?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)