i am struggling on something i’d think would be pretty simple. i want to do something like:
SomeEntity.prototype.speed = 0;
SomeEntity.prototype.tween = null;
SomeEntity.prototype.setSpeed(speed, duration){
if(this.tween != null){
this.tween.stop();
}
this.tween = this.entity.tween(this.speed).to(speed, duration, pc.SineOut).start();
}
i am using playcanvas-tween and can’t figure out how to do this without boxing the values in an object as described on the manual page. please advise