Miarmy Crowd Simulation Documentation (English)

Action Transform Data

Agent Transform Data is generated from you "rig root", and stored independently in action node. It's a kind of locomotion data can be applied to overall agent
As we all know, we create action from animation, it is motion in a limited area. For example a character is walking in scene and we build action data 24 frames.
In the below picture, it's a walk cycle, nothing special



A walk cycle from A to B, for example 24 frames


The normal animation will be from A to B and get back to A, once again, from A to B, repeatedly.
We want to apply it to the agents and make the agent move forward in any direction from anywhere. We want to the agents can travel in scene independently.



Transform "the walk cycle A to B" to "agent locomotion data"


In above picture, the red line is repeatedly playback animation
The yellow line is the action with agent transform data. The movement of yellow paths shown is our purpose.
With agent transform data, we can apply the accumulate locomotion to the agent, and our agent can work independently in our scene
For this purpose, we need separated the animation in 2 parts:

  • Action data: the animation pose data of each frame
  • Agent transform data: the each frame root node velocity data can be used to apply to single agent transform 

Usage:

  1. The action data part is responsible to pose you agent only.
  2. The agent transform data part is responsible to move your agent in each frame.

The agent transform data actually is an array of velocity value for each frame. So, no matter where the agent is and what direction the agent orient to, we can apply a velocity to it each frame. The result is, the agents can travel in scene from anywhere respectively, instead of repeat playing back in a small area.

Agent transform data can be several types, different types are determined by the degree of freedom of translate and rotate
The "A" picture above shows the "locomotion" type, and "B" shows the "turning" type.

  • Static: agent stands without transform change (e.g. stand, sit, cheer)
  • Locomotion: agent walks in z direction straight (e.g. walk, stand to walk, jog, run)
  • Turning: agent turning to left or right (turn left, turn right)
  • Ramp: agent go up or go down (go upstairs, climbing)


Miarmy will automatically generate agent transform data for you when you create action.
Also we provide tools are able to re-build it or fix it

Click auto fill, you can build agent transform data as preset:


Fix Agent Transform is used for shifting or rotating your agent transform data:


For example 1
The standard agent orientation is "+Z", but if your animation rig is walking in x direction. After creating action, you can rotate it back to +Z. 
Just fill 90 in action editor, and click "Fix Agent Transform"



Fix the agent transform data


For example 2



The root of agent moved


Please notice the above animation, from stand to sit, character's root (hip) has been moved, from A to B. However, this action is a static action. When this action transition to sit action, there will be a weird behavior:


The red spot is the "origin". The left action is "stant_to_sit" and right is "sit" action.


You may notice the

  1. In "stand_to_sit" action: the Origin is in the character's feet.
  2. In "sit" action: the origin is in character's root (hip)

If the agent transit from "stand_to_sit" to "sit", the action will "shift" forward, because the 2 action have different origin places. At this time the only thing we need to is move the sit origin to his front, like the picture below:


 
Fix the agent transform data


The result will move the action entirely forward. The play back transition will now without "shift" and seamless.


Summary

Although the agent transform data is crucial, this data can be actually automatically generated, in most of time, you don't need to care about that, just choose the right type. Everything will be fine.









Basefount Technology