Hi Spine Forums - Newish to Spine and have a question regarding the Starling Runtime:
What is the best way to set both the timeScale and the eventThreshold of an animation - at the same moment?
Currently I have:
- SkeletonAnimation.state.setAnimationByName(0,"MyAnimtaion1",false).timeScale = 2;
- SkeletonAnimation.state.addAnimationByName(0,"MyAnimtaion2",false,1).timeScale = 1;
However, if I want to adjust the eventThreshold for "MyAnimtaion1", I can not do:
- SkeletonAnimation.state.setAnimationByName(0,"MyAnimtaion1",false).timeScale = 2;
- SkeletonAnimation.state.setAnimationByName(0,"MyAnimtaion1",false).eventThreshold = 1;
- SkeletonAnimation.state.aaddAnimationByName(0,"MyAnimtaion2",false,1).timeScale = 1;
because the 2nd 'setAnimationByName' wipes the 1st. And if I use an 'addAnimationsByName' then I just get another animation added.
I have looked at:
- SkeletonAnimation.timeScale = .5;
but that seems to globally takeover for all the animations.
Any insight is apprecieated. ChzBoi