Quick answer: Use Continuous collision detection on fast hitters, lower Project Settings → Physics → Sleep Threshold, and call rb.WakeUp() from explosion / area-effect code. Sleeping bodies don’t respond to triggers that don’t physically contact.
A pile of crates rests on the floor. You shoot one. It explodes outward; the others sit there. PhysX considers them sleeping and the explosion didn’t register as a touch.
The Symptom
Settled physics objects don’t respond to forces, explosions, or fast projectiles. They’ve been still long enough that PhysX deactivated their simulation. Once nudged, they behave normally.
What Causes This
PhysX puts Rigidbodies with kinetic energy below sleepThreshold to sleep. Sleeping bodies skip integration; they only wake on contact with an active body. An explosion that only adds force via AddExplosionForce won’t wake them because no contact happens.
The Fix
Step 1: Wake explicitly when applying area forces.
public void Explode(Vector3 center, float radius, float force)
{
var hits = Physics.OverlapSphere(center, radius);
foreach (var h in hits)
{
if (h.attachedRigidbody == null) continue;
h.attachedRigidbody.WakeUp();
h.attachedRigidbody.AddExplosionForce(force, center, radius);
}
}
WakeUp() before the force ensures the body is integrating before the impulse is applied.
Step 2: Continuous collision on fast objects. Bullet Rigidbody → Collision Detection → Continuous Speculative (cheap, default-ish) or Continuous Dynamic (precise, costlier). Tunneling through sleeping targets stops.
Step 3: Lower sleepThreshold for active scenes. Project Settings → Physics → Sleep Threshold = 0.001 keeps bodies awake longer. Trade more CPU for fewer mysteriously-frozen objects.
Per-body Sleep Tuning
For specific bodies that should never sleep:
void FixedUpdate()
{
if (rb.IsSleeping())
rb.WakeUp();
}
Cost is one boolean per FixedUpdate. Pin only the few bodies that justify it.
Detect Sleep Programmatically
Useful for puzzle games (“is the marble settled?”):
if (rb.IsSleeping())
AwardPoints();
Wait one or two FixedUpdates after expected motion before checking, since PhysX may not flip to sleep immediately.
Verifying
Drop a stack of objects, wait until they settle. Trigger an explosion at the base. With the fix, the stack scatters; without, only the directly-touched ones move.
“Wake before applying area force. Continuous collision for fast hits. Sleep threshold tuned for the scene.”
Related Issues
For Rigidbody falling through floor, see falling through floor. For trigger exit on disable, see trigger exit.
WakeUp. Continuous. The pile scatters.