docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Struct GhostUpdateSystem

    System present only in client worlds, and responsible for:

    - updating the state of interpolated ghosts, by copying and intepolating data from the received snapshosts.

    - restore the predicted ghost state from the GhostPredictionHistoryState before running the next prediction loop (until new snapshot aren't received).

    - updating the PredictedGhost properties for all predicted ghost, by reflecting the latest received snapshot (see AppliedTick) and setting up the correct tick from which the ghost should start predicting (see PredictionStartTick

    Implements
    ISystem
    ISystemCompilerGenerated
    Inherited Members
    ValueType.Equals(object)
    ValueType.GetHashCode()
    object.Equals(object, object)
    object.GetType()
    object.ReferenceEquals(object, object)
    Namespace: Unity.NetCode
    Assembly: Unity.NetCode.dll
    Syntax
    [UpdateInGroup(typeof(GhostSimulationSystemGroup))]
    [UpdateAfter(typeof(GhostReceiveSystem))]
    [UpdateBefore(typeof(GhostSpawnClassificationSystemGroup))]
    [UpdateBefore(typeof(GhostInputSystemGroup))]
    [WorldSystemFilter(WorldSystemFilterFlags.ClientSimulation, WorldSystemFilterFlags.Default)]
    [BurstCompile]
    public struct GhostUpdateSystem : ISystem, ISystemCompilerGenerated

    Methods

    OnCreate(ref SystemState)

    Declaration
    public void OnCreate(ref SystemState systemState)
    Parameters
    Type Name Description
    SystemState systemState

    OnCreateForCompiler(ref SystemState)

    Declaration
    public void OnCreateForCompiler(ref SystemState state)
    Parameters
    Type Name Description
    SystemState state

    OnDestroy(ref SystemState)

    Declaration
    public void OnDestroy(ref SystemState systemState)
    Parameters
    Type Name Description
    SystemState systemState

    OnUpdate(ref SystemState)

    Declaration
    [BurstCompile]
    public void OnUpdate(ref SystemState systemState)
    Parameters
    Type Name Description
    SystemState systemState

    Implements

    Unity.Entities.ISystem
    Unity.Entities.ISystemCompilerGenerated
    In This Article
    Back to top
    Copyright © 2025 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)