Weapon Animations

Mattis

Active member
Hi!

Where is the component that controlls what weapon animation should play when? and are your weapons using animator controller? ... Im about to animate my weapons and trying to figure out how they work.. Have not found any docs on it..

Kr
Mattis
ASG
 
Yes, weapon animations are controlled by animator controllers. For an example, check out the AssaultRifle animator controller in the demo. It uses all the same animator parameters as the character's base animator controller (e.g. item ID, state index, etc.). For the AssaultRifle, it has an Animator Item ID of 1 (defined on its Item component), and the Use ability has an Item State Index of 2, hence the transition parameters for Any State -> Fire.
 
The animator controller is attached to the visible object itself (which you can quickly find from the First/Third-PersonPerspectiveItem component, under "Render"). In the demo scene it's "AssaultRifle".
 
Top