CopyEntitiesFrom(EntityManager, NativeArray<Entity>, NativeArray<Entity>)
Instantiates / Copies all entities from srcEntityManager and copies them into this EntityManager. Entity references on components that are being cloned to entities inside the srcEntities set are remapped to the instantiated entities. References to entities outside the srcEntities set become Entity.Null.
阅读时间1 分钟最后更新于 4 天前
Definition
- Type: Method
- Namespace: Unity.Entities
- Assembly: UnityEngine.EntitiesModule
[ExcludeFromBurstCompatTesting("Accesses managed component store")]public void CopyEntitiesFrom(EntityManager srcEntityManager, NativeArray<Entity> srcEntities, NativeArray<Entity> outputEntities = default)
Parameters
The EntityManager to copy from
Entities in the srcEntityManager that have component with Entity references
New entities that have been remapped from srcEntities