From 4910d1727253fa5f32d7330c8fecd8ae5faef2ed Mon Sep 17 00:00:00 2001 From: Zzooouhh Date: Mon, 25 Dec 2017 20:49:19 +0100 Subject: [PATCH] Some changes to how counter is moved --- Mage.Sets/src/mage/cards/b/BaronVonCount.java | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/Mage.Sets/src/mage/cards/b/BaronVonCount.java b/Mage.Sets/src/mage/cards/b/BaronVonCount.java index 0fb7391dd0..7f9bc95d6d 100644 --- a/Mage.Sets/src/mage/cards/b/BaronVonCount.java +++ b/Mage.Sets/src/mage/cards/b/BaronVonCount.java @@ -200,13 +200,12 @@ class BaronVonCountMoveDoomCounterEffect extends OneShotEffect { } Integer doomNumber = (Integer) game.getState().getValue(mageObject.getId() + "_doom"); if (doomNumber <= 1) { - doomNumber = 5; game.fireEvent(GameEvent.getEvent(GameEvent.EventType.CUSTOM_EVENT, source.getSourceId(), source.getSourceId(), controller.getId(), "DoomCounterReset", 1)); } else { doomNumber--; + game.getState().setValue(mageObject.getId() + "_doom", doomNumber); + ((Permanent) mageObject).addInfo("doom counter", CardUtil.addToolTipMarkTags("Doom counter at: " + doomNumber), game); } - game.getState().setValue(mageObject.getId() + "_doom", doomNumber); - ((Permanent) mageObject).addInfo("doom counter", CardUtil.addToolTipMarkTags("Doom counter at: " + doomNumber), game); return true; } return false; @@ -267,6 +266,15 @@ class BaronVonCountDestroyPlayerEffect extends OneShotEffect { if (targetPlayer != null && targetPlayer.canLose(game)) { game.informPlayers(targetPlayer.getLogName() + " was destroyed"); targetPlayer.lost(game); // double checks canLose, but seems more future-proof than lostForced + } + MageObject mageObject = game.getObject(source.getSourceId()); + if (mageObject != null) { + if (game.getState().getValue(mageObject.getId() + "_doom") == null) { + return false; + } + Integer doomNumber = 5; + game.getState().setValue(mageObject.getId() + "_doom", doomNumber); + ((Permanent) mageObject).addInfo("doom counter", CardUtil.addToolTipMarkTags("Doom counter at: " + doomNumber), game); return true; } return false;