Vixen
02b45cc4
csharp
public static class MoveSetCache

Turns a loaded move set into one a selector can be pointed at.

No guide page documents this yet — the page shows what the code says about itself.

Remarks

The third of the joins AnimationClipCache made for a clip. A MoveSetContent names its clips by address and its overlays by address, and neither is anything a selector can read: MoveSet holds Motions, and a motion holds a clip already baked against a rig.

⚠ Keyed on the rig, because the clips are. Every row goes through AnimationClipCache, so a set baked against two skeletons is two sets holding two different clips — and a cache keyed on the address alone would hand a character somebody else's joint indices.

⚠ A row whose clip will not load is dropped and named. An entry with no motion would be selected like any other and then play silence, which reads in game as a character freezing — much harder to trace than a set with one fewer move in it. Preview is the editor's opposite choice and says why.

⚠ An overlay cycle is broken rather than followed. A set naming itself, directly or round a chain, is a mistake somebody will make in a text file — and following it is a stack overflow rather than a diagnostic.

Methods (2)

  • public static MoveSet Get(MoveSetContent content, Skeleton skeleton, Func<string, AnimationClipContent?>? clips = null, Func<string, MoveSetContent?>? overlays = null, ICollection<string>? unresolved = null)

    The set for a content and a rig, baking it the first time it is asked for.

  • public static bool Forget(MoveSetContent content)

    Forgets every bake of a content, for a rig or a clip that has been re-imported.

Used by (1)

  • LoadPathTestsVixen.Animation.Tests