AttackDirectionAnimationFloatSettings.FloatAnimation
A class in Root.Township, Alta.Intelligence.
Per-creature driver made by AttackDirectionAnimationFloatSettings: eases a networked animator float toward a value set by the attack direction.
- Listed in Creatures and AI
- Nested in
AttackDirectionAnimationFloatSettings - Inherits or implements
IAttackDirectionAnimation
Constructors
| Member | What it is |
|---|---|
FloatAnimation() | Creates an AttackDirectionAnimationFloatSettings.FloatAnimation with default values. |
Fields
2 private and internal fields
| Member | What it is |
|---|---|
private AnimatedFloat animatedProperty | The networked animator float being driven. |
private float target | Value the float is easing toward. |
Methods
4 private and internal methods
| Member | What it is |
|---|---|
private void Alta.Intelligence.IAttackDirectionAnimation.Disable() | Does nothing. |
private void Alta.Intelligence.IAttackDirectionAnimation.SetDirection(int direction) | Sets the target value to (direction + 1) / 2, so -1, 0 and 1 map to 0, 0.5 and 1. |
private void Alta.Intelligence.IAttackDirectionAnimation.Setup(NetworkAnimator animator, string parameterName) | Looks up the named float on the creature's NetworkAnimator and starts the target at its current value. |
private void Alta.Intelligence.IAttackDirectionAnimation.Update(float lerp) | Lerps the float toward the target by the given amount. |