The Control Rig is a central component of vehicle animation in SubwaySim 2. It controls important animated elements of the vehicle body and undercarriage and acts as a bridge between animation logic and the skeletal mesh.
Typical elements controlled via the Control Rig include:
Because a Control Rig is not generated automatically when importing an FBX file, it must be created manually.
To create a Control Rig, navigate to the folder where your Skeletal Mesh is located.
In the Meshes directory:
Unreal Engine will now generate a new Control Rig asset in the same folder.
The Control Rig should follow a clear and consistent naming convention.
We recommend:
Example:
This makes it easy to identify and reference the Control Rig later when working with Animation Blueprints.
Open the newly created Control Rig by double-clicking it.
You will now see the Control Rig editor, which consists of:
Before adding any logic or nodes, we must define the required variables.
These variables are used to receive values from Lua via the Animation Blueprint and apply them to the Skeletal Mesh.
In the Variables panel, create the following variables with the specified types:
Make sure that the variable types are set correctly. These variables will later be used to drive rotations and positional changes of vehicle components based on simulation data.
At this point, the Control Rig asset is correctly created and prepared for further setup.
After creating the required variables, we now continue with setting up the actual Control Rig logic.
Instead of building everything from scratch, we will reuse a proven setup provided by the Modding SDK.
Navigate to the Samplemod_Vehicle plugin and open the Control Rig of the sample vehicle A3L92.
Inside the Control Rig graph of the A3L92, copy the nodes shown in the provided screenshots and paste them into your own Control Rig.
This setup already contains all required logic to correctly process bogie and axle movement and is intended to be reused as a base for custom vehicles.
After pasting the nodes, it is important to verify that all imported functions and connections are correct.
Specifically, double-click the following functions:
Compare their internal node setups with the reference screenshots provided in this documentation.
The AxleRotation function defines how each individual axle of the vehicle rotates. Each axle must be explicitly defined so that wheel rotation behaves correctly in-game.
The BogieRotation function works similarly, but applies to the rotation and movement of the bogies (trucks) themselves.
Both systems rely on incoming values provided by the simulation and passed through the Animation Blueprint into the Control Rig.
If any variable nodes are missing after copying the setup:
Make sure that all Transform and Float variables are connected exactly as shown in the reference setup.
Inside the imported nodes (highlighted in red in the screenshots), all required bones must be assigned correctly.
For each node:
Incorrect or missing bone assignments will result in non-functional animations or incorrect movement behavior.
Once all nodes, variables, and bone assignments are set up correctly, the Control Rig must be compiled and saved.
To finalize the setup:
Compiling ensures that:
If any errors or warnings appear during compilation, they must be resolved before continuing.
After compiling and saving, the Control Rig is fully functional and ready to be referenced by an Animation Blueprint.