{!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} Struct NetworkSnapshotAck | Netcode for Entities | 1.1.0-pre.3
docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Struct NetworkSnapshotAck

    Client and Server Component. One per NetworkId entity, stores SnapshotAck and Ping info for a client.

    Implements
    IComponentData
    IQueryTypeParameter
    Inherited Members
    ValueType.Equals(object)
    ValueType.GetHashCode()
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetType()
    Namespace: Unity.NetCode
    Assembly: solution.dll
    Syntax
    public struct NetworkSnapshotAck : IComponentData, IQueryTypeParameter

    Fields

    Name Description
    DeviationRTT

    The round trip time average deviation from the EstimatedRTT. It is not a real standard deviation but an approximation using a simpler exponential smoothing average.

    EstimatedRTT

    The calculated exponential smoothing average connection round trip time.

    LastReceiveTimestamp

    The local time stamp at which the connection has received the last message. Used to calculate the elapsed "processing" time and reported to the remote peer to correctly update the round trip time.

    LastReceivedRemoteTime

    The last remote time stamp received by the connection. The remote time is sent back (via command for the client or in the snapshot for the server) and used to calculate the round trip time for the connection.

    LastReceivedSnapshotByLocal

    The field has a different meaning on the client vs on the server:

    Client: it is the last received ghost snapshot from the server.

    Server: record the last command tick that has been received. Used to discard either out of order or late commands.

    LastReceivedSnapshotByRemote

    The last snapshot (tick) received from the remote peer.

    For the client, it respresent the last received snapshot received from the server.

    For the server, it is the last acknowledge packet that has been received by client.

    NumLoadedPrefabs

    Server-only, the number of ghost prefabs loaded by remote client. On the client is not used and it is always 0.

    ReceivedSnapshotByLocalMask

    Client-only, a bitmask that indicates which of the last 32 snapshots has been received from the server. On the server it is always 0.

    RemoteInterpolationDelay

    The reported interpolation delay reported by the client (in number of ticks).

    ServerCommandAge

    How late the commands are received by server. Is a negative fixedPoint Q24:8 number that measure how many ticks behind the server was when he received the command, and it used as feedback by the NetworkTimeSystem to synchronize the ServerTick such that the client always runs ahead of the server. A positive number indicates that the client is running behind the server. A negative number indicates that the client is running ahead of the server.

    Methods

    Name Description
    IsReceivedByRemote(NetworkTick)

    Return true if the snapshot for tick tick has been received (from a client perspective) or acknowledged (from the servers POV)

    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)