Animated Texture Reset

I’m using the AnimatedTextureExtended script on a texture. I’m trying to pause it on the first frame and play it from there OnTriggerEnter.

I’m currently just saying that the var totalcell = 1 until it triggers, then it’s the original totalcell which is 30. Though it does play it, it seems like it’s just playing from a random frame instead of the first one. Can anyone help me with this?

Instead of messing with the timer, you can have

  1. A defaultOffset variable assigned to first frame.
  2. Set it to texture at start
  3. Then play animation OnTriggerEnter.
  4. Once animation is complete set texture back to defaultOffset.

I assume scale is same throughout animation, if not you need defaultscale also.

I solved the problem without tempering with script too much. Apparently, if you just put the fps var on 0 it pauses on the current frame and resumes when returned to the original value.