diff --git a/Mage.Sets/src/mage/cards/g/GideonOfTheTrials.java b/Mage.Sets/src/mage/cards/g/GideonOfTheTrials.java index 96f475d41f6..fc4e0ff04a3 100644 --- a/Mage.Sets/src/mage/cards/g/GideonOfTheTrials.java +++ b/Mage.Sets/src/mage/cards/g/GideonOfTheTrials.java @@ -27,13 +27,9 @@ */ package mage.cards.g; -import java.util.UUID; import mage.MageInt; - -import mage.abilities.Ability; import mage.abilities.LoyaltyAbility; import mage.abilities.common.PlanswalkerEntersWithLoyalityCountersAbility; -import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; import mage.abilities.effects.Effect; import mage.abilities.effects.common.GetEmblemEffect; import mage.abilities.effects.common.PreventAllDamageToSourceEffect; @@ -42,15 +38,14 @@ import mage.abilities.effects.common.continuous.BecomesCreatureSourceEffect; import mage.abilities.keyword.IndestructibleAbility; import mage.cards.CardImpl; import mage.cards.CardSetInfo; -import mage.constants.*; -import mage.filter.common.FilterPlaneswalkerPermanent; -import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.game.events.GameEvent; +import mage.constants.CardType; +import mage.constants.Duration; import mage.game.command.emblems.GideonOfTheTrialsEmblem; import mage.game.permanent.token.Token; import mage.target.TargetPermanent; +import java.util.UUID; + /** * * @author JRHerlehy @@ -94,45 +89,6 @@ public class GideonOfTheTrials extends CardImpl { } } -class GideonOfTheTrialsCantLoseEffect extends ContinuousRuleModifyingEffectImpl { - - private static final FilterPlaneswalkerPermanent filter = new FilterPlaneswalkerPermanent("a Gideon planeswalker"); - - static { - filter.add(new SubtypePredicate(SubType.GIDEON)); - } - - public GideonOfTheTrialsCantLoseEffect() { - super(Duration.EndOfGame, Outcome.Benefit); - staticText = "As long as you control a Gideon planeswalker, you can't lose the game and your opponents can't win the game"; - } - - public GideonOfTheTrialsCantLoseEffect(final GideonOfTheTrialsCantLoseEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - return true; - } - - @Override - public boolean applies(GameEvent event, Ability source, Game game) { - if ((event.getType() == GameEvent.EventType.WINS && game.getOpponents(source.getControllerId()).contains(event.getPlayerId())) - || (event.getType() == GameEvent.EventType.LOSES && event.getPlayerId().equals(source.getControllerId()))) { - if (game.getBattlefield().contains(filter, source.getControllerId(), 1, game)) { - return true; - } - } - return false; - } - - @Override - public GideonOfTheTrialsCantLoseEffect copy() { - return new GideonOfTheTrialsCantLoseEffect(this); - } -} - class GideonOfTheTrialsToken extends Token { public GideonOfTheTrialsToken() { diff --git a/Mage/src/main/java/mage/game/command/emblems/GideonOfTheTrialsEmblem.java b/Mage/src/main/java/mage/game/command/emblems/GideonOfTheTrialsEmblem.java index 7c9fa13d682..4451fc77110 100644 --- a/Mage/src/main/java/mage/game/command/emblems/GideonOfTheTrialsEmblem.java +++ b/Mage/src/main/java/mage/game/command/emblems/GideonOfTheTrialsEmblem.java @@ -62,7 +62,7 @@ class GideonOfTheTrialsCantLoseEffect extends ContinuousRuleModifyingEffectImpl } public GideonOfTheTrialsCantLoseEffect() { - super(Duration.EndOfGame, Outcome.Benefit); + super(Duration.EndOfGame, Outcome.Benefit, false, false); staticText = "As long as you control a Gideon planeswalker, you can't lose the game and your opponents can't win the game"; }