Vehicle Wheel

physics.vehicle_wheel.set_debug_all

Client

Shows or hides the debug overlay on all vehicle wheels, including ones created afterward

Syntax

local status = physics.vehicle_wheel.set_debug_all(
    state
)

The overlay shows the wheel's live state.

  • Ring — cyan while the wheel has full grip, shifting toward red as it skids, and magenta while it is airborne. The yellow spoke marks wheel rotation.
  • Suspension — a white cross at the connection point, an orange ray down to the bottom of the wheel at rest, a blue bar for the suspension travel range, and a line to the wheel center that turns from green to red as the spring compresses.
  • Contact — a red cross at the contact point, with the surface normal drawn from it.

Parameters

TypeNameDescription
boolstatetrue to show the debug overlay on all vehicle wheels, false to hide it

Returns

TypeNameDescription
boolstatustrue on successful execution, false otherwise

Examples

Toggle the wheel debug overlay globally
physics.vehicle_wheel.set_debug_all(true)

On this page