{!See https://docs.google.com/document/d/1takg_GmIBBKKTj-GHZCwzxohpQz7Bhekivkk72kYMtE/edit for reference implementation of OneTrust, dataLayer and GTM} {!OneTrust Cookies Consent} {!OneTrust Cookies Consent end} {!dataLayer initialization push} {!dataLayer initialization push end} {!Google Tag Manager} {!Google Tag Manager end} Method CopyFromComponentDataArray | Entities | 1.2.0-exp.3
docs.unity.cn
Search Results for

    Show / Hide Table of Contents

    Method CopyFromComponentDataArray

    CopyFromComponentDataArray<T>(NativeArray<T>)

    Copies the values of component type T in a NativeArray into the entities matched by this query.

    Declaration
    [GenerateTestsForBurstCompatibility(GenericTypeArguments = new Type[] { typeof(BurstCompatibleComponentData) })]
    public void CopyFromComponentDataArray<T>(NativeArray<T> componentDataArray) where T : unmanaged, IComponentData
    Parameters
    Type Name Description
    NativeArray<T> componentDataArray

    The values to copy into the matching entities.

    Type Parameters
    Name Description
    T

    The component type.

    Remarks

    This version of the function blocks on all registered jobs that access any of the query components. For a non-blocking variant, see CopyFromComponentDataListAsync<T>(NativeList<T>, out JobHandle)

    Exceptions
    Type Condition
    InvalidOperationException

    Thrown if T is not part of the query.

    In This Article
    Back to top
    Copyright © 2023 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)