I have a few objects that have a USceneComponent as the root, but now I decided that I wanted to add some projectile movement to them so I could throw them around. Because USceneComponent has no collision, in order to bypass that issue I thought it was possible to make the collision component stop its movement on hit, however no event was being generated. After doing a few tests, I noticed that some collision are detected while others are not.
Set-by-step example:
- create a fps example project
- add an actor blueprint
- add SceneComponent as root
- add a Cube and set the collision preset to “BlockAll”
- add a OnHit event to the cube, so it displays a text
- add projectile movement and set the gravity scale to a low value like 0.05
- instantiate the actor in the level
Result:
Hitting the actor with the character or the gun projectiles shows the OnHit text, but it doesn’t with everything else (i.e the floor mesh, even if it’s set to blockall as well).
Assuming this is intended, I could change the root to be a collision box thus making either physics or projectile movement work without the need for the hit event, but is there are other way around it?