docs.unity3d.com
    Show / Hide Table of Contents

    Method Execute

    Execute(ArchetypeChunk, Int32, Int32)

    Implement the Execute() function to perform a unit of work on an ArchetypeChunk.

    Declaration
    void Execute(ArchetypeChunk chunk, int chunkIndex, int firstEntityIndex)
    Parameters
    Type Name Description
    ArchetypeChunk chunk

    The current chunk.

    Int32 chunkIndex

    The index of the current chunk within the list of all chunks found by the Job's EntityQuery. Note that chunks are not processed in index order, except by chance.

    Int32 firstEntityIndex

    The index of the first entity in the current chunk within the list of all entities in all the chunks found by the Job's EntityQuery.

    Remarks

    The Job component system calls the Execute function once for each EntityArchetype found by the EntityQuery used to schedule the Job.

    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023