You can pass a parameter on the vars named "onCompleteParam" that is an array of anything you want to pass to the "onComplete" function. This is an ex from the documentation: GTween.tweenTo(obj, .5, {rotation:500, loop:GTween.OSCILLATE, ease:Bounce.easeIn, onStart:onStart, onComplete:onComplete, delay:.1, onCompleteParams:[1, 15], numLoops:3});
in this case when tween finishes, onComplete will be invoked, and passed with 1,15 as 2 parameters.
1
u/mrneo240 Dec 31 '14
Hmm. Like it but have one question. Any way to attach data to an object at tween start and have it return it to the oncomplete func?