Hi,
I want to create level editor with tilemap
I want to do loop / foreach for all of “tree” icon (tile)
like this:
forEach(tilemap as tile){
if(tile.name == “tree”){
create_actual_tree(tile.x, tile.y);
}
}
how to do this ?
Hi,
I want to create level editor with tilemap
I want to do loop / foreach for all of “tree” icon (tile)
like this:
forEach(tilemap as tile){
if(tile.name == “tree”){
create_actual_tree(tile.x, tile.y);
}
}
how to do this ?
This question will be immediately answered for you by either working through a few “how to change Tiles in a Tilemap” or even just basic Tile / Tilemap tutorials. It’s right there in the API, exactly how to get the tile coordinates and read/write the Tile.
Just wanted to add on Kurt’s good advice to get you started, you can refer to the Tilemap API for you to have an idea what you can do with them