From 0d7ceae474c9df3c60c528c850b74c400d3d90ea Mon Sep 17 00:00:00 2001 From: Zwitschi Date: Tue, 10 Nov 2026 21:33:31 +0100 Subject: [PATCH] docs(memory): record the vehicle settle fix and the failed root-bone experiment --- MEMORY.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/MEMORY.md b/MEMORY.md index fcb55a6..98613d0 100644 --- a/MEMORY.md +++ b/MEMORY.md @@ -1158,3 +1158,27 @@ Historical task context from 2026-11-09/10; later vehicle findings above may sup - The hot-hatch skeletal mesh now imports (403 x 148 x 158 cm), but the mesh is rolled (height Y, width Z) while the armature is correct - the MESH vertices are exported raw (identity) while the ARMATURE is baked with the FBX conversion, the same mesh-vs-armature split as before. + +## 2026-11-10 — Vehicle settles (float 33 m -> 6 cm); drive still ~0 + +- **Two real fixes** (commit `319096d`): + 1. The skeletal mesh imports ROLLED (height along Y, width along Z) while the armature is + unrolled. The chassis box must therefore be built with swapped axes (`Box.Y = Extent.Z*1.8`, + `Box.Z = Extent.Y*0.55`) and centred at the rolled mesh's mid-height (`Box.Center.Z = + Bounds.Origin.Y`). This is what settled the car at Z 6 cm (was floating at 33 m). + 2. A diagnostic `if (SettleElapsed > 2.5f) Mover->SetComponentTickEnabled(false)` was firing for + every vehicle (not just zero-wheel ones) and cut the drive test (throttle 1-4 s). Now gated + on `Wheels.Num() == 0`. +- **Experiment that FAILED and was reverted**: moving the root bone to the centre of mass in + `vehicle_from_template.py` (root at `body.bound_box` centre) puts the wheel bones at NEGATIVE Z + (-54 cm below root) and the vehicle then FLOATS at spawn height (stays Z 304, never falls). + So the Chaos suspension in this rig wants a POSITIVE rest position (wheel bone above the root + bone). Root bone stays grounded at (0,0,0); the box offset to centre of mass is done in C++. +- **Remaining**: drive test reports `speed=1 cm/s` (no forward motion) and `travelled ~56 m` - a + horizontal drift during the fall. Wheels rest ~2 cm above the ground (wheel bone Z +34 vs wheel + radius 33) because the suspension rest position is measured against the root bone while the box + sits at +76. Next: make the wheels actually contact (align wheel radius to the bone, or correct + the rest position for the box offset) before re-testing direction. +- `GetWheelRestingPosition` = `LocateBoneOffset(BoneName, WheelClass.Offset + AdditionalOffset)`, + which is the wheel bone position relative to the ROOT BODY BONE - it does NOT account for + `Box.Center`. That offset is the root of the drive gap.