這些定語的命名都很直白,顧名思義,不過,還是彙總一下吧
定語 | 修飾類型 | 功能 |
---|---|---|
[AlwaysUpdateSystem] | class | 總是更新系統 |
[BurstCompile] | struct | Burst編譯 |
[ReadOnly] | NativeArray | 隻讀模式,速度更快 |
[NativeDisableParallelForRestriction] | NativeArray | 原生禁用并行限制 |
[DisallowMultipleComponent] | class | 禁用多元件,被修飾的元件在每個實體上隻能有一個 |
[DisableAutoCreation] | class | 禁用自動建立,系統在ECS中會自動建立,用這個定語禁用 |
[UpdateInGroup] | class | 在某個系統組中更新,例:[UpdateInGroup(typeof(SimulationSystemGroup))] |
[UpdateBefore] | class | 在某個系統組之前更新,例:[UpdateBefore(typeof(SimulationSystemGroup))] |
[UpdateAfter] | class | 在某個系統組之後更新,例:[UpdateAfter(typeof(SimulationSystemGroup))] |