What is a Player Animator
The Animator is responsible for maintaining your AnimGraph with up to date information. You can also set the position and rotation of your player in the Animator.
public class StandardPlayerAnimator : PlayerAnimator
public override void Tick()
SetParam( "b_grounded", GroundEntity != null );
SetLookAt( "lookat_pos", Player.EyePos + Input.Rot.Forward * 1000 );
public virtual void DoRotation()
var idealRotation = Rotation.LookAt( Input.Rot.Forward.WithZ( 0 ), Vector3.Up );
Rot = Rotation.Slerp( Rot, idealRotation, WishVelocity.Length * Time.Delta * 0.01f );
Rot = Rot.Clamp( idealRotation, 120 );
SetParam( "walkspeed_scale", 2.0f / 190.0f );
SetParam( "runspeed_scale", 2.0f / 320.0f );
var moveDir = WishVelocity.Normal;
var forward = Rot.Forward.Dot( moveDir );
var sideward = Rot.Right.Dot( moveDir );
SetParam( "forward", forward );
SetParam( "sideward", sideward );
SetParam( "wishspeed", WishVelocity.Length );
Setting the Animator is the same as setting a Player Controller.
public override void Respawn()
Animator = new StandardPlayerAnimator();
Like the Player Controller, this property can be changed at any time and is replicated to the client. Setting to null will mean your player isn't animated.