Photon Fusion 2.1.1

TickRate.Selection Struct Reference

Represents a selection of tick rates for client and server. More...

Public Member Functions

bool ConvertObsoleteIndicesToIntervals ()
 If this selection is index-based (old format), converts the values of the obsolete index fields to intervals.
ValidateResult Validate ()
 Validates the tick rates in the Selection.

Public Attributes

int Client
 The tick rate used by clients and the server.
int ClientSendIndex
 The send tick rate for the client, as a ratio of the Client Tick Rate.
int ClientSendInterval
 The send interval for the client, used to calculate the Client Send Rate from the Client Tick Rate.
int ServerIndex
 Always equal to the Client Tick Rate.
int ServerSendIndex
 The send tick rate for the server, as a ratio of the Client Tick Rate.
int ServerSendInterval
 The send interval for the server, used to calculate the Server Send Rate from the Client Tick Rate.
int ServerTickInterval
 The tick interval for the server, used to calculate the Server Tick Rate from the Client Tick Rate.

Detailed Description

Represents a selection of tick rates for client and server.

Member Function Documentation

◆ Validate()

ValidateResult Validate ( )

Validates the tick rates in the Selection.

Returns
A ValidateResult that indicates the result of the validation.

The Selection is valid if:

  • The client tick rate is within the valid range.
  • The server tick interval in the Selection is a divisor of the client tick rate and is within the range of available intervals.
  • The server send interval in the Selection is a divisor of the client tick rate and is within the range of available intervals.
  • The client send interval in the Selection is a divisor of the client tick rate and is within the range of available intervals.
  • The server send interval in the Selection is not smaller than the server tick interval.