mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 10:08:18 +00:00
save doesn't create ranks accidentally anymore (fixes #73)
This commit is contained in:
parent
6bcf2bbe0d
commit
e29571dd73
|
@ -1677,7 +1677,7 @@ void CSqlScore::SaveTeamThread(void *pUser)
|
|||
char aBuf2[256];
|
||||
str_format(aBuf2, sizeof(aBuf2), "Team successfully saved. Use '/load %s' to continue", OriginalCode);
|
||||
pData->m_pSqlData->GameServer()->SendChatTeam(Team, aBuf2);
|
||||
((CGameControllerDDRace*)(pData->m_pSqlData->GameServer()->m_pController))->m_Teams.KillTeam(Team);
|
||||
((CGameControllerDDRace*)(pData->m_pSqlData->GameServer()->m_pController))->m_Teams.KillSavedTeam(Team);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -635,8 +635,11 @@ void CGameTeams::SetTeamLock(int Team, bool Lock)
|
|||
m_TeamLocked[Team] = Lock;
|
||||
}
|
||||
|
||||
void CGameTeams::KillTeam(int Team)
|
||||
void CGameTeams::KillSavedTeam(int Team)
|
||||
{
|
||||
// Set so that no finish is accidentally given to some of the players
|
||||
ChangeTeamState(Team, CGameTeams::TEAMSTATE_OPEN);
|
||||
|
||||
for (int i = 0; i < MAX_CLIENTS; i++)
|
||||
if(m_Core.Team(i) == Team && GameServer()->m_apPlayers[i])
|
||||
GameServer()->m_apPlayers[i]->KillCharacter(-2);
|
||||
|
|
|
@ -80,7 +80,7 @@ public:
|
|||
void SetCpActive(CPlayer* Player, int CpActive);
|
||||
void OnTeamFinish(CPlayer** Players, unsigned int Size);
|
||||
void OnFinish(CPlayer* Player);
|
||||
void KillTeam(int Team);
|
||||
void KillSavedTeam(int Team);
|
||||
bool TeeFinished(int ClientID)
|
||||
{
|
||||
return m_TeeFinished[ClientID];
|
||||
|
|
Loading…
Reference in a new issue