MotH 0a84347d11 Sorted tags il y a 1 an
..
car_select 1d5184e235 Update most demos for Godot 4.0.beta10 (#782) il y a 2 ans
screenshots 1d5184e235 Update most demos for Godot 4.0.beta10 (#782) il y a 2 ans
town 55934859e3 Add camera selection to Truck Town (#820) il y a 2 ans
vehicles 55934859e3 Add camera selection to Truck Town (#820) il y a 2 ans
.gitattribute d9a6635c11 Ported truck town to Godot 3.0 il y a 7 ans
README.md 55934859e3 Add camera selection to Truck Town (#820) il y a 2 ans
default_env.tres 1d5184e235 Update most demos for Godot 4.0.beta10 (#782) il y a 2 ans
icon.webp 63d1cd9a60 Use 128×128 WebP icons for all demos (#885) il y a 2 ans
icon.webp.import 63d1cd9a60 Use 128×128 WebP icons for all demos (#885) il y a 2 ans
project.godot 0a84347d11 Sorted tags il y a 1 an
spedometer.gd 1d5184e235 Update most demos for Godot 4.0.beta10 (#782) il y a 2 ans

README.md

Truck Town

This is a demo implementing different types of trucks of varying complexity using vehicle physics.

Controls:

  • Up Arrow, W, Gamepad Right Trigger, Gamepad A/Cross: Accelerate
  • Down Arrow, S, Gamepad Left Trigger, Gamepad B/Circle : Brake
  • Left Arrow, Gamepad Left Stick: Steer left
  • Right Arrow, Gamepad Left Stick: Steer right
  • U, Gamepad Select, left-click speedometer: Change speedometer unit (m/s, km/h, mph)
  • C, Gamepad Y/Triangle: Change camera (exterior, interior, top-down)
  • Escape, Gamepad D-Pad Up: Go back to menu (press again to exit)

Language: GDScript

Renderer: Forward Plus

Check out this demo on the asset library: https://godotengine.org/asset-library/asset/524

How does it work?

The base vehicle uses a VehicleBody node. The trailer truck is tied together using a ConeJointTwist node, and the tow truck is tried together using a chain made of RigidBody nodes which are pinned together using PinJoint nodes.

Screenshots

Screenshot