jrouwe / JoltPhysics

A multi core friendly rigid body physics and collision detection library. Written in C++. Suitable for games and VR applications. Used by Horizon Forbidden West.
MIT License
6.65k stars 438 forks source link

[Feature request] Implement gravity override for all bodies and not just vehicle constraints #1230

Closed PiMoNFeeD closed 2 months ago

PiMoNFeeD commented 2 months ago

In my project, I want to be able to override gravity on per-object basis, and while I could mess with gravity factor, that won't help when my global gravity shifts if I want my overridden gravity to stay the same. That would also help make vehicle constraint implementation cleaner, as that won't need to do the hack of setting vehicle gravity factor to 0 and instead applying it manually.