Phase 5 updates

Phase 5 · Slice 2 ·

The Animator

  • AnimationClip from .anim files, using the curves Unity plays:
    • position, rotation (quaternion or Euler, with the clip's rotation order) and scale by path;
    • float curves on components by class ID, and on script fields by GUID;
    • object curves such as sprite swaps;
    • events, and the clip settings (loop, length). SampleAnimation and SetCurve work too.
  • Animator with .controller state machines:
    • parameters (float, int, bool, trigger) and transitions with conditions, exit time, fixed or normalized cross-fades and offsets;
    • Any State first; sub-state machines flattened under their paths;
    • 1D, 2D (gradient band) and direct blend trees; override layers with weights; AnimatorOverrideController;
    • write defaults; Play, CrossFade and their fixed-time forms; state, transition and clip info. StringToHash is CRC-32, like Unity's.
  • Animators run after Update and coroutines, before LateUpdate (in FixedUpdate with AnimatePhysics). The timing follows a new animator scenario recorded in Unity:
    • a cross-fade completes once it's past its end, and transitions are checked afterwards;
    • zero-length transitions switch at once;
    • exit-time transitions carry the time past the exit into the next state;
    • Play applies at the next update without advancing it;
    • events fire on [previous, current). Unity's times drift slightly low, so a boundary landed on exactly counts in the next update; a small tolerance mirrors that. The scenario matches Unity exactly, directly and through the editor form. 29 scenarios pass.
  • Unity scenes load and save Animators with their controllers. CoreModule gained Transform.Find.
  • An MCP e2e test drives the conformance scene's Animator.
  • Not yet: humanoid rigs and retargeting, IK, root motion, additive layers and avatar masks, transition interruption, StateMachineBehaviours, the legacy Animation component, Timeline, and clips from FBX files.
  • Next: uGUI and TextMeshPro, rendering (shadows, PBR closer to URP).