Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice
  3. Dismiss Notice

Question Particle System and Trigger Colliders

Discussion in 'Physics' started by mattbru2, Dec 1, 2022.

  1. mattbru2

    mattbru2

    Joined:
    Mar 3, 2021
    Posts:
    18
    I can't post my whole project, but basically imagine a trigger collider (10 meter sphere) around the player. If a particle enters that trigger collider, I want to do something (like a pop up that says "vision is obscured!"). I don't want the particles to actually collide and be moved by this collider, thus it is a trigger.

    I cannot get the OnParticleCollision to activate when the collider is a trigger. I've found a few posts/youtube videos saying this is true, but I haven't found any Unity documentation on it.

    Is there a way to do this?
     
  2. MelvMay

    MelvMay

    Unity Technologies

    Joined:
    May 24, 2013
    Posts:
    11,675
    The physics team don't deal with this. If you have a particle question then it's best to add a tag of "particles" so they can see it.

    It's right there in the particle docs and the first link in a Google Search: https://docs.unity3d.com/Manual/PartSysTriggersModule.html

    Just like physics itself, there's a distinction between a collision and trigger.
     
  3. mattbru2

    mattbru2

    Joined:
    Mar 3, 2021
    Posts:
    18

    So in my actual sim I have dozens of short lived particle systems being created at any point and potentially hundreds of dynamically created colliders. The trigger module seems to suggest that I would have to keep track of all of my particle systems and then register any dynamically created collider against all of them? I would hope there is a way to do this with layers as is done with the collider module?
     
  4. MelvMay

    MelvMay

    Unity Technologies

    Joined:
    May 24, 2013
    Posts:
    11,675
    I'm not a particle dev. As I said, you should use the particles tag to try to get a particle devs attention. The physics teams did not create the particles modules etc. Personally, I've never used them.

    Sorry.
     
  5. richardkettlewell

    richardkettlewell

    Unity Technologies

    Joined:
    Sep 9, 2015
    Posts:
    2,295
    Sorry we only have an option for a list of colliders in the trigger module.
     
    MelvMay likes this.