godotengine / godotengine/godot
VehicleWheel3D spring length is being calculated incorrectly
- Dominant language
- C++
- Stars
- 117k
- Forks
- 26.8k
- PR merge metrics
- PR metrics pending
Description
### Tested versions
4.3
### System information
nixos-unstable
### Issue description
There have been bug reports revolving weird spring behaviors before. For some users, the wheels appear to clip into the floor, when [their suspension strength is simply set too low](https://github.com/godotengine/godot/issues/45339#issuecomment-1050273752_)
Initially I thought this was caused by the wheels not being transformed at all, however I now discovered they are simply not transformed correctly.
### Steps to reproduce
1. Set up a VehicleBody3D with wheels
2. Attatch a visual instance to the wheels
3. Run the game
You will likely see the suspension not being able to hold up the vehicle. You will also likely see the wheels clipping trough the floor.
### Minimal reproduction project (MRP)
[minimal_vehicle_bug.zip](https://github.com/godotengine/godot/files/14448808/minimal_vehicle_bug.zip)
Contributor guide
Research direction
Start by running the attached minimal_vehicle_bug.zip project with a VehicleBody3D and VehicleWheel3D setup, then inspect the spring and wheel transformation behavior described in the issue. Done means the suspension supports the vehicle as expected and the wheels no longer clip through the floor under the reproduction steps.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, godot
- Domain
- game-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100