docs.unity.cn
    Show / Hide Table of Contents

    Method CopyFromComponentDataArray

    CopyFromComponentDataArray<T>(NativeArray<T>)

    Copies the component values in the provided NativeArray to the entities matching this query.

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

    The list of values to write to the 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.

    Exceptions
    Type Condition
    InvalidOperationException

    Thrown if T is not part of the query.

    Back to top Copyright © 2022 Unity Technologies
    Generated by DocFX
    on 04 August 2022
    Terms of use