mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 10:08:18 +00:00
Turn off practice mode and reset practice wishes when locked team dies
This commit is contained in:
parent
fb90990d6d
commit
c00759a0ed
|
@ -693,9 +693,13 @@ void CGameTeams::OnCharacterDeath(int ClientID, int Weapon)
|
|||
char aBuf[512];
|
||||
str_format(aBuf, sizeof(aBuf), "Everyone in your locked team was killed because '%s' %s.", Server()->ClientName(ClientID), Weapon == WEAPON_SELF ? "killed" : "died");
|
||||
|
||||
m_Practice[Team] = false;
|
||||
|
||||
for(int i = 0; i < MAX_CLIENTS; i++)
|
||||
if(m_Core.Team(i) == Team && GameServer()->m_apPlayers[i])
|
||||
{
|
||||
GameServer()->m_apPlayers[i]->m_VotedForPractice = false;
|
||||
|
||||
if(i != ClientID)
|
||||
{
|
||||
GameServer()->m_apPlayers[i]->KillCharacter(WEAPON_SELF);
|
||||
|
|
Loading…
Reference in a new issue