Animation Slot
Last Updated Time: 09/21/2023
Overview
The Slot can be served as a node in the animation tree to play dynamic actions (such as attack actions), and insert animation poses played outside the Animation Tree to be used by other nodes. Slots are often used with Montage.
Creating Slots
In the Anim Tree Editor, right-click on Slot Name under the Slot Manager,select Add Default Group And Slot to add a Slot Group or a Slot.
To add a new slot, right-click on DefaultGroup or DefaultSlot,then select Add Slot , enter the slot name in the pop-up window and press Enter key to finish.
After adding:
Right-click the Slot Group to open the shortcut menu.
Name | Description |
---|---|
Add Slot | Add a new slot. |
Add Group | Add a new slot group. |
Delete Group | Delete the selected slot group. |
Right-click the slot to open the shortcut menu.
Name | Description |
---|---|
Delete Slot | Delete the selected slot. |
Rename Slot | Rename the selected slot. |
Add Slot | Add a new slot. |
Add Group | Add a new slot group. |
Delete Group | Delete the selected slot group. |
After finish editing the slot, click on Save in the Slot Manager.
Using Nodes
Right-click in the empty space of the Anim Tree to open the Nodes selection panel, expand the Montage category and select a slot from it.
Finish adding:
Slot nodes are often paired with Layered Blend Per Bone nodes to achieve the character's upper and lower body action synthesis, such as:
When there is no input outside the Animation Tree, the input of the Slot node UpperBody pin will be considered as the output, and the character will output the Locomotion animation.
When there is an external input, the output of the node will be switched to the external input, and the upper body of the character will be replaced by the input animation.
Properties
When a Slot node is selected, all of its properties will be shown in the Property Window.
Property | Description |
---|---|
Group | Slot group. |
Slot | Slot selection. |
Transition Mode | Select the transition mode when playing the Slot node.
|
Slot Groups
All created slots belong to slot groups, when the first slot is created, it will be automatically created under the DefaultGroup. To create a new slot group, right-click on slot or slot group in the Slot Manager and select Add Group, type in the name and press Enter key to finish creation.
After creation:
Slot groups can be used to categorize slots, and slots in the same group can affect each other. When playing animations within the same group, you can choose whether to stop other animations in the group through scripts or C++ project calls.
Inserting Animations into the Animation Tree Slot
Insert the default_Attack01 attack animation into the UpperBody slot in the Animation Tree through the BlendAction interface.
actor:BlendAction("default_Attack01", false, false, true, 1.0, true, "UpperBody", true)
Example
In terms of using Slot nodes, please refer to the examples in the Layered Blend Per Bone Nodes.