Merge pull request #8220 from Zwelf/pr-practice-disallow-save

Disallow `/save` on teams with practice enabled
This commit is contained in:
Dennis Felsing 2024-04-16 01:11:13 +00:00 committed by GitHub
commit 88ff8204db
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -290,6 +290,8 @@ void CScore::SaveTeam(int ClientId, const char *pCode, const char *pServer)
int Team = pController->Teams().m_Core.Team(ClientId);
if(pController->Teams().GetSaving(Team))
return;
if(pController->Teams().IsPractice(Team))
return;
auto SaveResult = std::make_shared<CScoreSaveResult>(ClientId);
SaveResult->m_SaveId = RandomUuid();