🇺🇸 United States · English ← Edition home
Roblox

Roblox Animation Graph State Machines: How the New Beta Works

For readers in the United States

Author: Shivam Das · Independent coverage. Corrections / Contact

Roblox Studio Animation Graph Editor showing connected animation clip nodes
Roblox Studio Animation Graph Editor showing connected animation clip nodes

Roblox is giving animators and game developers a more structured way to control character movement. State Machines and Luau Expressions bring state-based transitions into the Animation Graph Editor, letting creators define how a character moves from one animation to another without putting every transition rule in a separate script.

The feature can organize locomotion, falling, landing, or the stages of a multi-part attack combo. The graph tracks the active animation state and the transitions allowed from it.

Quick answer: A Roblox Animation Graph state machine is a node that organizes animations into named states and controls when the graph can transition between them. Creators add a State Machine node, create states, connect animation clips or blend nodes, choose an entry state, and define transitions using graph parameters or completion conditions.

What Roblox announced

On October 8, 2026, Roblox announced State Machines and Luau Expressions as a Studio beta for the Animation Graph Editor. The editor itself had moved into full release in July; the October announcement added a more explicit way to manage state-dependent animation flow and parameter calculations inside the graph.

Animation Graphs provide a visual system for combining and blending clips. A state machine adds rules about which animation states can follow other states, helping prevent an animation from starting at the wrong point in a sequence.

Roblox's October beta announcement said State Machines and Expressions were Studio-only at that stage and could not yet be used in live games during the beta. Creator Hub now documents how to build state machines, but creators should check current Studio Beta Features and release notes before depending on the feature in a published experience.

Roblox Studio Animation Graph Editor insert menu listing Clip, Select, Sequence, Blend and other node types
The editor uses connected nodes to define how character poses are selected and blended. Image: Roblox Creator Hub.

What a state machine changes

Before a dedicated state machine, developers often used Select or Priority Select nodes and tracked animation state in Luau. That can become difficult when a character has many possible actions. A condition intended for one part of an attack combo might also become true while the character is still in an earlier state.

A state machine makes the allowed flow explicit. Each state has a name, and each transition identifies where the animation can go next. A state can be backed by a clip, a blend node, or another state machine. Its output is the active pose, or a blend between poses during a transition.

Roblox Studio Animation Graph Editor showing two animation clip nodes with animation IDs
Clip nodes provide the animation clips that a larger graph can combine. Image: Roblox Creator Hub.

How to create a State Machine in Roblox Studio

  1. Select the rig or character.
  2. Open the Animation Graph Editor from the Avatar tab and create or open a graph.
  3. Right-click the graph canvas, choose Insert Node, then select State Machine.
  4. Click Open on the State Machine node.
  5. Use Create State to add names such as Locomotion, Fall, and LandIdle.
  6. Return to the main graph and connect animation clips or blend nodes to matching state inputs. Each state name must match its input name.
  7. Connect (Entry) to the state that should play first.
  8. Add transitions, set their conditions and blend timing, then preview the graph with different parameter values.

The entry state determines where playback begins. A state can contain one clip, a blend node combining several clips, or a nested state machine.

Example: locomotion, falling and landing

Roblox's documentation demonstrates a movement sequence: a character starts in locomotion, switches to a fall animation after leaving the ground, and plays a landing animation after touching the ground again.

  • Locomotion: Use a Blend1D node to blend idle and running clips with a parameter such as Speed.
  • Fall: Connect a falling clip and set its play mode to OnceAndHold so it holds its final pose.
  • LandIdle: Connect a landing clip, also using OnceAndHold, so the graph can return to locomotion after the landing animation finishes.
Roblox Studio Blend1D animation graph node with multiple animation inputs and a position control
A Blend1D node can blend clips using a parameter such as movement speed. Image: Roblox Creator Hub.

Add a Boolean graph parameter named Grounded, set to true while the character is on the ground. Roblox's example uses these transitions:

From To Condition Blend duration
Locomotion Fall not Grounded 0.2 seconds
Fall LandIdle Grounded 0.1 seconds
LandIdle Locomotion Wait for landing clip to finish; begin before it ends 0.2 seconds

This creates a controlled sequence instead of allowing a landing clip to interrupt a fall or returning to running before the landing motion is complete. The pattern can be extended with jump-start, jump-loop, alternate landing, or combat states.

