diff --git a/Mage/src/main/java/mage/actions/MageLoseGameAction.java b/Mage/src/main/java/mage/actions/MageLoseGameAction.java deleted file mode 100644 index 30d5d5bd2944..000000000000 --- a/Mage/src/main/java/mage/actions/MageLoseGameAction.java +++ /dev/null @@ -1,47 +0,0 @@ -package mage.actions; - -import mage.abilities.Ability; -import mage.actions.impl.MageAction; -import mage.actions.score.ArtificialScoringSystem; -import mage.game.Game; -import mage.players.Player; - -import java.util.UUID; - -/** - * Lose game action. - * - * @author ayratn - */ -public class MageLoseGameAction extends MageAction { - - public static final String LIFE_REASON = "{L} You lose the game."; - public static final String POISON_REASON = "{L} You are poisoned. You lose the game."; - public static final String DRAW_REASON = "{L} You attempt to draw from an empty library. You lose the game."; - - private final Player player; - private final String reason; - private Player oldLosingPlayer; - - public MageLoseGameAction(final Player player, final String reason) { - this.player = player; - this.reason = reason; - } - - @Override - public int doAction(Ability source, final Game game) { - oldLosingPlayer = game.getLosingPlayer(); - if (oldLosingPlayer == null && player.canLose(game)) { - setScore(player, ArtificialScoringSystem.inst.getLoseGameScore(game)); - game.setLosingPlayer(player); - if (!game.isSimulation()) - game.informPlayer(player, reason); - } - return 0; - } - - @Override - public void undoAction(final Game game) { - game.setLosingPlayer(oldLosingPlayer); - } -} \ No newline at end of file