Hi everyone,
I am trying to get a masked object to fade in and out but havent had much luck. It appears that when i set the masked objects alpha to anything above 0 it goes to a full alpha of 1. Any help with this would be great thanks. Here is the code I am using.
Best,
Chris Brasino
[lua]mapLights = display.newImageRect(“images/maps/emap1Lights.png”, 320, 480); – object being masked
mask = graphics.newMask( “images/maps/mask.png” ) – mask
mapLights:setMask( mask )
mapLights.maskScaleX, mapLights.maskScaleY = 10,10
mapLights.alpha = 0; – set the alpha to 0
transition.to(mapLights, {delay = 1000, time = 5000, alpha = 1}) – this should make the map fade in slowly but the instant it becomes active after the delay its alpha goes instantly to 1.
[import]uid: 126017 topic_id: 30709 reply_id: 330709[/import]