Animation
Animation
Importing
Compared to Unity, it is more complex to import FBX into Lumberyard. Just dragging assets into the engine does not work for Lumberyard. And for different parts of the characters and animations, they have to be exported from Maya in different ways. But Unity does not need these steps in importing characters and animations.
Animation Editor
Animation Graph
In Unity, things are very similar. The animator window shows the animator controller, which holds the same information as the anim graph in Lumberyard. Unity also provides different types of parameters to trigger animations, but the types are less than Lumberyard. In Unity, there’s no concept of motion set. Any animations can be added to the animator controller.
Character
The Actor component in Lumberyard is similar to that of a Skinned Mesh Renderer, it is the component which recognizes that the mesh has a rig and skin weights. The Anim Graph component in Lumberyard is similar to Unity’s Animator component.
Scripting Interface
The methods of calling animation is very similar to Unity. In Unity, there are also parameters that can control the animation. So it is easy to learn and understand how to use scripts to control animations in Lumberyard for developers who are familiar with Unity.
State Machines and Blend Trees
In Unity, the transition between the two animation clips can be adjusted by dragging the start and end values of the overlap.
Blend Tree
Unity has Blend Trees:
In Unity, when the blend tree is set up with Animation clips and input parameters, the inspector window gives a graphical visualization of how the animations are combined as the parameter value changes (as you drag the slider, the arrows from the tree root change their shading to show the dominant animation clip).
The blend tree in Lumberyard can also achieve the same result, and it can also be previewed in the Animation Editor.
Animation Layers
Unity uses Animation Layers for managing complex state machines for different body parts. An example of this is if you have a lower-body layer for walking-jumping, and an upper-body layer for throwing objects / shooting.
You can manage animation layers from the Layers Widget in the top-left corner of the Animator Controller.
On each layer, you can specify the mask (the part of the animated model on which the animation would be applied), and the Blending type. Override means information from other layers will be ignored, while Additive means that the animation will be added on top of previous layers.
Unity and Lumberyard works in different ways but they can achieve the same things in pose mask. In Lumberyard, the pose mask is achieved in a blend tree, which is different from Unity. However, understanding how animation layer works is definitely helpful in getting started in Lumberyard poseMask.
Scripting Interface
The script should be on an entity with both Actor component and AnimGraph component. In scripting, the animations are called by changing the values of the parameters which are pre-set in the animation graphs. In the animation graph, each animation is triggered by certain parameters, thus, having access to control these parameters means being able to trigger animations.