Closed chimaira closed 10 years ago
Hi again, Sory I solved this by calling the same function within the tween onComplete
function fly(max, min) {
var cx = Math.floor(Math.random() * (max - min) + min);
var cy = Math.floor(Math.random() * (max - min) + min);
var tmpTween = new TWEEN.Tween(scope.target)
.to({x: cx, y: cy}, 2000)
.easing(TWEEN.Easing.Linear.None)
.start()
.onComplete(function () {
scope.fly(10,0);
});
// ....//
};
Yeah that's one option, there's nothing built-in. Closing as resolved!
Hi , Sorry , it probably not an issue, but I did not find any way for my animation case .
Here is it, I started a single tween with an infinity repeat.
In this aimation I want the 'nx' and 'ny' values to be randomized on every tween recall, in other words I want passing expressions instead of fixed values.
How to perform that ?
Thank you.