FadeGroup Class

Summary

A group of Animancer.AnimancerNodes which are cross-fading.
graph BT Type-->Base0["Updatable"] click Base0 "/animancer/api/Animancer/Updatable" Base0-->Base1["Object"] Type-.->Interface0["IUpdatable"] click Interface0 "/animancer/api/Animancer/IUpdatable" Type-.->Interface1["ICloneable<FadeGroup>"] Type-.->Interface2["ICopyable<FadeGroup>"] Type-.->Interface3["IHasDescription"] click Interface3 "/animancer/api/Animancer/IHasDescription" Type["FadeGroup"] class Type type-node

Syntax

public class FadeGroup : Updatable, IUpdatable, ICloneable<FadeGroup>, ICopyable<FadeGroup>, 
    IHasDescription

Remarks

Documentation: Custom Easing

Properties

Name Value Summary
Easing Func<float, float>
[Pro-Only] An optional function for modifying the fade curve.
FadeDuration float
The total amount of time this fade will take to complete (in seconds).
FadeIn NodeWeight
The node which is fading towards the Animancer.FadeGroup.TargetWeight.
FadeOut IReadOnlyList<NodeWeight>
The nodes which are fading out.
FadeSpeed float
The speed at which the Animancer.FadeGroup.NormalizedTime increases.
Graph AnimancerGraph
The Animancer.AnimancerNodeBase.Graph.
IsValid bool
Should this fade continue?
KeepChildrenConnected bool
Should the fading nodes always be connected to the Animancer.FadeGroup.ParentPlayable?
NormalizedTime float
The 0-1 progress of this fade.
Parent AnimancerNodeBase
The Animancer.AnimancerNodeBase.Graph.
ParentPlayable Playable
The Animancer.AnimancerNodeBase.Playable of the Animancer.FadeGroup.Parent.
RemainingFadeDuration float
The remaining amount of time this fade will take to complete (in seconds).
TargetWeight float
The Animancer.AnimancerNode.Weight which the Animancer.FadeGroup.FadeIn is moving towards.

Methods

Name Value Summary
AddFadeOut(AnimancerNode) void
Adds a node to the Animancer.FadeGroup.FadeOut list.
AppendDescription(StringBuilder, string) void
Appends a detailed descrption of the current details of this object.
ApplyWeights() void
Recalculates the node weights based on the Animancer.FadeGroup.NormalizedTime.
AssertNormalizedBounds(Func<float, float>, string) void
[Assert-Conditional] Checks Animancer.OptionalWarning.FadeEasingBounds.
static
Cancel() void
Interrupts this fade and releases it to the Animancer.ObjectPool`1.
Clone(CloneContext) FadeGroup
Creates a new object with the same type and values this.
CloneForSingleTarget(AnimancerNode, AnimancerNode) FadeGroup
Creates a clone of this Animancer.FadeGroup for a single target node (`copyTo`).
Contains(AnimancerNode) bool
Does this fade affect the `node`?
CopyFrom(FadeGroup, CloneContext) void
Copies the contents of `copyFrom` into this object, replacing its previous contents.
GetTargetWeight(AnimancerNode) float
Returns the Animancer.FadeGroup.TargetWeight if the `node` is the Animancer.FadeGroup.FadeIn. Otherwise, returns 0.
Remove(AnimancerNode) bool
Removes the `node` from this Animancer.FadeGroup and returns true if successful.
SetFadeIn(AnimancerNode) void
Assigns the Animancer.FadeGroup.FadeIn with no Animancer.FadeGroup.FadeOut.
SetNodes(AnimancerNode, AnimancerNode, IReadOnlyList<AnimancerNode>, bool) void
Assigns the target nodes that will be faded.
StartFade() void
Registers this fade to be updated.
StartFade(float, float) void
Sets the starting values and registers this fade to be updated.
Update() void
Updates this object.

Extension Methods

Name Value Summary
SetEasing(Easing.Function) void
[Pro-Only] Assigns the Animancer.Easing.GetDelegate(Animancer.Easing.Function) as the Animancer.FadeGroup.Easing if the `fade` isn't null.
SetEasing(Func<float, float>) void
[Pro-Only] Assigns the `function` as the Animancer.FadeGroup.Easing if the `fade` isn't null.