- Better check for Sunburst.

This commit is contained in:
Agetian
2017-10-08 10:55:19 +00:00
parent 036d672e7c
commit 43862a4b7b
2 changed files with 8 additions and 5 deletions

View File

@@ -1401,14 +1401,17 @@ public class CardFactoryUtil {
return doXMath(n, m, c); return doXMath(n, m, c);
} }
if (sq[0].startsWith("UniqueManaColorsProduced")) { if (sq[0].startsWith("UniqueManaColorsProduced")) {
boolean untappedOnly = sq[0].contains("ByUntappedSources");
int uniqueColors = 0; int uniqueColors = 0;
CardCollectionView otb = cc.getCardsIn(ZoneType.Battlefield); CardCollectionView otb = cc.getCardsIn(ZoneType.Battlefield);
outer: for (byte color : MagicColor.WUBRG) { outer: for (byte color : MagicColor.WUBRG) {
for (Card card : otb) { for (Card card : otb) {
for (SpellAbility ma : card.getManaAbilities()) { if (!card.isTapped() || !untappedOnly) {
if (ma.getManaPart().canProduce(MagicColor.toShortString(color))) { for (SpellAbility ma : card.getManaAbilities()) {
uniqueColors++; if (ma.getManaPart().canProduce(MagicColor.toShortString(color))) {
continue outer; uniqueColors++;
continue outer;
}
} }
} }
} }

View File

@@ -6,6 +6,6 @@ T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | O
SVar:TrigGainLife:AB$GainLife | Cost$ 0 | Defined$ You | LifeAmount$ X | References$ X SVar:TrigGainLife:AB$GainLife | Cost$ 0 | Defined$ You | LifeAmount$ X | References$ X
SVar:X:Count$CardCounters.CHARGE SVar:X:Count$CardCounters.CHARGE
SVar:NeedsToPlayVar:Z GE2 SVar:NeedsToPlayVar:Z GE2
SVar:Z:Count$UniqueManaColorsProduced SVar:Z:Count$UniqueManaColorsProduced.ByUntappedSources
SVar:Picture:http://www.wizards.com/global/images/magic/general/clearwater_goblet.jpg SVar:Picture:http://www.wizards.com/global/images/magic/general/clearwater_goblet.jpg
Oracle:Sunburst (This enters the battlefield with a charge counter on it for each color of mana spent to cast it.)\nAt the beginning of your upkeep, you may gain life equal to the number of charge counters on Clearwater Goblet. Oracle:Sunburst (This enters the battlefield with a charge counter on it for each color of mana spent to cast it.)\nAt the beginning of your upkeep, you may gain life equal to the number of charge counters on Clearwater Goblet.