Attention: Here be dragons

This is the latest (unstable) version of this documentation, which may document features not available in or compatible with released stable versions of Godot.

VehicleWheel3D

Inherits: Node3D < Node < Object

A 3D physics body for a VehicleBody3D that simulates the behavior of a wheel.

Description

A node used as a child of a VehicleBody3D parent to simulate the behavior of one of its wheels. This node also acts as a collider to detect if the wheel is touching a surface.

Note: This class has known issues and isn't designed to provide realistic 3D vehicle physics. If you want advanced vehicle physics, you may need to write your own physics integration using another PhysicsBody3D class.

Tutorials

Properties

float

brake

0.0

float

damping_compression

0.83

float

damping_relaxation

0.88

float

engine_force

0.0

float

steering

0.0

float

suspension_max_force

6000.0

float

suspension_stiffness

5.88

float

suspension_travel

0.2

bool

use_as_steering

false

bool

use_as_traction

false

float

wheel_friction_slip

10.5

float

wheel_radius

0.5

float

wheel_rest_length

0.15

float

wheel_roll_influence

0.1

Methods

Node3D

get_contact_body ( ) const

float

get_rpm ( ) const

float

get_skidinfo ( ) const

bool

is_in_contact ( ) const


Property Descriptions

float brake = 0.0

  • void set_brake ( float value )

  • float get_brake ( )

Slows down the wheel by applying a braking force. The wheel is only slowed down if it is in contact with a surface. The force you need to apply to adequately slow down your vehicle depends on the RigidBody3D.mass of the vehicle. For a vehicle with a mass set to 1000, try a value in the 25 - 30 range for hard braking.


float damping_compression = 0.83

  • void set_damping_compression ( float value )

  • float