crashcat docs
    Preparing search index...

    Function updateGroundVelocity

    • Updates the ground velocity to account for rotation of the ground body. This is needed for rotating platforms - the character should move with the platform's rotation, not just its linear velocity.

      Note: This function recalculates the ground velocity from the ground body, applying any listener adjustments (e.g., conveyor belts). It should only be called when you want to refresh the ground velocity based on the current ground body state.

      Parameters

      • world: World

        the physics world

      • character: KCC

        the character controller

      • Optionallistener: CharacterListener

        optional listener for adjusting body velocities

      Returns void