From 15cf7f574d19e2e782112fad71a65106333443ce Mon Sep 17 00:00:00 2001 From: William Burns Date: Sat, 2 Apr 2016 11:08:40 +0100 Subject: [PATCH] Fix join/quit messages. --- .../game/clans/clans/ClansManager.java | 42 ++++++++----------- 1 file changed, 18 insertions(+), 24 deletions(-) diff --git a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/clans/ClansManager.java b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/clans/ClansManager.java index d3532185b..299bcd519 100644 --- a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/clans/ClansManager.java +++ b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/clans/ClansManager.java @@ -593,21 +593,18 @@ public class ClansManager extends MiniClientPluginimplements IRelati event.setJoinMessage(null); return; } - - if (event.getJoinMessage() != null) + + event.setJoinMessage(null); + + for (Player other : UtilServer.getPlayers()) { - event.setJoinMessage(null); - - for (Player other : UtilServer.getPlayers()) + if (_tutorialManager.isInTutorial(other)) { - if (_tutorialManager.isInTutorial(other)) - { - // Don't display join message if player in tutorial. - continue; - } - - other.sendMessage(F.sys("Join", event.getPlayer().getName())); + // Don't display join message if player in tutorial. + continue; } + + other.sendMessage(F.sys("Join", event.getPlayer().getName())); } } @@ -619,21 +616,18 @@ public class ClansManager extends MiniClientPluginimplements IRelati event.setQuitMessage(null); return; } - - if (event.getQuitMessage() != null) + + event.setQuitMessage(null); + + for (Player other : UtilServer.getPlayers()) { - event.setQuitMessage(null); - - for (Player other : UtilServer.getPlayers()) + if (_tutorialManager.isInTutorial(other)) { - if (_tutorialManager.isInTutorial(other)) - { - // Don't display quit message if player in tutorial. - continue; - } - - other.sendMessage(F.sys("Quit", event.getPlayer().getName())); + // Don't display quit message if player in tutorial. + continue; } + + other.sendMessage(F.sys("Quit", event.getPlayer().getName())); } }