os.startFormAnimation() is a function that is used to cause a bot to play a given animation (usually one attached to its mesh). It accepts an options object that can control how the animation is played.
One option is initialTime, which specifies the time that the the animation clip will start at. It is able to be used to start an animation in the middle of the animation clip. Another option is timeScale, which controls the speed that the animation plays at. Values < 1 play slower than normal, while values > 1 play faster than normal. 0 means that the animation is supposed to appear paused.
However, when timeScale is set to 0, the initialTime option does not work. Calling os.startFormAnimation() with both timeScale set to 0 and initialTime > 0 causes the bot to appear paused at the start of its animation instead of at the position that was specified.
Click and drag on the purple bot. As you drag the bot, you should see the fox frozen in place. This is wrong. Instead, the fox should progress through the animation the further you drag away from the purple bot.
Edit the @onDragging script on the purple bot and set timeScale to 1. Now drag the purple bot. Notice how the fox animates based on where you drag. This is how it should work, except that when you release the mouse the fox should be frozen in place instead of continuing to play the animation.
os.startFormAnimation()
is a function that is used to cause a bot to play a given animation (usually one attached to its mesh). It accepts an options object that can control how the animation is played.One option is
initialTime
, which specifies the time that the the animation clip will start at. It is able to be used to start an animation in the middle of the animation clip. Another option istimeScale
, which controls the speed that the animation plays at. Values < 1 play slower than normal, while values > 1 play faster than normal. 0 means that the animation is supposed to appear paused.However, when
timeScale
is set to 0, theinitialTime
option does not work. Callingos.startFormAnimation()
with bothtimeScale
set to 0 andinitialTime
> 0 causes the bot to appear paused at the start of its animation instead of at the position that was specified.Steps to reproduce:
@onDragging
script on the purple bot and settimeScale
to 1. Now drag the purple bot. Notice how the fox animates based on where you drag. This is how it should work, except that when you release the mouse the fox should be frozen in place instead of continuing to play the animation.