How can I make a collision event send an event while the particle goes through an object?

In the picture above, I have a bunch of rocks emitting from a source. I want the rocks to go through the ground, but still make an impact effect via collision event. I have no idea how to do this without the rocks stopping at the ground, or bouncing back up.

1 Like

Hey, collsions have some funky rules, but one of the things you could try is setting up a Niagara Module that you can use in the collision module’s “collision enabled” bool parameter.

You could try setting up some logic, either having the particle be a certain distance away from the init spawn position, or maybe with the particle age that would change the state of the “enable collision” bool.

Here is an example that I had used to flip the particle color, as well as change the bool paramter in the colision based on age of the particles.

You should also read up on GDF collsision, this has specific rules on how collisions are calculated.

I hope this helps.

1 Like

sorry, reading your question again, I’m now thinking you want your rock to collide once and then not longer render.

In the collision module, it writes out a bool parameter called"has collided".

In the sprite or mesh renderer, you have this feature called render visiblity. This sprite will render with the visiblie tag value that assigned to it.

What you want to do it is the particle update, set a new variable for the visiblity tag. Set the int32 to a bool, then set the “has collided” to the bool parameter.

Now, you should see the rocks no longer render after they have collided once.

not sure if this is what youre wanting, but maybe it is.

What I wanted was more along the lines of this GIF
You can see in the GIF that when the rocks hit the ground, they create a burst of particles via collision event. Though you can notice they instantly pop out of existence because I’m making it kill the particles on collision so they dont bounce back up, but what I want it to do is to send a collision event when they would have collided, but have the rocks still go inside/through the ground.

Any reason on why your doing a death event, rather than a collision event?

to stop things from bouncing you can change the restitution value or the max collision events.

I’m using a collision event for it, not a death event. I want the rocks to go through the ground, not just not bounce

If you don’t really care about the actual collision response then instead of using the collision module you could use a scratch pad and do the collision trace from the particle position along the velocity vector and identify the intersection yourself.

Another option is you could keep the collision but scale the particle down on each bounce where it spawns the extra particles so it appears to lose volume as it breaks on each impact.

Here ya go, I think what you are looking for is in this video:

1 Like