Struct CommandArrivalStatistics
Stores statistics pertaining to the frequency and reliability of received commands from a client. Thus, only valid on the server. May help you diagnose input/command issues.
Inherited Members
Namespace: Unity.NetCode
Assembly: Unity.NetCode.dll
Syntax
public struct CommandArrivalStatistics
Fields
AvgCommandPayloadSizeInBits
Rolling average of the payload size of the received input (i.e. command) packets, not including Transport headers.
Declaration
public float AvgCommandPayloadSizeInBits
Field Value
Type | Description |
---|---|
float |
NumArrivedTooLate
The number of individual commands that didn't arrive in time to be used. Therefore, they were pointless to send. A single netcode command packet will typically contain multiple commands, for redundancy.
Declaration
public uint NumArrivedTooLate
Field Value
Type | Description |
---|---|
uint |
Remarks
Use this field to optimize NumAdditionalCommandsToSend.
NumCommandPacketsArrived
The total count of command PACKETS that arrived. A single netcode command packet will typically contain multiple commands, for redundancy.
Declaration
public int NumCommandPacketsArrived
Field Value
Type | Description |
---|---|
int |
NumCommandsArrived
The total count of commands that arrived. A single netcode command packet will typically contain multiple commands, for redundancy.
Declaration
public uint NumCommandsArrived
Field Value
Type | Description |
---|---|
uint |
NumRedundantResends
How many commands that arrived were resends of commands we already received?
Declaration
public uint NumRedundantResends
Field Value
Type | Description |
---|---|
uint |
Properties
ArrivedTooLatePercent
Percentage of commands arrived too late.
Declaration
public double ArrivedTooLatePercent { get; }
Property Value
Type | Description |
---|---|
double |
AvgCommandsPerPacket
Average commands packed into each packet.
Declaration
public double AvgCommandsPerPacket { get; }
Property Value
Type | Description |
---|---|
double |
ResendPercent
Percentage of commands that were resent redundantly.
Declaration
public double ResendPercent { get; }
Property Value
Type | Description |
---|---|
double |
Methods
ToFixedString()
Debug string.
Declaration
public FixedString128Bytes ToFixedString()
Returns
Type | Description |
---|---|
FixedString128Bytes | A formatted debug string. |