docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method CopyAndReplaceEntitiesFrom

    CopyAndReplaceEntitiesFrom(EntityManager, NativeArray<EntityRemapInfo>)

    Copies all entities from srcEntityManager and replaces all entities in this EntityManager

    Declaration
    [Obsolete("This function only works in a narrow set of circumstances and has semantics that differ from a regular copy.", false)]
    [ExcludeFromBurstCompatTesting("Accesses managed component store")]
    public void CopyAndReplaceEntitiesFrom(EntityManager srcEntityManager, NativeArray<EntityRemapUtility.EntityRemapInfo> remap = default)
    Parameters
    Type Name Description
    EntityManager srcEntityManager

    The EntityManager to copy from

    NativeArray<EntityRemapUtility.EntityRemapInfo> remap
    Remarks

    Guarantees that the chunk layout and order of the entities will match exactly, thus this method can be used for deterministic rollback. This feature is not complete and only supports a subset of the EntityManager features at the moment:

    • Currently it copies all CleanupComponents (They should not be copied)
    • Currently does not support class based components
    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)