Hi Guys,
I have just passed through this topic and saw that after so many years, no one replied. The answer is pretty simple.
-
In the material, multiply the number of rows by the number of columns and subtract the value of empty spaces.
-
Next, divide the result by the total number slots in your image. That will return you the percentage at which the animation ends in a normalized range of 0-1.
-
Get a time node and connect the ‘frac’ node to it. It will make sure that time loops only from 0-1.
-
At last, multiply your result from step 2 with the ‘frac’ node and connect to the animation phase in the flipbook. This result will loop from 0 to the last frame of the animation.
Below is the image showing how I made it UE5.