added damping force

This commit is contained in:
thatTopHatCat
2025-07-12 13:06:10 -04:00
parent 722732590b
commit 75ae5521fd
2 changed files with 14 additions and 3 deletions

4
car.gd
View File

@@ -6,3 +6,7 @@ extends RigidBody3D
func _physics_process(_delta: float) -> void:
for wheel: Wheel in wheels:
wheel.apply_forces(self)
##Point argument is in local space
func get_velocity_at_point(point: Vector3) -> Vector3:
return linear_velocity + angular_velocity.cross(point - center_of_mass)