Translation is an Animation type that applies an affine translation to its affected region automatically as it progresses. You can set the offset in both the X and Y dimensions. Translations can be applied normally to both Textures and FontStrings.
Defined Methods
- xOffset, yOffset = Translation:GetOffset() - Returns the animation's translation offsets
- Translation:SetOffset(xOffset, yOffset) - Sets the animation's translation offsets
Inherited Methods
- duration = Translation:GetDuration() - Returns the time for the animation to progress from start to finish
- elapsed = Translation:GetElapsed() - Returns the amount of time since the animation began playing
- delay = Translation:GetEndDelay() - Returns the amount of time the animation delays after finishing
- framerate = Translation:GetMaxFramerate() - Returns the maximum number of times per second that the animation will update its progress
- name = Translation:GetName() - Returns the widget object's name
- type = Translation:GetObjectType() - Returns the object's widget type
- order = Translation:GetOrder() - Returns the order of the animation within its parent group
- parent = Translation:GetParent() - Returns the object's parent object
- progress = Translation:GetProgress() - Returns the progress of an animation, ignoring smoothing effects
- progress = Translation:GetProgressWithDelay() - Returns the progress of the animation and associated delays
- region = Translation:GetRegionParent() - Returns the `Region` object on which the animation operates
- handler = Translation:GetScript("scriptType") - Returns the widget's handler function for a script
- progress = Translation:GetSmoothProgress() - Returns the progress of the animation (ignoring start and end delay)
- smoothType = Translation:GetSmoothing() - Returns the smoothing type for the animation
- delay = Translation:GetStartDelay() - Returns the amount of time the animation delays before its progress begins
- hasScript = Translation:HasScript("scriptType") - Returns whether the widget supports a script handler
- Translation:HookScript("scriptType", handler) - Securely hooks a script handler
- delaying = Translation:IsDelaying() - Returns whether the animation is currently in the middle of a start or end delay
- done = Translation:IsDone() - Returns whether the animation has finished playing
- isType = Translation:IsObjectType("type") - Returns whether the object belongs to a given widget type
- paused = Translation:IsPaused() - Returns whether the animation is currently paused
- playing = Translation:IsPlaying() - Returns whether the animation is currently playing
- stopped = Translation:IsStopped() - Returns whether the animation is currently stopped
- Translation:Pause() - Pauses the animation
- Translation:Play() - Plays the animation
- Translation:SetDuration(duration) - Sets the time for the animation to progress from start to finish
- Translation:SetEndDelay(delay) - Sets the amount of time for the animation to delay after finishing
- Translation:SetMaxFramerate(framerate) - Sets the maximum number of times per second for the animation to update its progress
- Translation:SetOrder(order) - Sets the order for the animation to play within its parent group
- Translation:SetParent(animGroup) or Translation:SetParent("animGroupName") - Sets the parent for the animation
- Translation:SetScript("scriptType", handler) - Sets the widget's handler function for a script
- Translation:SetSmoothProgress() - This function is not yet documented
- Translation:SetSmoothing("smoothType") - Sets the smoothing type for the animation
- Translation:SetStartDelay(delay) - Sets the amount of time for the animation to delay before its progress begins
- Translation:Stop() - Stops the animation
Script Handlers
- OnEvent(self, "event", ...) - Run whenever an [[docs/events|event]] fires for which the frame is registered
- OnFinished(self, requested) - Run when the animation (or animation group) finishes animating
- OnLoad(self) - Run when the frame is created
- 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