Fix engine client flags not being updated under some conditions

The flags were only being updated based on rather arbitrary conditions, so they could never reset to zero or reduced.
The flags are now always updated. The flags are only used in the output of the `status` command.
This commit is contained in:
Robert Müller 2022-06-30 23:46:59 +02:00
parent 747fe9308f
commit 6d0806f99d
2 changed files with 2 additions and 4 deletions

View file

@ -548,7 +548,6 @@ void CServer::SetClientFlags(int ClientID, int Flags)
if(ClientID < 0 || ClientID >= MAX_CLIENTS || m_aClients[ClientID].m_State < CClient::STATE_READY)
return;
if(Flags > m_aClients[ClientID].m_Flags)
m_aClients[ClientID].m_Flags = Flags;
}

View file

@ -529,7 +529,6 @@ void CPlayer::OnDirectInput(CNetObj_PlayerInput *NewInput)
if(Server()->IsSixup(m_ClientID))
NewInput->m_PlayerFlags = PlayerFlags_SevenToSix(NewInput->m_PlayerFlags);
if(NewInput->m_PlayerFlags)
Server()->SetClientFlags(m_ClientID, NewInput->m_PlayerFlags);
AfkTimer();