I’m fairly new to DOTS, and was just trying to learn about utilizing the job system.
Specifically I wanted to benefit from the job system while while filtering both all, any and none of component types. The IJobChunk struct works beautifully for this since It is guaranteed to return entities with the same archetype. I was just wondering what is the best way to add and remove components using it in a job. Is it possible (or advisable) to pass Entities to an entityCommandBuffer with it?
IJobForEach has access to entities implicitly, but how would one go about accessing Entities using an IJobChunk?
The manual doesn’t mention much. And my searches have come up short.
https://docs.unity3d.com/Packages/com.unity.entities@0.1/manual/chunk_iteration_job.html
This paragraph in the manual alludes to what I want, but I would love for it to be elaborated upon.