Rig - is an actor blueprint which creates a biped rig and allows animation editing. It uses AllrightMacroLib library. Rig blueprint has three components:
- PoseableMesh - is a poseable mesh component, which is used for posing the character.
- SkeletalMesh - is a skeletal mesh component, which is used for posing the character.
- AnimMesh - is a skeletal mesh component, which is used for animation playing and recording.
To create the rig choose a Rig option in Source property under Rig Properties menu.
Rig consist of:
- stretchy ik spine
- ik head with auto rotation of neck
- fk shoulders
- fk-ik arms
- ik legs
- fk fingers
You can use Left Hend Fk Ik and Right Hand Fk Ik properties under the Rig Properties menu.
You can make unlimited instances of this blueprint in a scene, because it is very easy to solve.
To delete rig choose Stance option in Source property under the Rig Properties menu.
To create and play animation you can use default Level Sequence Editor plugin.
During deleting of rig the Level Sequence animation will also be deleted!
For how to use Sequencer Editor please visit the Sequencer Editor page in Unreal Engine documentation.
You can play final animation using the rig, but of course it is better to save it to the animation sequence.1. Choose your level sequence in Sequencer property under the Bake menu. Also you need to set Start Frame, End Frame and Fps. 2. Choose BakeToAnimSequence event under the Bluetilities menu and click Run. 3. Select path to create new animation sequence.
Also, you can bake animation from animation sequence to the rig.
1. Choose the animation sequence that needs to be baked in Anim To Play property under the Rig Properties menu.
To play this animation choose the Animation option in Source property under the Rig Properties menu.
The rig will be automatically deleted!
Also you can use animation playing properties Initial Position and Looping.
2. Choose the level sequence on which to bake an animation in Sequencer property under the Bake menu. Also you need to set the Start Frame, End Frame and Fps.
3. Choose BakeToRig event under the Bluetilities menu and click Run.
Now the animation is editable on the rig.
Using custom skeletons
If your skeleton is identical to UE4_Mannequin_Skeleton, it is better to assign UE4_Mannequin_Skeleton to your character.
The rig can be created for any character that has a skeletal hierarchy which is identical to the hierarchy of required bones of default UE4_Mannequin_Skeleton.
You can see required bones by choosing a Humanoid option in Select Rig property under the Retarget Manager window. Also, do not forget about the Show Advanced button.
There can be extra bones in a rig, but the main hierarchy order must be the same. The names of the bones do not matter. The requirements are the same as for making animation copies.
For good IK solving it is best to bend the characters arms and legs a little bit before importing to Unreal.
- To prepare a skeleton for the rig choose a Humanoid option in Select Rig property under the Retarget Manager window.
- Use the drop-down menus to select the Bones on the Skeleton that are similar in location to the Bones (Nodes) on the Rig.
For how to use the Retarget Manager please visit the Animation Retargeting page in Unreal Engine documentation.
After preparing the character choose it in Char Type property under the Rig Properties menu.
Now you can work with this character.
The rig has two types of solving. You can define them using a Rig Type property under the Rig Properties menu.
- PoseableMesh uses a PoseableMesh component.
- AnimBlueprint uses a SkeletalMesh component and animation blueprint.
By default rig uses RigAnim blueprint. AnimBlueprint mode allows user to edit RigAnim with animation blueprint editor nodes.
For how to use animation blueprints please visit the Animation Blueprints page in Unreal Engine documentation.
If you are using a custom skeleton, you need to retarget RigAnim blueprint on your skeleton and to set a new animation blueprint in Anim Blueprint property under the Rig Properties menu.
For how to use the Retarget Animation please visit the Animation Retargeting page in Unreal Engine documentation.
Before creating the rig you can customize the view of your controllers under the Controls Properties menu.
Shape - defines controls shape. By default it is using Static Meshes from CharRig/Controls/Shapes folder.
Color - defines colors for middle, left and right controls.
Scale - defines controls scale.
Controllers orientation is defined by orientation of bones. Ik effector controllers , as well as the main controller of upper body have a global orientation.
Controller names are generated according to the names of the skeleton bones.
AllrightMacroLib is an expandable open multi level macro library which is created using the AllrightNodes plugin. It allows to create different parts of the rig, update them, record and edit animation. User can create his own custom rigs using this library. AllrightMacroLib uses enumerators from Enums folder.
Main macros groups:
- Constraints - consist of usual parent, point, orient and aim constraint analogs like those in Autodesk Maya.
- AutoRig - are rigging modules for spine, head, arms, legs and fingers.
- Ik - is a two bone inverse kinematics system.
- Ctrl - creates controls with different shapes and colors.
- Update Rig - updates rigging modules.
- Bake To Rig - is a recording system for the rig.
- Bake To Anim Sequence - is a recording system for an animation sequence.
RigAnim is an animation blueprint that was created using UE4_Mannequin_Skeleton. This Blueprint controls skeletal animation while the Anim Blueprint property under the Rig Properties menu is set to AnimBlueprint . RigAnim gets variable values from Rig and sets them to skeleton bones using SetBoneLocationAndRotation node. This blueprint allows the user to edit animation with the animation blueprint editor nodes. If the user wants to use a custom skeleton, he needs to retarget RigAnim blueprint on his skeleton and to set a new animation blueprint in Anim Blueprint property under the Rig Properties menut.
Enums folder has several enumerators :
- AxisEnum - is used in a AllrightMacroLib.
- CharSourceEnum, CtrlTypeEnum, RigTypeEnum - are used in a Rig.
Controls folder has:
- Ctrl - is an actor blueprint class, that is used for controllers actors.
- Circle, Cube, Locator, Sphere - are static meshes, that are used to define a shape of the control.
- ControlMtl - is a material, which is used to define a shader of the control.
- SpawnActorInEditor - spawns an actor in editor (for use in construction script)
- Parent - is a stripped-down version of AttachActorToActor node which attaches one actor to another.
- SetActorSelectable - sets actor selectable state
- PostEditChange - updates actor and evaluates construction script
- SelectActorInEditor - selects actor
- OpenEditorForAsset - opens editor for asset
- NotificationBox - shows message in the corner of screen
- PromtDialogue - shows message with list and possibility to select
- GetAssetsByClass - gets an array of all objects by specified class
- AppendName - appends to name
- MatchesWildcard - checks if a name matches other name
- AddRawKeyToAnimSequence - adds a raw transform key to an animation sequence
- CreateAnimAsset - creates a new animation sequence for skeletal mesh component
- CropAnimation - crops the raw anim data either from Start to CurrentTime or CurrentTime to End depending on value of bFromStart
- GetSpaceBases - gets an array of bone transformations from skinned mesh component
- IsSequencerHasBindingForActor - checks if a sequencer has binding for an actor
- GetTracksFromBinding - gets an array of tracks from an actors binding
- GetSectionsFromTrack - gets an array of sections from a track
- SetTransformSectionKey - sets a transform key on a section
- SetSectionStartTime - sets a sections start time
- SetSectionEndTime - sets a sections end time
- GetSequencerComponents - gets an array of sequencer components and bindings
- UpdateSequncerComponent - updates the sequencer components location in a specific time
- AddBindingToSequencer - adds actors binding to the sequencer
- AddTransformTrack - adds a transform track to the actors binding
- RemoveBindingFormSequencer - deletes binding from sequencer
- GetRigMapping - gets an array of mapped names from retarget manager
- TwoBoneIk - uses the same algorithm as animation blueprint
- GetPoleVectorLocation - finds location where should be pole vector for ik
- SetBoneLocationAndRotation - alters location and translation of the bone
- ActorUpdater - is a custom tickable object, which evaluates a construction script of a specified actor.