Add team color to vanish quit messages (PC-1161)

This commit is contained in:
ArcticZeroo 2017-10-23 10:29:36 -04:00 committed by Alexander Meech
parent 924e0b6fda
commit 12e3b2b84a

View File

@ -925,7 +925,13 @@ public class ArcadeManager extends MiniPlugin implements IRelation
{
if (event.getNewState()) //Is going into incognito
{
UtilServer.broadcast(F.sys("Quit", event.getPlayer().getName()));
GameTeam team = _game.GetTeam(event.getPlayer());
if (team != null) {
UtilServer.broadcast(F.sys("Quit", team.GetColor() + event.getPlayer().getName()));
} else {
UtilServer.broadcast(F.sys("Quit", event.getPlayer().getName()));
}
if (_game != null && _game.GetCountdown() > 0) //Lobby is counting down
{
@ -935,8 +941,6 @@ public class ArcadeManager extends MiniPlugin implements IRelation
_game.GetPlayerGems().remove(event.getPlayer());
// Leave Team
GameTeam team = _game.GetTeam(event.getPlayer());
if (team != null)
{
team.RemovePlayer(event.getPlayer());