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

how to do collision/trigger exit job?

Discussion in 'Physics for ECS' started by Conspiracy, Jan 15, 2020.

  1. Conspiracy


    Oct 22, 2016
    so I the current way I know to do collision or trigger is with a trigger/collision events job but as far as I know that basically just trigger/collision stay. Is there a way to do collision/trigger exit or even enter?

    code examples would be appreciated. Thank you
  2. Adam-Mechtley



    Feb 5, 2007
    There is not yet a "built-in" mechanism as such, in part because it introduces state information, and also because the details depend on how you want to organize your data, whether you want to change archetypes, and so on.

    One possibility is shown in the trigger event sample where you basically track the frame number:
    Conspiracy likes this.