MotionX V1.0.5

MotionX

Extensible Animation Manager for Roblox -- Anything about animations, in one place.

Animation Registration

Register and play animations by name with customizable priorities

Playback Control

Pause, resume, and stop animations with dynamic speed adjustment

State Tracking

Track currently playing or paused animations with built-in status methods

What is MotionX?

MotionX is an extensible animation manager built for clean, efficient control of character animations in Roblox. It simplifies animation workflows with a clear API and built-in state handling.

Installation

Roblox Installation

You can download MotionX from this [link]

After downloading, drag the Module into Replicated Storage


Rojo/Wally Installation

To install MotionX Using Wally you have to add MotionX to your dependencies list inside your wally.toml file.

And then you can require it just any other module from wally.

Wally Package: [link]

Getting Started

Creating a new Instance


After downloading MotionX, let's initialize it so it's ready to use.

To use MotionX, you first need to create an instance and connect it to your character. Here's how:


Start by requiring MotionX

 
local MotionX = require(path.to.MotionX)

The .new() method creates a new MotionX Controller for your character.


After requiring MotionX, we can use .new() to crate a new instance. Before that, make sure you have a character already.

 
local Players = game:GetService("Players")
local player = Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()

local characterAnimator = MotionX.new(character)
warning Warning

Your character must include an Animator , or MotionX will not be able to play animations.


If you need to get a MotionX Instance from another script, you can use .Get() to get the instance.

 
--animation script
local characterAnimator = MotionX.new(character)
--other script
local animator = MotionX.Get(character)

Registering an animation


Now we can start registering animations, to register a new animation we can use the :RegisterNew() method.

 
local characterAnimator = MotionX.new(character)

characterAnimator:RegisterNew("Jump", 1234567890, Enum.AnimationPriority.Movement)
info Info

Look at :RegisterNew() to view the method more in depth.


Playing & Stopping an animation


To play an animation use the :Play() method.

 
characterAnimator:Play("Jump")

This plays the "Jump" animation once. If you want it to loop, simply pass true as the second argument:

 
characterAnimator:Play("Jump", true) -- loops the animation

Stopping an animation

To stop an animation use the :Stop() method.

 
characterAnimator:Stop("Jump")

Stopping & Resuming an animation


To pause an animation use the :Pause() method.

 
characterAnimator:Pause("Jump")

To resume an animation use the :Resume() method.

 
characterAnimator:Resume("Jump")

lightbulb Tip

You can also call :Play() to resume your animation!


Setting the speed of an Animation


To set the speed of an animation use the :SetSpeed() method.

 
characterAnimator:SetSpeed("Jump", 0.3)

Stopping all animations, Unregistering an animation and cleanup


Stopping all animations

To stop all animations use the :StopAll() method.

 
characterAnimator:StopAll()

This will stop all currently running animations.

If you want to only stop animations from one group, you can pass the group name as the first paramater.


Unregistering Animations

To un-register an animation use the :Remove() method.

 
characterAnimator:Remove("Jump")

This will un-register the animation.


Cleanup

To remove the entire MotionX Instance entirely use the :Destroy() method.

 
characterAnimator:Destroy()

isPlaying(), isPaused(), GetPlaying(), GetGroup()


All of these methods basically do the same things, they either return true or false depending on the current state

 
--Example usage:
characterAnimator:isPlaying("Jump") -- returns true if is playing, returns fale is isn't playing

On the other hand, for GetPlaying() and GetGroup():

GetPlaying - It returns a table with the names of the animations.

 
--Example usage:
characterAnimator:GetPlaying() -- returns a table with all names of the animations.

GetGroup - It returns the group name of an animation.

 
--Example usage:
characterAnimator:GetGroup("Jump") -- returns the group name (Default is Global).

Binding Markers


To bind a marker or multiple markers use the :BindMarkers() method.

 
characterAnimator:BindMarkers("Jump", {
	land = function()
		print("Landed!")
	end,
})

Getting all animations


If you want to get all currently registered animations, you will have to use :GetAllAnimations()

Optionally, you can pass a Group as the first paramater and it will return all animations in that group.


local globalAnimations = characterAnimator:GetAllAnimations()
local movementAnimations = characterAnimator:GetAllAnimations("Movement")
print(globalAnimations) -- will print all animations
print(movementAnimations) -- will print all movement animations

API Reference

.new() [Constructor] [Static]


Creates a new instance of MotionX.

Paramaters

character Model The character/rig of what you want to animate.

.Get() [Instance] [Read Only]


Returns the constructor of a character.

Paramaters

character Model The character/rig

Returns

Returns the MotionX Instance.

:RegisterNew() [Instance]


Register a new animation.

Paramaters

name string The name of the animation (cannot duplicate!).
animationId number The assetId of the animation.
priority Enum.AnimationPriority The priority of the animation (Default is Action). [Optional]
group string The name of a group (Default is Global). [Optional]

:Remove() [Instance]


Remove an animation.

Paramaters

name string The name of the animation.

:Play() [Instance]


Play/Resume an animation.

Paramaters

name string The name of the animation.
looped boolean If you want the animation to be looped. [Optional]
fadeTime number The fade-in time. [Optional]

:Stop() [Instance]


Stop an animation.

Paramaters

name string The name of the animation.

:StopAll() [Instance]


Stops all animations.

Paramaters

group string The name of the group you want to stop all animations of.

:Pause() [Instance]


Pause an animation.

Paramaters

name string The name of the animation.

:Resume() [Instance]


Resume an animation.

Paramaters

name string The name of the animation.

:BindMarkers() [Instance]


Binds a marker or multiple markers to a function.

Paramaters

name string The name of the animation.
callbackTable table the callback table.

:SetSpeed() [Instance]


Changes the playback speed of an animation.

Paramaters

name string The name of the animation.
speed number The new playback speed.

:Destroy() [Instance]


Cleanup function.


:isPlaying() [Instance] [Read Only]


Checks if a animation is playing.

Paramaters

name string The name of the animation.

Returns

false or true

:isPaused() [Instance] [Read Only]


Checks if a animation is paused.

Paramaters

name string The name of the animation.

Returns

false or true

:GetPlaying() [Instance] [Read Only]


Returns what animations are playing.

Returns

Returns a table with 1 or multiple strings

:GetGroup() [Instance] [Read Only]


Returns the group of an animation.

Paramaters

name string The name of the animation.

Returns

Returns a string

:GetAllAnimations() [Instance] [Read Only]


Returns the all registered animations.

Paramaters

group string The group of the animations. [Optional]

Returns

Returns a table with the name of the animation and the data.

Change Logs

15.08.2025


New:

Added a Global Cache.

MotionX Is now on Wally.

Added 1 new read only method: '.Get()'

Added 1 new read only method: ':GetAllAnimations()'

Changes

Fixed some memory leaks


20.07.2025


New:

Added a new groupping feature! (suggested by BreezeOnTheDoor)

Added auto-cleanup when you delete your character

Added 1 new read only method: ':GetGroup()'

Added 1 new instance method: ':BindMarkers()'

Changes:

Changed ':Play()' method to include adding a fade time

Changed ':RegisterNew()' method to include adding a group

Changed ':GetGroup()' method to include a group paramater for stopping all animations in a group.


19.07.2025


Release day!