Are you using the SkeletonMecanim
component? If you are using SkeletonAnimation
, then you can configure the start time and looping behaviour via the
TrackEntry returned from SetAnimation
or AddAnimation
calls.
For SkeletonMecanim
I'm afraid we are limited to what the Unity Mecanim API provdes us with. Unfortuantely it seems that AnimatorStateInfo.normalizedTime
does incorrectly not account for the cycle offset, it seems to always start from 0.0. Unfortunately there is also no other property available at the AnimatorStateInfo
, so I'm afraid to say that we can't support it with the current behaviour.
Regarding workarounds, nothing that can be tweaked at runtime via code comes to my mind. At edit time you could select the Mecanim Transition in the Animator window and move the second track to the left, effectively setting the Transition Offset
parameter of the Transition to the desired cycle offset. Or obviously modify the animation in the Spine Editor (cycle the keys around) to effectively start at a different time.