I’ve got a method that creates a new tile:
local newTile = map:createTileAt(waterGID, floodCells[i].layer, floodCells[i].position) --floodCells[i].position)
–dump(newTile)
newTile:build()
local newProperty = Property:new(“flooded”, “true”)
newTile:addProperty(newProperty)
local tileSprite = newTile:getVisual()
tileSprite.alpha = 0
newTile:show()
–dump(newTile)
newTile:fadeToPosition(localX-32, localY-64, 2500, 0, onWaterFlowComplete)
in the method onWaterFlowComplete I can call map:getTilesWithProperty(“flooded”) and get the expected tile(s) back.
However, on the next mapTouch event when I make the same call
map:getTilesWithProperty(“flooded”) I get back nothing.
I’ve banged around with this most of the day and can’t seem to make any sense of it. Tried not using fade, etc., nothing seemed help.
Any suggestions would be appreciated. [import]uid: 133637 topic_id: 25665 reply_id: 325665[/import]