As a further example:
Let's say I want to build two tiles next one another, but I only build the first one, and write a loop to find the first tile and then build a second tile to the right of the first tile's location.
I can do this manually by saying:
tileMap.SetTile(0, 0, layer, tileID); // Build a tile in the bottom left of the tilemap, at the 0,0 location
tileMap.SetTile(1, 0, layer, tileID); //Build a tile to the right of the first tile
However, if I wanted to find the first tile and then get it's X and Y in the TILEMAP not in the worldspace, I cannot find a way to do that. I want to return 0,0 for the first tile, then say something like:
tileMap.SetTile(firstTile.x + 1, 0, layer, tileID);
Does that make more sense?
Thank you,
Mike