Documentation
    Preparing search index...

    Variable CHARACTER_CONTROLLER_SERIALIZERConst

    CHARACTER_CONTROLLER_SERIALIZER: ComponentSerializerShape<CharacterController>

    The §79 serializer for CharacterController (§12, PH-11 residue, 2026-08-21).

    import { CharacterController, CHARACTER_CONTROLLER_SERIALIZER } from "@fourjs/motion";

    registry.register(CharacterController, CHARACTER_CONTROLLER_SERIALIZER);

    The whole configuration is written, plus the vertical motion state — verticalVelocity and grounded — and nothing else. The split is the KINEMATIC_CONTROLLER_SERIALIZER rule applied to a class that has both kinds of state:

    • Vertical motion is scene state. A character saved mid-jump is at a height the document already carries, moving at a speed nothing else can reconstruct, so a document that dropped it would restore the character hanging in the air and then let it fall from rest.
    • The move intent is not. It is this frame's input — the same live, per-step quantity as an in-flight moveTo command, and §79 documents do not carry the player's thumb. It restores at (0, 0), and the application writes the next one on the next step exactly where it wrote the last.

    maxFallSpeed is written only when finite: Infinity is not JSON, and its absence is already the class's "no terminal velocity" default on both sides. skippedSteps is a diagnostic of a run and is not carried.