This commit is contained in:
miwarnec 2024-11-05 12:59:36 +01:00
parent e70be519e7
commit ae1edff268

View File

@ -511,14 +511,17 @@ void UpdateServerBaseline(double localTime)
byte frameCount = (byte)Time.frameCount; // perf: only access Time.frameCount once!
if (syncPosition && syncRotation)
{
// no unreliable redundancy: baseline is reliable
RpcServerToClientBaseline_PositionRotation(frameCount, position, rotation);
}
else if (syncPosition)
{
// no unreliable redundancy: baseline is reliable
RpcServerToClientBaseline_Position(frameCount, position);
}
else if (syncRotation)
{
// no unreliable redundancy: baseline is reliable
RpcServerToClientBaseline_Rotation(frameCount, rotation);
}
@ -700,14 +703,17 @@ void UpdateClientBaseline(double localTime)
byte frameCount = (byte)Time.frameCount; // perf: only access Time.frameCount once!
if (syncPosition && syncRotation)
{
// no unreliable redundancy: baseline is reliable
CmdClientToServerBaseline_PositionRotation(frameCount, position, rotation);
}
else if (syncPosition)
{
// no unreliable redundancy: baseline is reliable
CmdClientToServerBaseline_Position(frameCount, position);
}
else if (syncRotation)
{
// no unreliable redundancy: baseline is reliable
CmdClientToServerBaseline_Rotation(frameCount, rotation);
}