This was really tricky for me to figure out. I have an explosive barrel which needs:
- gravity
- physics simulation
- hit events
Here 1) and 2) are such that the player may push the barrel around (gently) in the world without it going BOOM.
And 3) is such that when player shoots at the barrel it goes BOOM.
But as we have seen, “simulate physics” in incompatible with “collision enabled”. But without “simulate physics” gravity doesn’t work. And without “collision enabled” I can never trigger hit events from the player’s projectiles.
My ONLY solution so far is to create a custom Object Channel “Projectile” inside Project Settings → Engine - >Collision. My explosive barrel’s root component is a static mesh with SimulateGraphics=true, EnableGravity=true, and for Collision ignore Projectile objects. The barrel then has a Capsule Component which does not simulate graphics, but instead has Collision Enabled (Query and Physics) and blocks Projectile objects.
I also have OnComponentHit event binding on the Capsule Component.