From b360bb1528b6cc6515d4aada40da1e0b5bbbe18b Mon Sep 17 00:00:00 2001 From: LevelX2 Date: Mon, 16 Jun 2014 07:48:15 +0200 Subject: [PATCH] Removed redundant remove user from chat call and some formatting. --- Mage.Common/src/mage/view/RevealedView.java | 4 ++-- .../src/mage/player/human/HumanPlayer.java | 6 +----- Mage.Server/src/main/java/mage/server/UserManager.java | 1 - .../src/mage/sets/gatecrash/GideonChampionOfJustice.java | 2 +- 4 files changed, 4 insertions(+), 9 deletions(-) diff --git a/Mage.Common/src/mage/view/RevealedView.java b/Mage.Common/src/mage/view/RevealedView.java index 0b03d1bb16..2d573ef89f 100644 --- a/Mage.Common/src/mage/view/RevealedView.java +++ b/Mage.Common/src/mage/view/RevealedView.java @@ -39,8 +39,8 @@ import mage.game.Game; */ public class RevealedView implements Serializable { - private String name; - private SimpleCardsView cards = new SimpleCardsView(); + private final String name; + private final SimpleCardsView cards = new SimpleCardsView(); public RevealedView(String name, Cards cards, Game game) { this.name = name; diff --git a/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java b/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java index b9891f61db..7d53273e8c 100644 --- a/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java +++ b/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java @@ -45,12 +45,8 @@ import mage.abilities.PlayLandAbility; import mage.abilities.SpecialAction; import mage.abilities.SpellAbility; import mage.abilities.TriggeredAbility; -import mage.abilities.costs.Cost; import mage.abilities.costs.VariableCost; -import mage.abilities.costs.common.PayLifeCost; -import mage.abilities.costs.common.RemoveCounterCost; import mage.abilities.costs.common.SacrificeSourceCost; -import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCost; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.costs.mana.PhyrexianManaCost; @@ -343,7 +339,7 @@ public class HumanPlayer extends PlayerImpl { Map options = getOptions(target); if (target.getTargets().size() > 0) { if (options == null) { - options = new HashMap(1); + options = new HashMap<>(1); } List chosen = (List)target.getTargets(); options.put("chosen", (Serializable)chosen); diff --git a/Mage.Server/src/main/java/mage/server/UserManager.java b/Mage.Server/src/main/java/mage/server/UserManager.java index ae803cff1d..efcc7acdd0 100644 --- a/Mage.Server/src/main/java/mage/server/UserManager.java +++ b/Mage.Server/src/main/java/mage/server/UserManager.java @@ -129,7 +129,6 @@ public class UserManager { .append(" userId: ").append(userId) .append(" sessionId: ").append(user.getSessionId()) .append(" Reason: ").append(reason.toString())); - ChatManager.getInstance().removeUser(userId, reason); user.kill(reason); users.remove(userId); } else { diff --git a/Mage.Sets/src/mage/sets/gatecrash/GideonChampionOfJustice.java b/Mage.Sets/src/mage/sets/gatecrash/GideonChampionOfJustice.java index 16e5ca4593..222d44262f 100644 --- a/Mage.Sets/src/mage/sets/gatecrash/GideonChampionOfJustice.java +++ b/Mage.Sets/src/mage/sets/gatecrash/GideonChampionOfJustice.java @@ -67,7 +67,7 @@ public class GideonChampionOfJustice extends CardImpl { // +1: Put a loyalty counter on Gideon, Champion of Justice for each creature target opponent controls. LoyaltyAbility ability1 = new LoyaltyAbility( - new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(0), new PermanentsTargetOpponentControlsCount(), false), 1); + new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(0), new PermanentsTargetOpponentControlsCount(), true), 1); ability1.addTarget(new TargetOpponent()); this.addAbility(ability1);