Here's my new code:<div><br></div><div><div>__sequence.addStep(new HydroTween(this, { func:functionOne, args:[whatever] }, 0, 0, null, null, null, null, null, null, null, false ));<br></div><div>__sequence.addStep(new HydroTween(this, { func:functionTwo }, 0, 0, null, null, null, null, null, null, null, false ));<br>
</div><div>__sequence.addStep(new HydroTween(__fader, { start_alpha:1, alpha:0, duration:__duration_fade }, 0, 0, null, null, null, null, null, null, null, false ));<br></div><div>__sequence.addStep(new HydroTween(this, { delay:Number(properties.@timeout) || __duration_timeout, func:trace, args:['timeout triggered'] }, 0, 0, null, null, null, null, null, null, null, false ));<br>
</div><div><br></div><div>I changed the nulls to point to "this", as well as the "false" in the end of each addStep() call, but I got the same results as before. The __fader Sprite did not work before or after the change, BTW.</div>
<div>Hope that helps,<br></div><div><br></div>Bernardo Kuri<br>
<br><br><div class="gmail_quote">On Thu, Feb 12, 2009 at 4:36 PM, Donovan Adams <span dir="ltr"><<a href="mailto:donovan@hydrotik.com">donovan@hydrotik.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Possible that since you are adding HydroTween instances with a null target<br>
the tweens aren't working properly.<br>
<br>
I'm assuming the __fader is tweening fine though? Make sure you are adding<br>
the argument to disable the GC. was in the last snippet I sent. Looks like<br>
it got omitted in the code you sent.<br>
<br>
Still trying to figure out what's going on and it looks like a couple of<br>
things.<br>
<br>
The optimization of HydroTween for Garbage Collection is creating the issue<br>
with HydroSequence when sequences need to be reused. Just needs a little<br>
hashing out.<br>
<div class="Ih2E3d"><br>
<br>
<br>
<br>
<br>
<br>
<br>
-------- Original Message --------<br>
> From: "Bernardo Kuri" <<a href="mailto:support@bernardokuri.com">support@bernardokuri.com</a>><br>
</div><div class="Ih2E3d">> Sent: Thursday, February 12, 2009 10:24 AM<br>
> To: "Mailing list for the Go ActionScript Animation Platform"<br>
</div><div class="Ih2E3d"><<a href="mailto:golist@goasap.org">golist@goasap.org</a>><br>
> Subject: Re: [Golist] HydroSequence Looping Issue<br>
><br>
</div><div><div></div><div class="Wj3C7c">> Thanks for the suggestion, Donovan.I had to modify your example to fit<br>
my<br>
> code, and this is what i came up with:<br>
><br>
> // start code<br>
> __sequence = new Sequence();<br>
> __sequence.addEventListener("START", onSeqEvent, false, 0, true);<br>
> __sequence.addEventListener("CYCLE", onSeqEvent, false, 0, true);<br>
> __sequence.repeater.cycles = Repeater.INFINITE;<br>
><br>
> // The following code resides in another function. As you can see, the<br>
> sequence needs to be dynamically created:<br>
><br>
> __sequence.addStep(new HydroTween(null, { func:functionOne,<br>
args:[whatever]<br>
> } ));<br>
> __sequence.addStep(new HydroTween(null, { func:functionTwo } ));<br>
> __sequence.addStep(new HydroTween(__fader, { start_alpha:1, alpha:0,<br>
> duration:__duration_fade } ));<br>
> __sequence.addStep(new HydroTween(null, {<br>
delay:Number(properties.@timeout)<br>
> || __duration_timeout, func:trace, args:['timeout triggered'] } ));<br>
> __sequence.start();<br>
> // end code<br>
><br>
> The weird thing is that none of the events are being dispatched at all.<br>
On<br>
> top of that, my "timeout triggered" trace is not showing on my output<br>
> anymore.<br>
> Is there anything else I can try?<br>
><br>
> Thanks a bunch,<br>
><br>
> Bernardo Kuri<br>
><br>
><br>
> On Thu, Feb 12, 2009 at 1:45 PM, Donovan Adams <<a href="mailto:donovan@hydrotik.com">donovan@hydrotik.com</a>><br>
wrote:<br>
><br>
> > It seems there is an issue with the autoGC feature and passing a param<br>
into<br>
> > HydroSequence.<br>
> ><br>
> > The reason it's not repeating is that HydroTween is clearing out the<br>
memory<br>
> > of the tweens in a sequence.<br>
> ><br>
> > I will have to delve into this a bit deeper, but in the meantime y ou<br>
might<br>
> > consider using this as an option?<br>
> ><br>
> > var ht1:HydroTween = new HydroTween(target, {x:300}, 1, 0,<br>
> > Quadratic.easeOut, null, null, null, null, null, null, false);<br>
> > var ht2:HydroTween = new HydroTween(target, {x:100}, 1, 0,<br>
> > Quadratic.easeOut, null, null, null, null, null, null, false);<br>
> ><br>
> > var seq:Sequence = new Sequence(ht1, ht2);<br>
> > seq.repeater.cycles = Repeater.INFINITE;<br>
> > seq.start();<br>
> ><br>
> > -------- Original Message --------<br>
> > > From: "Bernardo Kuri" <<a href="mailto:support@bernardokuri.com">support@bernardokuri.com</a>><br>
> > > Sent: Thursday, February 12, 2009 6:58 AM<br>
> > > To: <a href="mailto:golist@goasap.org">golist@goasap.org</a><br>
> > > Subject: [Golist] HydroSequence Looping Issue<br>
> > ><br>
> > > Hello fellow GoList members,<br>
> > > I would really appreciate it if someone can help me out with this<br>
issue.<br>
> > My<br>
> > > project will be ready to launch as soon as this is fixed.<br>
> > ><br>
> > > I am having an issue with a HydroSequence instance that I need to<br>
loop<br>
> > > indefinitely. As far as I understand it, a HydroSequence class<br>
instance<br>
> > > has a public property called "repeater" that needs to be set to<br>
> > > Repeater.INFINITE in order to accomplish infinite looping. The<br>
problem<br>
> > is<br>
> > > that it's<br>
> > > not actually doing that at all. I tried adding a listener for the<br>
> > "CYCLE"<br>
> > > event, but that doesn't get triggered either.<br>
> > ><br>
> > > Here's the relevant portion of the code:<br>
> > ><br>
> > > --------------------------------------<br>
> > ><br>
> > > import com.hydrotik.go.HydroSequence;<br>
> > > import org.goasap.managers.Repeater;<br>
> > ><br>
> > > __sequence = new HydroSequence();<br>
> > > __sequence.repeater.cycles = Repeater.INFINITE;<br>
> > ><br>
> > > __sequence.addItem( { func:firstFunction, args:[whatever] } );<br>
> > > __sequence.addItem( { func:secondFunction } );<br>
> > > __sequence.addItem( { target:__fader, start_alpha:1, alpha:0,<br>
> > > duration:__duration_fade } );<br>
> > > __sequence.addItem( { delay:Number(properties.@timeout) ||<br>
> > > __duration_timeout, func:trace, args:['timeout triggered']} );<br>
> > ><br>
> > > __sequence.start();<br>
> > ><br>
> > > --------------------------------------<br>
> > ><br>
> > > If I execute the above and look at the output, "timeout triggered"<br>
will<br>
> > show<br>
> > > only once, which is obviously not what I need.<br>
> > ><br>
> > > I have even tried adding another step to the sequence that basically<br>
> > calls<br>
> > > __sequence.start(), like so:<br>
> > ><br>
> > > __sequence.addItem( { taget:__sequence func:start } );<br>
> > ><br>
> > > ... but that did absolutely nothing.<br>
> > ><br>
> > > Am I missing something here? I really can't seem to get it to work<br>
> > > correctly.<br>
> > > Thanks for your time guys!<br>
> > ><br>
> > > Bernardo Kuri<br>
> > ><br>
> > > _______________________________________________<br>
> > > GoList mailing list<br>
> > > <a href="mailto:GoList@goasap.org">GoList@goasap.org</a><br>
> > > <a href="http://goasap.org/mailman/listinfo/golist_goasap.org" target="_blank">http://goasap.org/mailman/listinfo/golist_goasap.org</a><br>
> ><br>
> ><br>
> ><br>
> > _______________________________________________<br>
> > GoList mailing list<br>
> > <a href="mailto:GoList@goasap.org">GoList@goasap.org</a><br>
> > <a href="http://goasap.org/mailman/listinfo/golist_goasap.org" target="_blank">http://goasap.org/mailman/listinfo/golist_goasap.org</a><br>
> ><br>
><br>
> _______________________________________________<br>
> GoList mailing list<br>
> <a href="mailto:GoList@goasap.org">GoList@goasap.org</a><br>
> <a href="http://goasap.org/mailman/listinfo/golist_goasap.org" target="_blank">http://goasap.org/mailman/listinfo/golist_goasap.org</a><br>
<br>
<br>
<br>
_______________________________________________<br>
GoList mailing list<br>
<a href="mailto:GoList@goasap.org">GoList@goasap.org</a><br>
<a href="http://goasap.org/mailman/listinfo/golist_goasap.org" target="_blank">http://goasap.org/mailman/listinfo/golist_goasap.org</a><br>
</div></div></blockquote></div><br></div>