Current physics engine and world representation: - Original ODE 0.5 with original modifications made by GSC, with few changes merged from ODE 0.6 by OpenXRay. - Used as a backend by xrPhysics, which provides abstract physics interface. - OPCODE 1.2 with changes by OpenXRay contributors to support caching. - Used as a backend by xrCDB, which provides abstract collision detection interface. Proposed better alternative: - Jolt Physics instead of both ODE and OPCODE, unified physics world representation. - xrCDB is a candidate for removal, while it's functionality is to be replaced or moved to xrPhysics module. Reasoning: - ODE 0.5 is not made for x64, nor for multithreading. - OPCODE is faster than ODE, but Jolt possible can be even faster, removing the need for separate collision detection module. - Jolt supports x64 and has been made with multithreading in mind, and it also provides many more advanced features. Possible implementation plan: - [ ] Optionally update OPCODE to https://github.com/solbjorn/OpCoDe (see https://github.com/OpenXRay/xray-16/issues/877#issuecomment-2637054334). - The new versions works better and it should be faster to integrate it, so that users get performance improvements sooner. - [ ] Replace OPCODE with Jolt. - [ ] Make sure everything in the game works properly. - [ ] Replace ODE with Jolt.
Activity
Xottab-DUTY commentedon Sep 14, 2026
@xxcactussell has already replaced OPCODE with Jolt in his https://github.com/xxcactussell/unxray fork. We can look at it as a reference.