docs.unity3d.com
    Show / Hide Table of Contents

    Struct CopyInputToCommandBuffer<TInputBufferData, TInputComponentData>

    For internal use only, helper struct that should be used to implement systems that copy the content of an IInputComponentData into the code-generated ICommandData buffer.

    Inherited Members
    ValueType.Equals(Object)
    ValueType.GetHashCode()
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetType()
    Namespace: Unity.NetCode
    Syntax
    [BurstCompile]
    public struct CopyInputToCommandBuffer<TInputBufferData, TInputComponentData>
        where TInputBufferData : struct, IInputBufferData where TInputComponentData : struct, IInputComponentData
    Type Parameters
    Name Description
    TInputBufferData
    TInputComponentData

    Methods

    Create(ref SystemState)

    Creates the internal component type handles, register to system state the component queries. Very important, add an implicity constraint for running the parent system only when the client is connected to the server, by requiring at least one connection with a NetworkId components. Should be called inside your the system OnCreate method.

    Declaration
    [BurstCompile]
    public EntityQuery Create(ref SystemState state)
    Parameters
    Type Name Description
    SystemState state
    Returns
    Type Description
    EntityQuery

    InitJobData(ref SystemState)

    Initialize the CopyInputToCommandBuffer by updating all the component type handles and create a a new CopyInputToCommandBuffer<TInputBufferData, TInputComponentData>.CopyInputToBufferJob instance.

    Declaration
    [BurstCompile]
    public CopyInputToCommandBuffer<TInputBufferData, TInputComponentData>.CopyInputToBufferJob InitJobData(ref SystemState state)
    Parameters
    Type Name Description
    SystemState state
    Returns
    Type Description
    CopyInputToCommandBuffer.CopyInputToBufferJob<>

    a new CopyInputToCommandBuffer<TInputBufferData, TInputComponentData>.CopyInputToBufferJob instance.

    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