Skip to content

Commit

Permalink
Don't send slowfast if velocities are zero
Browse files Browse the repository at this point in the history
  • Loading branch information
justinshannon committed Jan 7, 2022
1 parent cd5f314 commit 57504ef
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion client/src/network/networkmanager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -586,7 +586,9 @@ namespace xpilot
void NetworkManager::OnSlowPositionTimerElapsed()
{
SendSlowPositionPacket();
SendFastPositionPacket();
if(!PositionalVelocityIsZero(m_userAircraftData)) {
SendFastPositionPacket();
}
}

void NetworkManager::OnFastPositionTimerElapsed()
Expand Down

0 comments on commit 57504ef

Please sign in to comment.