ModEnc is currently in Maintenance Mode: Changes could occur at any given moment, without advance warning.

Animation Looping

From ModEnc
Revision as of 13:07, 8 March 2019 by E1 Elite (talk | contribs) (Corrected. The example was wrong on the usage of End, so the example section is removed.)
Jump to navigation Jump to search

Here is the animation looping control flag descriptions. The loop control allows to set start/end frames for the first iteration of the loop and start/end frames for all other iterations in the loop.

  • Start defines a 0-based index of the first frame to play on the first iteration. Start is used for first iteration irrespective of the number of total iterations defined for this animation. Start defaults to 0 if not defined.
  • End defines the number of frames to play for the first iteration. End is only used if the total number of iteration is 1, which happens when LoopCount is not defined or LoopCount=1. If the total number of iterations is more than 1, then End value is disregarded and instead LoopEnd is used. If End is not given or if it has a larger number than existing frames, the first iteration will end anyway with the last frame of the SHP (it could be the shadow frames as well unless Shadow=yes is set in RA2/YR making it to end with the last normal frame).
  • LoopStart defines a 0-based index of the first frame for loop iterations.
  • LoopEnd defines a 1-based index of the last frame when total number of iterations is more than one.
  • LoopCount defines the total amount of iterations to play. Value 1 is for a single iteration where the Start and End values are used instead of LoopStart and LoopEnd. Value -1 is used for infinite loop.