Paper Flipbook Length

I am currently working on some wall jumping mechanics. I have two different flip-books for the jumping. The first is the character jumping and flipping and the second is just the end frame of the first.

For the jump sequence I am switching to the first jumping flip-book, delaying for the length of that flip-book and then switching to the second flip-book until the player lands.

This is working fine for a normal jump as the first flip-book is playing until the end.

For the wall jumping mechanic, it is possible for the first jumping flip-book to be switched out before it finishes playing. The problem I have is that when I switch back to the first jumping flip-book and get the length, it is coming back with a lower value than expected.

I suspected it was because the flip-book was resuming from it’s last play frame.

I have tried using the play from beginning and set play frame functions with no luck. I still get the same unexpected length back which makes the second jump flip-book switch out to early.

If I manually set the delay to the actual length of the flip-book then it works fine.

Can anyone shed some light on this?