Photon Fusion
2.1.1
Public Types | |
| enum | Selection |
| The settings to use. More... | |
| enum | Unit |
| The base quantity of a setting. More... | |
Public Member Functions | |
| void | SanityCheck () |
Public Attributes | |
| int | ClientMaxResimsPerFrame = DEFAULT_MAX_RESIMS_PER_FRAME |
| bool | ClientsCanAddInputDelayToLimitResims = false |
| Selection | InputDelaySettings = Selection.Default |
| int | InputReceiveBufferDelayAdded = DEFAULT_INPUT_BUFFER_DELAY_ADDED |
| Unit | InputReceiveBufferDelayAddedUnit = DEFAULT_INPUT_BUFFER_DELAY_ADDED_UNIT |
| Selection | InputReceiveBufferSettings = Selection.Default |
| float | MaxLateInputs = DEFAULT_MAX_LATE_INPUTS_PERCENTILE |
| float | MaxLateSnapshots = DEFAULT_MAX_LATE_SNAPSHOTS_PERCENTILE |
| int | MinimumInputDelay = DEFAULT_MINIMUM_INPUT_DELAY |
| Unit | MinimumInputDelayUnit = DEFAULT_MINIMUM_INPUT_DELAY_UNIT |
| float | RedundantInputs = DEFAULT_REDUNDANT_INPUTS |
| float | RedundantSnapshots = DEFAULT_REDUNDANT_SNAPSHOTS |
| int | StateReceiveBufferDelayAdded = DEFAULT_STATE_BUFFER_DELAY_ADDED |
| Unit | StateReceiveBufferDelayAddedUnit = DEFAULT_STATE_BUFFER_DELAY_ADDED_UNIT |
| Selection | StateReceiveBufferSettings = Selection.Default |
A collection of settings that control input delay as well as how long inputs and snapshots are buffered to mitigate loss.
These settings influence how far ahead and behind the client's local and remote time frames are, respectively, relative to the latest snapshot.
| enum Selection |
| enum Unit |
| int ClientMaxResimsPerFrame = DEFAULT_MAX_RESIMS_PER_FRAME |
The (soft) limit on the number of resimulations per frame.
The default value is -1, which means "no limit".
| bool ClientsCanAddInputDelayToLimitResims = false |
If enabled, clients will dynamically adjust their input delay to (soft) limit the number of resimulations per frame.
| Selection InputDelaySettings = Selection.Default |
In client-server mode, clients can use input delay to reduce the number of resimulations per frame.
We recommend leaving the default values unchanged unless you fully understand their impact on client behavior.
| int InputReceiveBufferDelayAdded = DEFAULT_INPUT_BUFFER_DELAY_ADDED |
This parameter sets the added amount.
Its default value is 0. Increasing this increases the client's simulation time offset.
| Unit InputReceiveBufferDelayAddedUnit = DEFAULT_INPUT_BUFFER_DELAY_ADDED_UNIT |
This parameter sets the unit for the added amount.
| Selection InputReceiveBufferSettings = Selection.Default |
Clients want to send inputs early enough so that "most" of them are received before they are needed. Fusion clients do this by figuring out how late "most" input packets could arrive and then moving time into the future to compensate (forming a buffer on the server).
Clients calculate the time offset as:
target = ((offset for MaxLateInputs percentile) * redundantInputs) + added
We recommend leaving the default values unchanged unless you fully understand their impact on client behavior.
| float MaxLateInputs = DEFAULT_MAX_LATE_INPUTS_PERCENTILE |
The maximum percentage of inputs that should ever arrive late because of jitter.
Decreasing this increases the client's simulation time offset.
| float MaxLateSnapshots = DEFAULT_MAX_LATE_SNAPSHOTS_PERCENTILE |
The maximum percentage of snapshots that should ever arrive late because of jitter.
Decreasing this increases the client's interpolation delay.
| int MinimumInputDelay = DEFAULT_MINIMUM_INPUT_DELAY |
This parameter sets a minimum input delay for all players.
Its default value is 0.
| Unit MinimumInputDelayUnit = DEFAULT_MINIMUM_INPUT_DELAY_UNIT |
This parameter sets the unit for the minimum amount.
| float RedundantInputs = DEFAULT_REDUNDANT_INPUTS |
The number of consecutive, additional, chances each input should have to reach the server before it's needed. E.g. when this is 1 each input has two chances to reach the server on time.
Increasing this increases the client's simulation time offset.
| float RedundantSnapshots = DEFAULT_REDUNDANT_SNAPSHOTS |
The number of consecutive snapshots a client should be able to miss without disrupting their interpolation.
Increasing this increases the client's interpolation delay.
| int StateReceiveBufferDelayAdded = DEFAULT_STATE_BUFFER_DELAY_ADDED |
This parameter sets the added amount.
Its default value is 0.
| Unit StateReceiveBufferDelayAddedUnit = DEFAULT_STATE_BUFFER_DELAY_ADDED_UNIT |
This parameter sets the unit for the added amount.
| Selection StateReceiveBufferSettings = Selection.Default |
Clients want to delay rendering remote objects enough so that "most" of their state updates are received before they are needed. Fusion clients do this by figuring out how late "most" snapshot packets could arrive and then moving remote time into the past to compensate (forming a buffer on the client).
Clients calculate the target buffer delay as:
target = ((offset for the MaxLateSnapshots percentile) * (redundantSnapshots + 1)) + added
Note: the '+1' in the calculation above is due to needing a pair of snapshops to interpolated between before we have any redundancy. In contrast only a single input is required.
We recommend leaving the default values unchanged unless you fully understand their impact on client behavior.