mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 10:08:18 +00:00
Merge pull request #7314 from furo321/keep-practice
Don't disable practice on death.
This commit is contained in:
commit
7034ca84ec
|
@ -1047,8 +1047,22 @@ void CGameTeams::OnCharacterDeath(int ClientID, int Weapon)
|
||||||
if(g_Config.m_SvTeam == SV_TEAM_FORCED_SOLO && Team != TEAM_SUPER)
|
if(g_Config.m_SvTeam == SV_TEAM_FORCED_SOLO && Team != TEAM_SUPER)
|
||||||
{
|
{
|
||||||
ChangeTeamState(Team, CGameTeams::TEAMSTATE_OPEN);
|
ChangeTeamState(Team, CGameTeams::TEAMSTATE_OPEN);
|
||||||
|
if(m_aPractice[Team])
|
||||||
|
{
|
||||||
|
if(Weapon == WEAPON_SELF)
|
||||||
|
{
|
||||||
ResetRoundState(Team);
|
ResetRoundState(Team);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
GameServer()->SendChatTeam(Team, "You died, but will stay in practice until you use kill.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ResetRoundState(Team);
|
||||||
|
}
|
||||||
|
}
|
||||||
else if(Locked)
|
else if(Locked)
|
||||||
{
|
{
|
||||||
SetForceCharacterTeam(ClientID, Team);
|
SetForceCharacterTeam(ClientID, Team);
|
||||||
|
|
Loading…
Reference in a new issue