2D Toolkit Forum
2D Toolkit => Support => Topic started by: Gluklichman on August 25, 2013, 12:38:32 pm
-
In my solution I use tk2dTileMap. To change parts of map during the game I use :
_tilemap.BeginEditMode();
//do something
_tilemap.EndEditMode();
While I`m in editor, everything is ok. But when i try to build my solution, building fails with error:
error CS1061: Type `tk2dTileMap' does not contain a definition for `BeginEditMode' and no extension method `BeginEditMode' of type `tk2dTileMap' could be found
Unity version: 4.0
tk2dVersion: 2.1
What is wrong?
-
Why are you calling BeginEditMode? You don't need to.
Simply call tileMap.SetTile( xxx );
then tileMap.Build() to refresh the data.
-
Thanks for your help. Now everything is good.