Hey there Zeh!

On Tue, Mar 4, 2008 at 12:18 PM, Zeh Fernando <[EMAIL PROTECTED]>
wrote:

>
> Hm.. that's a good question. It runs functions inside of the instance
> using .apply, but if you pass the super.load without wrapping it, I'm
> sure exactly how the function reference is handled by actionscript.
>

Yeah, I've looked at Tweener's code, even tried to tweak a little bit to see
if I could get through it, then I realized it's not Tweener's fault.
By issuing a:
trace(tScope);
on line 754, right before:
tTweening.onComplete.apply(tScope, tTweening.onCompleteParams);
it traces my current instance correctly.


>
> Anyway, have you tried this instead?
>
> public function load():Void {
>    var obj:Object = new Object({
>       _y: 200,
>       time: 1,
>        onComplete: function() { super.load(); }
>    });
>    Tweener.addTween(this, obj);
> }
>

Yes, I tried that. Just tried again right now to make sure I wasn't missing
anything ;)
Still, no success...

I've just pasted the code from the superclass inside the onComplete handler
(it's just a event dispatch anyway, works for now), but I really hate myself
for doing this, specially because this is a refactoring of some old crappy
code, and it's supposed to be made the right way.
Anyway, still trying to come up with something. (Boy, I really wish the boss
would let me use AS3 already, I'm sure these things wouldn't happen. AS2
really isn't made to serious programming)

Thanks for the help so far, Zeh! Valeu!

--
Wagner Amaral
AgĂȘncia Ginga - Brazil
www.agenciaginga.com.br
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to