Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Have a look at our Games Focus blog post series which will show what Unity is doing for all game developers – now, next year, and in the future.
    Dismiss Notice

ITriggerEventsJob questions

Discussion in 'DOTS Physics' started by felipin, Dec 15, 2019.

  1. felipin


    Nov 18, 2015
    Is there any concept like "every TriggerEvent created from a PhysicsShape is processed at the same thread"? If I wanna change a component from my trigger entity, is there any safe way to do it?
  2. Ryuuguu


    Apr 14, 2007
    What I did was fill a hashmap <Entity,dataneededForChange> in the ITriggerEventsJob and then in a second job of type withEntityJob checked the hashMap[entity] and made the changes there. Since they were all SetComponentData I was able to this all in the second job on multiple threads.