Soft bodies don't seem to work with scaled compound shapes
Closed this issue · 1 comments
mihe commented
This is a strange issue that I haven't been able to reproduce with just a simple scaled shape, but I have a snapshot that should hopefully suffice: jolt_snapshot_2024-02-02_21-18-30_63008.zip
The scene structure is essentially this:
- Body (Kinematic)
- SphereShape (unimportant empty-shaped sensor, using the sphere placeholder)
- Body (Static)
- ScaledShape (1.25x)
- StaticCompoundShape
- BoxShape (Floor)
- BoxShape (Wall)
- BoxShape (Wall)
- BoxShape (Wall)
- BoxShape (Wall)
- StaticCompoundShape
- ScaledShape (1.25x)
If you add any soft body to LoadSnapshotTest::Initialize
, like this one:
mBodyInterface->CreateAndAddSoftBody(SoftBodyCreationSettings(SoftBodyCreator::CreateCube(), RVec3(0.0f, 10.0f, 0.0f), Quat::sIdentity(), Layers::MOVING), EActivation::Activate);
You should see something like this:
Samples_XhYGVTLn6e.mp4
jrouwe commented
Thanks for the good repro! It failed to properly take the center of mass into account.