Search Unity

Question Why does EntityCommandBuffer.ParallelWriter lack a SetEnabled method?

Discussion in 'Entity Component System' started by chemicalcrux, Oct 19, 2022.

  1. chemicalcrux

    chemicalcrux

    Joined:
    Mar 16, 2017
    Posts:
    720
    Is there a reason that EntityCommandBuffer.ParallelWriter doesn't have the SetEnabled method?

    I can recreate it by checking if the target entity has a LinkedEntityGroup and iterating over its elements. Perhaps this isn't safe, since the child entities could be getting enabled and disabled by other parallel jobs?