RigsOfRods / rigs-of-rods

Main development repository for Rigs of Rods soft-body physics simulator
https://www.rigsofrods.org
GNU General Public License v3.0
1.01k stars 175 forks source link

Parser corrections (nodes2, forset, sectionconfig) #2922

Closed ohlidalp closed 2 months ago

ohlidalp commented 2 years ago

I reverted the parser to the original (2013 and earlier) sequential mechanic. That means things that one worked are back, but so are some restrictions that didn't apply in the time between.

ALPHA STATUS - Features and restrictions can still change.

Returning features:

Bugfixes:

Improvements:

ohlidalp commented 1 year ago

RESOLVED: it was a stupid typo regarding float beam_t::maxnegstress - initial spawn set it to positive value (wrong), resetting set it to negative value (correct). Kudos to @tritonas00 for pinpointing what's different.

I'm wrestling a real mystery.... Honda Accord (download: https://forum.rigsofrods.org/resources/honda-accord.281/) blows up, even though all N/B values are exactly the same as in my v0.4.0.7 retro-build (see README). I made a debug dump from both versions (option diag_actor_dump) and compared with diff tool... spring, mass, damp, positions, refLen, bounding, short/long bounds... all equivalent. And it doesn't happen after repair using Backspace key, only at initial spawn. The GIF is slow-motion with ratio 0.07 btw. parserRevertHondaAccordMystery-w300 In the retrobuild, it just works. Both spawn and Backspace-repair do the same. It looks like I'm going to have to take a detour and create a diagnostic tool which would let me inspect the simulation step-by-step. UPDATE: Also added wings (FlexAirfoil) to the debug dump - no luck. UPDATE2: Added fusedrag and turbulent drag to the dump - again, no luck. UPDATE3: Added hydros and shocks - no luck.

ohlidalp commented 1 year ago

Purpose: My great personal amend - to make the vehicle parsing/spawning work at least as well as in v0.4.0.7 (year 2013, before I started working on it).

Estimate: 2 man days. Pending review...

tritonas00 commented 1 year ago
ohlidalp commented 1 year ago

The Austin Mini is posessed by fusedrag autocalc which is misplaced - it needs to be placed after nodes, otherwise it produces garbage. This is a classic limitation of the old parser which wasn't effective in between 2013-2023 but now is back - along with all the other "B must come after A" limitations, actually. The Mini must have been either updated in between 2013-2023 when the order didn't matter, or it may have used old-style fusedrag before. Either way, both the mod and the docs must be corrected:

ohlidalp commented 1 year ago

The Ford Mustang has managedmaterials after the wheels and some flexbodies (rear wing...) that use them. Again, this didn't matter between 2013-2023 but now it's back. I updated the PR summary to mention this.

CuriousMike56 commented 1 year ago

Current issues I've noticed so far:

ohlidalp commented 2 months ago

Closing as stale and no longer mergeable. Also the problem it solves isn't really visible.