Hi,
it is disappearing because you restart the tween to 0 every 0.01 seconds (the delayedcall).
Here a working code with an endless loop - see the donecall in the second tween:
|
Quellcode
|
1
2
3
4
5
|
<action name="hotspot_animate">
if(hotspot[%1].loaded,
tween(hotspot[%1].alpha, 0.0, 1.0, default, tween(hotspot[%1].alpha, 1.0, 1.0, default, hotspot_animate(%1) ) );
);
</action>
|
First it will tween alpha 0.0, then the second tween will be called where alpha will be tweened to 1.0, and when this is done too - the action itself will be called again and the process starts from the beginning.
And as 'stop action' there is the 'loaded' check around to avoid running that action endless even if the hotspot is already removed.
Best regards,
Klaus