Fork me on GitHub
Not signed in (Sign In)

Welcome, Guest

Want to take part in these discussions? Sign in if you have an account, or apply for one below

    • CommentAuthordooley
    • CommentTimeJul 25th 2011
     
    /*Derp*/
    emitter.addAction(new TweenToZone(new RectangleZone(movieclip_mc.x, movieclip_mc.y, movieclip_mc.x+1, movieclip_mc.y+1 )));

    The code validates and everything compiles, music plays, fanfares blare. Nothing moves.
    Do I HAVE to use bitmap data in a tweentozone?
    Do I HAVE to use the tweentozone to have particles move towards a movieclip?
    What if my movieclip animates?

    The system is awesome, and the tutorials are great. Documentation is robust and most appreciated.
    • CommentAuthorRichard
    • CommentTimeJul 31st 2011
     
    You can use any Zone with the TweenToZone action. So using a RectangleZone is fine. However, TweenToZone is linked to the energy of the particle, so you need to set a Lifetime initializer and an Age action on the emitter or the tween won't happen.\

    The tween is based on the zone, and the destination for the tween is set when the particle is created, so it won't update if your movie clip moves.