From b10ad8e66365d5a40e0cd5259aa9c10903a43bad Mon Sep 17 00:00:00 2001 From: LevelX2 Date: Fri, 14 Feb 2014 15:13:59 +0100 Subject: [PATCH] * Game log - The announced value for X costs is now posted to the log at a later point in time to avoid posting canceled announcements. --- Mage/src/mage/abilities/AbilityImpl.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Mage/src/mage/abilities/AbilityImpl.java b/Mage/src/mage/abilities/AbilityImpl.java index 07c3da4f17..2b0a4b25fd 100644 --- a/Mage/src/mage/abilities/AbilityImpl.java +++ b/Mage/src/mage/abilities/AbilityImpl.java @@ -300,6 +300,11 @@ public abstract class AbilityImpl> implements Ability { logger.debug("activate failed - non mana costs"); return false; } + // inform about x costs now, so canceled announcements are not shown in the log + if (variableManaCost != null) { + int xValue = getManaCostsToPay().getX(); + game.informPlayers(new StringBuilder(game.getPlayer(this.controllerId).getName()).append(" announced a value of ").append(xValue).append(" for ").append(variableManaCost.getText()).toString()); + } return true; } @@ -356,8 +361,6 @@ public abstract class AbilityImpl> implements Ability { } variableManaCost.setPaid(); } - xValue = getManaCostsToPay().getX(); - game.informPlayers(new StringBuilder(game.getPlayer(this.controllerId).getName()).append(" announced a value of ").append(xValue).append(" for ").append(variableManaCost.getText()).toString()); } return variableManaCost;