An AnimationGroup is how various animations are actually applied to a region; this is how different behaviors can be run in sequence or in parallel with each other, automatically. When you pause an AnimationGroup, it tracks which of its child animations were playing and how far advanced they were, and resumes them from that point.
An Animation in a group has an order from 1 to 100, which determines when it plays; once all animations with order 1 have completed, including any delays, the AnimationGroup starts all animations with order 2.
An AnimationGroup can also be set to loop, either repeating from the beginning or playing backward back to the beginning. An AnimationGroup has an OnLoop handler that allows you to call your own code back whenever a loop completes. The :Finish()
method stops the animation after the current loop has completed, rather than immediately.
Defined Methods
- AnimationGroup:GetIgnoreFramerateThrottle() - This function is not yet documented
- AnimationGroup:IsForbidden() - This function is not yet documented
- AnimationGroup:IsSetToFinalAlpha() - This function is not yet documented
- AnimationGroup:SetIgnoreFramerateThrottle() - This function is not yet documented
- AnimationGroup:SetToFinalAlpha() - This function is not yet documented
- AnimationGroup:Stop() - Stops animation of the group
Inherited Methods
- name = AnimationGroup:GetName() - Returns the widget object's name
- type = AnimationGroup:GetObjectType() - Returns the object's widget type
- parent = AnimationGroup:GetParent() - Returns the object's parent object
- handler = AnimationGroup:GetScript("scriptType") - Returns the widget's handler function for a script
- hasScript = AnimationGroup:HasScript("scriptType") - Returns whether the widget supports a script handler
- AnimationGroup:HookScript("scriptType", handler) - Securely hooks a script handler
- isType = AnimationGroup:IsObjectType("type") - Returns whether the object belongs to a given widget type
- AnimationGroup:SetScript("scriptType", handler) - Sets the widget's handler function for a script
Script Handlers
- OnFinished(self, requested) - Run when the animation (or animation group) finishes animating
- OnLoad(self) - Run when the frame is created
- OnLoop(self, "loopState") - Run when the animation group's loop state changes
- OnPause(self) - Run when the animation (or animation group) is paused
- OnPlay(self) - Run when the animation (or animation group) begins to play
- OnStop(self, requested) - Run when the animation (or animation group) is stopped
- OnUpdate(self, elapsed) - Run each time the screen is drawn by the game engine