MixerChildFade Class

Summary

Fades the child weights of a Animancer.MixerState`1 to a new parameter value instead of fading the actual parameter.
Assembly
Animancer.dll
Namespace
Animancer
Base Types
  • Object
graph BT Type-->Base0["Object"] Type["MixerChildFade"] class Type type-node

Syntax

public static class MixerChildFade

Remarks

Documentation: Smoothing

Example: Imagine a Linear Mixer with thresholds 0, 1, 2 and child states A, B, C. If you fade its Parameter from 0 to 1 the states would go from A to B to C. But if you use this system instead, the states would go directly from A to C.

Usage

[SerializeField] private AnimancerComponent _Animancer;
[SerializeField] private LinearMixerTransition _Mixer;

public void FadeMixerTo(float parameter, float fadeDuration)
{
    _Mixer.State.FadeChildWeights(parameter, fadeDuration);
}

Methods

Name Value Summary
FadeChildWeights<TParameter>(MixerState<TParameter>, TParameter, float) void
Fades the child weights of a Animancer.MixerState`1 to a new parameter value instead of fading the actual parameter.
static