mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 11:48:02 +00:00
Merge branch '2079-kamigawa-compleated' into 'master'
Resolve "Kamigawa: Compleated" Closes #2079 See merge request core-developers/forge!6319
This commit is contained in:
@@ -795,6 +795,9 @@ public class ComputerUtilMana {
|
|||||||
|
|
||||||
if (toPay.isPhyrexian()) {
|
if (toPay.isPhyrexian()) {
|
||||||
cost.payPhyrexian();
|
cost.payPhyrexian();
|
||||||
|
if (!test) {
|
||||||
|
sa.setSpendPhyrexianMana(true);
|
||||||
|
}
|
||||||
} else if (lifeInsteadOfBlack) {
|
} else if (lifeInsteadOfBlack) {
|
||||||
cost.decreaseShard(ManaCostShard.BLACK, 1);
|
cost.decreaseShard(ManaCostShard.BLACK, 1);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -182,6 +182,8 @@ public class ForgeScript {
|
|||||||
return sa.hasParam("Daybound");
|
return sa.hasParam("Daybound");
|
||||||
} else if (property.equals("Nightbound")) {
|
} else if (property.equals("Nightbound")) {
|
||||||
return sa.hasParam("Nightbound");
|
return sa.hasParam("Nightbound");
|
||||||
|
} else if (property.equals("paidPhyrexianMana")) {
|
||||||
|
return sa.getSpendPhyrexianMana();
|
||||||
} else if (property.equals("MayPlaySource")) {
|
} else if (property.equals("MayPlaySource")) {
|
||||||
StaticAbility m = sa.getMayPlay();
|
StaticAbility m = sa.getMayPlay();
|
||||||
if (m == null) {
|
if (m == null) {
|
||||||
|
|||||||
@@ -2147,6 +2147,11 @@ public class CardFactoryUtil {
|
|||||||
|
|
||||||
re.setOverridingAbility(saReturn);
|
re.setOverridingAbility(saReturn);
|
||||||
|
|
||||||
|
inst.addReplacement(re);
|
||||||
|
} else if (keyword.equals("Compleated")) {
|
||||||
|
String sb = "etbCounter:LOYALTY:-2:ValidCard$ Card.CastSa Spell.paidPhyrexianMana:If life was paid, this planeswalker enters with two fewer loyalty counters";
|
||||||
|
final ReplacementEffect re = makeEtbCounter(sb, card, intrinsic);
|
||||||
|
|
||||||
inst.addReplacement(re);
|
inst.addReplacement(re);
|
||||||
} else if (keyword.startsWith("Dredge")) {
|
} else if (keyword.startsWith("Dredge")) {
|
||||||
final String dredgeAmount = keyword.split(":")[1];
|
final String dredgeAmount = keyword.split(":")[1];
|
||||||
|
|||||||
@@ -115,6 +115,7 @@ public abstract class SpellAbility extends CardTraitBase implements ISpellAbilit
|
|||||||
private Player targetingPlayer = null;
|
private Player targetingPlayer = null;
|
||||||
private Pair<Long, Player> controlledByPlayer = null;
|
private Pair<Long, Player> controlledByPlayer = null;
|
||||||
private ManaCostBeingPaid manaCostBeingPaid = null;
|
private ManaCostBeingPaid manaCostBeingPaid = null;
|
||||||
|
private boolean spentPhyrexian = false;
|
||||||
|
|
||||||
private SpellAbility grantorOriginal = null;
|
private SpellAbility grantorOriginal = null;
|
||||||
private StaticAbility grantorStatic = null;
|
private StaticAbility grantorStatic = null;
|
||||||
@@ -613,6 +614,13 @@ public abstract class SpellAbility extends CardTraitBase implements ISpellAbilit
|
|||||||
payingMana.clear();
|
payingMana.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public final boolean getSpendPhyrexianMana() {
|
||||||
|
return this.spentPhyrexian;
|
||||||
|
}
|
||||||
|
public final void setSpendPhyrexianMana(boolean value) {
|
||||||
|
this.spentPhyrexian = value;
|
||||||
|
}
|
||||||
|
|
||||||
public final void applyPayingManaEffects() {
|
public final void applyPayingManaEffects() {
|
||||||
Card host = getHostCard();
|
Card host = getHostCard();
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,13 @@
|
|||||||
|
Name:Tamiyo, Compleated Sage
|
||||||
|
ManaCost:2 G PGU U
|
||||||
|
Types:Legendary Planeswalker Tamiyo
|
||||||
|
Loyalty:5
|
||||||
|
K:Compleated
|
||||||
|
A:AB$ Tap | Cost$ AddCounter<1/LOYALTY> | Planeswalker$ True | ValidTgts$ Artifact,Creature | TgtPrompt$ Select up to one target artifact or creature | TargetMin$ 0 | TargetMax$ 1 | SubAbility$ DBPump | SpellDescription$ Tap up to one target artifact or creature. It doesn't untap during its controller's next untap step.
|
||||||
|
SVar:DBPump:DB$ Pump | Defined$ Targeted | KW$ HIDDEN This card doesn't untap during your next untap step. | Duration$ Permanent
|
||||||
|
A:AB$ ChangeZone | Cost$ SubCounter<X/LOYALTY> | Planeswalker$ True | ValidTgts$ Permanent.nonLand+cmcEQX | TgtPrompt$ Select target nonland permanent card with mana value X | AILogic$ BestCard | Origin$ Graveyard | Destination$ Exile | SubAbility$ DBCopy | SpellDescription$ Exile target nonland permanent card with mana value X from your graveyard.
|
||||||
|
SVar:DBCopy:DB$ CopyPermanent | Defined$ Targeted | SpellDescription$ Create a token that's a copy of that card.
|
||||||
|
SVar:X:Count$xPaid
|
||||||
|
A:AB$ Token | Cost$ SubCounter<7/LOYALTY> | Planeswalker$ True | Ultimate$ True | TokenScript$ tamiyos_notebook | SpellDescription$ Create Tamiyo's Notebook, a legendary colorless artifact token with "Spells you cast cost {2} less to cast" and "{T}: Draw a card."
|
||||||
|
DeckHas:Ability$Token & Type$Artifact
|
||||||
|
Oracle:Compleated ({PGU} can be paid with {G}, {U}, or 2 life. If life was paid, this planeswalker enters with two fewer loyalty counters.)\n[+1]: Tap up to one target artifact or creature. It doesn't untap during its controller's next untap step.\n[−X]: Exile target nonland permanent card with mana value X from your graveyard. Create a token that's a copy of that card.\n[−7]: Create Tamiyo's Notebook, a legendary colorless artifact token with "Spells you cast cost {2} less to cast" and "{T}: Draw a card."
|
||||||
@@ -46,6 +46,7 @@ public class InputPayManaOfCostPayment extends InputPayMana {
|
|||||||
if (player == selected) {
|
if (player == selected) {
|
||||||
if (player.canPayLife(this.phyLifeToLose + 2, this.effect, saPaidFor)) {
|
if (player.canPayLife(this.phyLifeToLose + 2, this.effect, saPaidFor)) {
|
||||||
if (manaCost.payPhyrexian()) {
|
if (manaCost.payPhyrexian()) {
|
||||||
|
saPaidFor.setSpendPhyrexianMana(true);
|
||||||
this.phyLifeToLose += 2;
|
this.phyLifeToLose += 2;
|
||||||
} else {
|
} else {
|
||||||
if (player.hasKeyword("PayLifeInsteadOf:B") && manaCost.hasAnyKind(ManaAtom.BLACK)) {
|
if (player.hasKeyword("PayLifeInsteadOf:B") && manaCost.hasAnyKind(ManaAtom.BLACK)) {
|
||||||
|
|||||||
@@ -217,9 +217,9 @@ public class HumanPlaySpellAbility {
|
|||||||
fromZone.add(oldCard, zonePosition >= 0 ? Integer.valueOf(zonePosition) : null);
|
fromZone.add(oldCard, zonePosition >= 0 ? Integer.valueOf(zonePosition) : null);
|
||||||
ability.setHostCard(oldCard);
|
ability.setHostCard(oldCard);
|
||||||
ability.setXManaCostPaid(null);
|
ability.setXManaCostPaid(null);
|
||||||
|
ability.setSpendPhyrexianMana(false);
|
||||||
if (ability.hasParam("Announce")) {
|
if (ability.hasParam("Announce")) {
|
||||||
final String announce = ability.getParam("Announce");
|
for (final String aVar : ability.getParam("Announce").split(",")) {
|
||||||
for (final String aVar : announce.split(",")) {
|
|
||||||
final String varName = aVar.trim();
|
final String varName = aVar.trim();
|
||||||
if (!varName.equals("X")) {
|
if (!varName.equals("X")) {
|
||||||
ability.setSVar(varName, "0");
|
ability.setSVar(varName, "0");
|
||||||
|
|||||||
Reference in New Issue
Block a user