- Home /
Driving 4.3 Animator with custom playback speed
I'm implementing a replay system in my game. Originally I was going to ignore animations and let them update with the state of my game's models, both during recording and playback. But, the animator in 4.3 has some really nice features. One thing I want to use it for is synching collision volumes to the frames of my game's sprites. It's much easier to use the Animation editor, than to do this by hand in code.
To continue with that, I'll need to update animations based on the playback speed, which was recorded previously. I was unsuccessful in modifying the Animator.speed to get consistent results. I've found the property Animator.playbackTime, but I don't know how to use it. When trying to set it, I get a warning that says "Can't playback from recorder, no recorded data found" My theory is that I should be able to update that playbackTime by incrementing it with my recorded delta time and have the animations play synched up to my playback. Any thoughts on this?