2D Toolkit Forum
2D Toolkit => Support => Topic started by: IndyBonez on April 23, 2015, 09:17:08 pm
-
Hi,
We are looking to implement auto tiling on top of the tile map stuff in 2D toolkit.
We are currently importing TMX maps from the Tiled Map Editor and using auto-tiling in there.
What we also want to support is auto tiling when painting in the 2D Toolkit editor and also auto tiling when modifying the map at run-time (ie mining).
But we are not sure as to where we should be looking within the 2D toolkits source code to implement these features? If you could possibly point us in the right direction that would be great. For example look at file x at line n type suggestions.
Thank you
-
What we also want to support is auto tiling when painting in the 2D Toolkit editor and also auto tiling when modifying the map at run-time (ie mining).
You can modify the tilemap quite easily - tilemap.SetTile(x, y, tileId);
If you're modifying the tilemap at runtime, make sure you're not using physics - its really expensive to regenerate that at runtime. You should either impleemtn your own physics, or recycle physics boxes around the player.