Create A New Tile with New Property, but unable to get tile back from Map.

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]

Hi,

My guess is you’re experiencing a bug in Lime. Take a look at this link to see if that might help you:

http://developer.anscamobile.com/forum/2011/08/27/moving-tile-leaves-tile-values-detection-behind

If you are using v.3.4 you might want to visit Lime’s members area to download the latest Beta where some of these issues have been dealt with. [import]uid: 129287 topic_id: 25665 reply_id: 104405[/import]

Thanks for the response. I had read through that post and a few others, but digging into Lime I couldn’t nail down the cause. In the end it appeared to be related to the fact that I was creating a new tile and moving it (slightly) via transition.to().

I downloaded 3.5 beta and merged the setImage fix into 3.4 and that solved my problem.

[import]uid: 133637 topic_id: 25665 reply_id: 104407[/import]