Transitions, conditions and priorities

A transition connects source states to a destination state. The state machine checks it only when a source state is active. It can be driven by an expression or wait for the current animation to finish.

When Wait For is Expression, the graph evaluates a condition. A Boolean parameter such as ShouldJump can trigger a transition, while Speed >= 12 uses a numeric parameter. When Wait For is Finished, the transition can begin after the source animation finishes or shortly before it finishes.

Roblox Creator Hub illustration of default animation graph transition settings
Transition settings control how one animation blends into another. Image: Roblox Creator Hub.

Transitions support a duration and an easing curve. Roblox's documentation lists Linear and CubicV2. If multiple expression-based transitions can become true at once, the higher-priority transition is evaluated first. Give competing transitions distinct priorities so the intended route is predictable.

Roblox Creator Hub illustration of an animation graph transition override setting
Input-specific overrides adjust blending for particular animation connections. Image: Roblox Creator Hub.

What Luau Expressions can and cannot do

Expressions put small calculations close to the graph nodes or transitions that use them. Roblox describes an expression as a short Luau-like formula that reads graph parameters and returns a value. For example:

math.clamp((MovementSpeed + 0.5) / MaxSpeed, 0, 1)

The beta announcement lists arithmetic, comparisons, Boolean operators, conditional expressions, the math library, Vector3 construction and member access, string concatenation, and limited multi-line local-variable logic.

Expressions do not support loops, function definitions, tables, require(), arbitrary method calls, libraries other than math, or direct DataModel access. They read graph parameters, not the character or Workspace directly. A script must pass gameplay information into the graph as a parameter.

Do developers still need Luau scripts?

Yes. Gameplay code still supplies the values that drive the graph. A script can calculate movement speed and update a graph parameter through AnimationTrack:SetParameter(). The graph can then use that value to blend idle and running animations or evaluate a transition. State machines reduce animation transition logic in scripts; they do not eliminate scripting.

When a state machine is better than Priority Select

Priority Select is useful when a graph should choose the highest-priority animation whose condition is true. A state machine is a better fit when a transition should only be possible from particular states. In a sword combo, for example, Swing 2 should follow Swing 1, but should not start directly from Idle just because a button condition is true. Simple idle/run blending may need only Blend1D; multi-stage actions with state-dependent exits are where a state machine is most useful.

What creators should check before shipping

  • Confirm rollout status: The October 8 announcement described State Machines and Expressions as Studio beta features and said they were not available in live games at that stage. Check current Beta Features and official release notes before planning a production launch.
  • Test every route: Check valid and invalid transitions, including simultaneous conditions.
  • Set priorities deliberately: Avoid ambiguous transitions with equal priority.
  • Keep expressions small: Put complex gameplay calculations in Luau and pass the result into the graph.
  • Check blend timing: Poor timing can make a transition feel rushed or create a visible snap.
  • Test real rigs: Custom rigs and gameplay conditions can reveal issues a simple preview misses.

Why this matters for Roblox games

The biggest benefit is predictability. Characters can move through animation sequences that respect the current state, making movement, combat combos, reloads, emotes, and other multi-stage actions easier to author and debug. It is not an automatic animation-quality upgrade: clips, rig setup, parameter values, timing, and gameplay code still matter. A clear state model gives teams a better structure for making those pieces work together.

Related Roblox Studio coverage

Frequently asked questions

What is a State Machine in Roblox Animation Graphs?

It organizes animation logic into named states and controls which transitions can occur from the active state.

How do I add a State Machine in Roblox Studio?

Open the Animation Graph Editor, right-click the canvas, choose Insert Node, select State Machine, and create named states in its state view.

Do State Machines replace Luau scripts?

No. Scripts still provide gameplay values and update graph parameters. State machines move much of the animation transition logic into the visual graph.

Can State Machines be used in live Roblox games?

Roblox's October 8, 2026 beta announcement said State Machines and Expressions were Studio-only and could not be used in live games at that stage. Check current release notes for any later rollout change.

Do Luau Expressions have full Luau support?

No. They support a limited syntax and do not support loops, function definitions, tables, require, arbitrary method calls, or direct DataModel access.

Official Roblox sources

Watch the Roblox Animation Graph Editor walkthrough

Roblox Creator Hub's official walkthrough introduces the visual Animation Graph Editor and shows how clips and nodes connect.

Author: Shivam Das

Back to top