* Fixed AddManaOfAnyColorEffect to send TAPPED_FOR_MANA event correctly (fixed that City of Brass did not work with Heartbeat of Spring).

This commit is contained in:
LevelX2 2015-01-23 00:25:39 +01:00
parent ac0d923afd
commit 105e12db10
2 changed files with 3 additions and 2 deletions

View file

@ -359,7 +359,7 @@ public abstract class AbilityImpl implements Ability {
} else if (effect instanceof DynamicManaEffect) {
mana = ((DynamicManaEffect)effect).getMana(game, this);
}
if (mana != null) { // if mana == null the event has to be fires in the mana effect
if (mana != null) { // if mana == null the event has to be fired in the mana effect
game.fireEvent(new ManaEvent(GameEvent.EventType.TAPPED_FOR_MANA, sourceId, sourceId, controllerId, mana));
}
break;

View file

@ -73,7 +73,7 @@ public class AddManaOfAnyColorEffect extends BasicManaEffect {
if (controller.choose(outcome, choice, game)) {
if (choice.getColor() == null) {
return false; // it happenes, don't know how
return false; // it happens, don't know how
}
Mana createdMana = null;
if (choice.getColor().isBlack()) {
@ -89,6 +89,7 @@ public class AddManaOfAnyColorEffect extends BasicManaEffect {
}
if (createdMana != null) {
controller.getManaPool().addMana(createdMana, game, source);
checkToFirePossibleEvents(createdMana, game, source);
}
return true;
}