diff --git a/Mage.Sets/src/mage/sets/vintagemasters/MishrasWorkshop.java b/Mage.Sets/src/mage/sets/vintagemasters/MishrasWorkshop.java index 02385476ac..afac89175d 100644 --- a/Mage.Sets/src/mage/sets/vintagemasters/MishrasWorkshop.java +++ b/Mage.Sets/src/mage/sets/vintagemasters/MishrasWorkshop.java @@ -30,7 +30,6 @@ package mage.sets.vintagemasters; import java.util.UUID; import mage.ConditionalMana; import mage.abilities.costs.common.TapSourceCost; -import mage.abilities.mana.ConditionalAnyColorManaAbility; import mage.abilities.mana.ConditionalColorlessManaAbility; import mage.abilities.mana.builder.ConditionalManaBuilder; import mage.abilities.mana.conditional.ArtifactCastConditionalMana; diff --git a/Mage/src/mage/players/ManaPool.java b/Mage/src/mage/players/ManaPool.java index 5be74e97b4..fad786a42e 100644 --- a/Mage/src/mage/players/ManaPool.java +++ b/Mage/src/mage/players/ManaPool.java @@ -181,16 +181,33 @@ public class ManaPool implements Serializable { Iterator it = manaItems.iterator(); while (it.hasNext()) { ManaPoolItem item = it.next(); + ConditionalMana conditionalItem = item.getConditionalMana(); for (ManaType manaType : ManaType.values()) { - if (item.get(manaType) > 0 && !doNotEmptyManaTypes.contains(manaType)) { - if (!item.getDuration().equals(Duration.EndOfTurn) || game.getPhase().getType().equals(TurnPhase.END)) { - if (game.replaceEvent(new GameEvent(GameEvent.EventType.EMPTY_MANA_POOL, playerId, null, playerId))) { - int amount = item.get(manaType); - item.clear(manaType); - item.add(ManaType.COLORLESS, amount); - } else { - total += item.get(manaType); - item.clear(manaType); + if (!doNotEmptyManaTypes.contains(manaType)) { + if (item.get(manaType) > 0) { + if (!item.getDuration().equals(Duration.EndOfTurn) || game.getPhase().getType().equals(TurnPhase.END)) { + if (game.replaceEvent(new GameEvent(GameEvent.EventType.EMPTY_MANA_POOL, playerId, null, playerId))) { + int amount = item.get(manaType); + item.clear(manaType); + item.add(ManaType.COLORLESS, amount); + } else { + total += item.get(manaType); + item.clear(manaType); + } + } + } + if (conditionalItem != null) { + if (conditionalItem.get(manaType) > 0) { + if (!item.getDuration().equals(Duration.EndOfTurn) || game.getPhase().getType().equals(TurnPhase.END)) { + if (game.replaceEvent(new GameEvent(GameEvent.EventType.EMPTY_MANA_POOL, playerId, null, playerId))) { + int amount = conditionalItem.get(manaType); + conditionalItem.clear(manaType); + conditionalItem.add(ManaType.COLORLESS, amount); + } else { + total += conditionalItem.get(manaType); + conditionalItem.clear(manaType); + } + } } } }