Class NetworkVariableAnticipationComponent
Inheritance
NetworkVariableAnticipationComponent
Inherited Members
Object.FindObjectsByType<T>(FindObjectsSortMode)
Object.FindObjectsByType<T>(FindObjectsInactive, FindObjectsSortMode)
Object.FindFirstObjectByType<T>()
Object.FindAnyObjectByType<T>()
Object.FindFirstObjectByType<T>(FindObjectsInactive)
Object.FindAnyObjectByType<T>(FindObjectsInactive)
Namespace: Unity.Netcode.RuntimeTests
Assembly: Unity.Netcode.RuntimeTests.dll
Syntax
public class NetworkVariableAnticipationComponent : NetworkBehaviour
Fields
ReanticipateOnAnticipationFailVariable
Declaration
public AnticipatedNetworkVariable<float> ReanticipateOnAnticipationFailVariable
Field Value
Type | Description |
---|---|
AnticipatedNetworkVariable<float> |
SmoothOnAnticipationFailVariable
Declaration
public AnticipatedNetworkVariable<float> SmoothOnAnticipationFailVariable
Field Value
Type | Description |
---|---|
AnticipatedNetworkVariable<float> |
SnapOnAnticipationFailVariable
Declaration
public AnticipatedNetworkVariable<int> SnapOnAnticipationFailVariable
Field Value
Type | Description |
---|---|
AnticipatedNetworkVariable<int> |
SnapRpcResponseReceived
Declaration
public bool SnapRpcResponseReceived
Field Value
Type | Description |
---|---|
bool |
Methods
OnReanticipate(double)
Invoked when the network anticipates a change in the state of the object. This method can be used to handle any logic that needs to occur when the network predicts a state change.
Declaration
public override void OnReanticipate(double lastRoundTripTime)
Parameters
Type | Name | Description |
---|---|---|
double | lastRoundTripTime | The last round trip time in seconds. |
Overrides
SetReanticipateValueRpc(float)
Declaration
[Rpc(SendTo.Server)]
public void SetReanticipateValueRpc(float f)
Parameters
Type | Name | Description |
---|---|---|
float | f |
SetSmoothValueRpc(float)
Declaration
[Rpc(SendTo.Server)]
public void SetSmoothValueRpc(float f)
Parameters
Type | Name | Description |
---|---|---|
float | f |
SetSnapValueResponseRpc(RpcParams)
Declaration
[Rpc(SendTo.SpecifiedInParams)]
public void SetSnapValueResponseRpc(RpcParams rpcParams)
Parameters
Type | Name | Description |
---|---|---|
RpcParams | rpcParams |
SetSnapValueRpc(int, RpcParams)
Declaration
[Rpc(SendTo.Server)]
public void SetSnapValueRpc(int i, RpcParams rpcParams = default)
Parameters
Type | Name | Description |
---|---|---|
int | i | |
RpcParams | rpcParams |