My plan is to have a 9Patch rectangle draw over a Tilemap, and when I release the mouse, all tiles below the 9Patch will change to a different tile in the Tilemap.
Is this possible, or do the two Objects not interact with each other in this way ?
You can use "Set tile range" in Tilemap object to do what you want and then use 9patch to only visualize area of selection.
That's what I'm doing, but I can't set each Tilemap tile under the 9patch.
I was hoping I could do 'For each tilemap tile under 9patch, set tile to 2'
9patchTileselection.capx
"Set tile range" is a bit confusing at start. Because Tile X and Tile Y are index numbers of tiles (not XY position coordinates) and Width and Height are the same - how many tiles horizontally and vertically you want to affect (not pixels).
Develop games in your browser. Powerful, performant & highly capable.
That's it !!! Thank you, I'm still new to Tilemaps and this was a massive help !
\I've adapted the CAPX that you have made, and now I'm trying to get it to sense if there is a tile already there, on the bottom tilemap, and if it does sense one, then to leave that spot blank on the top tilemap.
So far I have this, dl.dropboxusercontent.com/u/108799982/Capx%20Demos/OverlappingTilemaps.capx , but I'm afraid it's not working. Would you be able to give me one last assist ? <img src="smileys/smiley1.gif" border="0" align="middle" />
Is this what you want?
OverlappingTilemaps2.capx
Its erasing all tiles from Tilemap2 if they have same XY position as Tilemap1 - so you can make Tilemap2 tiles only on blank spaces of tilemap1.
Indeed it is, you sir are a genius <img src="smileys/smiley20.gif" border="0" align="middle" />