Replace first withContext call with more stable AI prediction (#7261)

This commit is contained in:
tool4ever
2025-03-25 19:08:36 +01:00
committed by GitHub
parent fcd8b8fd35
commit ac67a36ccf
29 changed files with 43 additions and 35 deletions

View File

@@ -111,6 +111,7 @@ public enum AbilityKey {
OriginalDefender("OriginalDefender"), OriginalDefender("OriginalDefender"),
OriginalParams("OriginalParams"), OriginalParams("OriginalParams"),
PayingMana("PayingMana"), PayingMana("PayingMana"),
Phase("Phase"),
Player("Player"), Player("Player"),
PreventedAmount("PreventedAmount"), PreventedAmount("PreventedAmount"),
Produced("Produced"), Produced("Produced"),

View File

@@ -58,7 +58,7 @@ public class SkipPhaseEffect extends SpellAbilityEffect {
final Card eff = createEffect(sa, player, name, image); final Card eff = createEffect(sa, player, name, image);
final StringBuilder sb = new StringBuilder(); final StringBuilder sb = new StringBuilder();
sb.append("Event$ BeginPhase | ActiveZones$ Command | PlayerTurn$ You | ActivePhases$ "); sb.append("Event$ BeginPhase | ActiveZones$ Command | ValidPlayer$ You | Phase$ ");
sb.append(phase != null ? phase : step); sb.append(phase != null ? phase : step);
if (duration != null && !isNextThisTurn) { if (duration != null && !isNextThisTurn) {
sb.append(" | Skip$ True"); sb.append(" | Skip$ True");

View File

@@ -203,6 +203,7 @@ public class PhaseHandler implements java.io.Serializable {
} }
final Map<AbilityKey, Object> repRunParams = AbilityKey.mapFromAffected(playerTurn); final Map<AbilityKey, Object> repRunParams = AbilityKey.mapFromAffected(playerTurn);
repRunParams.put(AbilityKey.Phase, phase);
ReplacementResult repres = game.getReplacementHandler().run(ReplacementType.BeginPhase, repRunParams); ReplacementResult repres = game.getReplacementHandler().run(ReplacementType.BeginPhase, repRunParams);
if (repres != ReplacementResult.NotReplaced) { if (repres != ReplacementResult.NotReplaced) {
// Currently there is no effect to skip entire beginning phase // Currently there is no effect to skip entire beginning phase

View File

@@ -4,6 +4,7 @@ import java.util.Map;
import forge.game.ability.AbilityKey; import forge.game.ability.AbilityKey;
import forge.game.card.Card; import forge.game.card.Card;
import forge.game.phase.PhaseType;
import forge.game.spellability.SpellAbility; import forge.game.spellability.SpellAbility;
public class ReplaceBeginPhase extends ReplacementEffect { public class ReplaceBeginPhase extends ReplacementEffect {
@@ -18,6 +19,14 @@ public class ReplaceBeginPhase extends ReplacementEffect {
@Override @Override
public boolean canReplace(Map<AbilityKey, Object> runParams) { public boolean canReplace(Map<AbilityKey, Object> runParams) {
if (!matchesValidParam("ValidPlayer", runParams.get(AbilityKey.Affected))) {
return false;
}
if (hasParam("Phase") && !PhaseType.parseRange(getParam("Phase")).contains(runParams.get(AbilityKey.Phase))) {
return false;
}
return true; return true;
} }

View File

@@ -18,7 +18,6 @@
package forge.game.replacement; package forge.game.replacement;
import java.util.*; import java.util.*;
import java.util.concurrent.Callable;
import com.google.common.base.MoreObjects; import com.google.common.base.MoreObjects;
import forge.game.card.*; import forge.game.card.*;
@@ -856,15 +855,13 @@ public class ReplacementHandler {
* Helper function to check if a phase would be skipped for AI. * Helper function to check if a phase would be skipped for AI.
*/ */
public boolean wouldPhaseBeSkipped(final Player player, final PhaseType phase) { public boolean wouldPhaseBeSkipped(final Player player, final PhaseType phase) {
Callable<Boolean> proc = () -> { final Map<AbilityKey, Object> repParams = AbilityKey.mapFromAffected(player);
final Map<AbilityKey, Object> repParams = AbilityKey.newMap(); repParams.put(AbilityKey.Phase, phase);
List<ReplacementEffect> list = getReplacementList(ReplacementType.BeginPhase, repParams, ReplacementLayer.Control); List<ReplacementEffect> list = getReplacementList(ReplacementType.BeginPhase, repParams, ReplacementLayer.Control);
if (list.isEmpty()) { if (list.isEmpty()) {
return false; return false;
} }
return true; return true;
};
return player.getGame().getPhaseHandler().withContext(proc, player, phase);
} }
/** /**

View File

@@ -4,7 +4,7 @@ Types:Enchantment
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigExile | TriggerDescription$ When CARDNAME enters, exile the top seven cards of your library face down. You may look at the cards exiled with CARDNAME, and you may play lands and cast spells from among those cards. T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigExile | TriggerDescription$ When CARDNAME enters, exile the top seven cards of your library face down. You may look at the cards exiled with CARDNAME, and you may play lands and cast spells from among those cards.
SVar:TrigExile:DB$ Dig | Defined$ You | DigNum$ 7 | ChangeNum$ All | DestinationZone$ Exile | ExileFaceDown$ True | NoReveal$ True SVar:TrigExile:DB$ Dig | Defined$ You | DigNum$ 7 | ChangeNum$ All | DestinationZone$ Exile | ExileFaceDown$ True | NoReveal$ True
S:Mode$ Continuous | Affected$ Card.ExiledWithSource | AffectedZone$ Exile | MayPlay$ True | MayLookAt$ You | Description$ You may look at the cards exiled with CARDNAME, and you may play lands and cast spells from among those cards. S:Mode$ Continuous | Affected$ Card.ExiledWithSource | AffectedZone$ Exile | MayPlay$ True | MayLookAt$ You | Description$ You may look at the cards exiled with CARDNAME, and you may play lands and cast spells from among those cards.
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
S:Mode$ CantBeCast | ValidCard$ Card | Caster$ You | NumLimitEachTurn$ 1 | Description$ You can't cast more than one spell each turn. S:Mode$ CantBeCast | ValidCard$ Card | Caster$ You | NumLimitEachTurn$ 1 | Description$ You can't cast more than one spell each turn.
AI:RemoveDeck:All AI:RemoveDeck:All
Oracle:When Colfenor's Plans enters, exile the top seven cards of your library face down.\nYou may look at the cards exiled with Colfenor's Plans, and you may play lands and cast spells from among those cards.\nSkip your draw step.\nYou can't cast more than one spell each turn. Oracle:When Colfenor's Plans enters, exile the top seven cards of your library face down.\nYou may look at the cards exiled with Colfenor's Plans, and you may play lands and cast spells from among those cards.\nSkip your draw step.\nYou can't cast more than one spell each turn.

View File

@@ -3,7 +3,7 @@ ManaCost:4 B G U
Types:Legendary Creature Gorgon Wizard Types:Legendary Creature Gorgon Wizard
PT:4/4 PT:4/4
K:Deathtouch K:Deathtouch
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | CheckSVar$ X | SVarCompare$ LT7 | Execute$ TrigDraw | TriggerDescription$ At the beginning of your upkeep, if you have fewer than seven cards in hand, draw cards equal to the difference. T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | CheckSVar$ X | SVarCompare$ LT7 | Execute$ TrigDraw | TriggerDescription$ At the beginning of your upkeep, if you have fewer than seven cards in hand, draw cards equal to the difference.
SVar:TrigDraw:DB$ Draw | Defined$ You | NumCards$ Difference SVar:TrigDraw:DB$ Draw | Defined$ You | NumCards$ Difference
SVar:X:Count$InYourHand SVar:X:Count$InYourHand

View File

@@ -6,7 +6,7 @@ K:Flying
K:Kicker:W W K:Kicker:W W
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigDestroyYourLand | TriggerDescription$ When CARDNAME enters, destroy all lands you control. If it was kicked, destroy all lands instead. T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigDestroyYourLand | TriggerDescription$ When CARDNAME enters, destroy all lands you control. If it was kicked, destroy all lands instead.
SVar:TrigDestroyYourLand:DB$ DestroyAll | ValidCards$ Land.YouCtrl | ConditionDefined$ Self | ConditionPresent$ Card.!kicked | SubAbility$ TrigKicker SVar:TrigDestroyYourLand:DB$ DestroyAll | ValidCards$ Land.YouCtrl | ConditionDefined$ Self | ConditionPresent$ Card.!kicked | SubAbility$ TrigKicker
SVar:TrigKicker:DB$ DestroyAll | ValidCards$ Land | Condition$ Kicked SVar:TrigKicker:DB$ DestroyAll | ValidCards$ Land | ConditionDefined$ Self | ConditionPresent$ Card.kicked
AI:RemoveDeck:Random AI:RemoveDeck:Random
DeckNeeds:Color$White DeckNeeds:Color$White
Oracle:Kicker {W}{W} (You may pay an additional {W}{W} as you cast this spell.)\nFlying\nWhen Desolation Angel enters, destroy all lands you control. If it was kicked, destroy all lands instead. Oracle:Kicker {W}{W} (You may pay an additional {W}{W} as you cast this spell.)\nFlying\nWhen Desolation Angel enters, destroy all lands you control. If it was kicked, destroy all lands instead.

View File

@@ -5,7 +5,7 @@ PT:3/3
K:Kicker:W W K:Kicker:W W
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigDestroy | TriggerDescription$ When CARDNAME enters, destroy all other creatures you control. If it was kicked, destroy all other creatures instead. T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigDestroy | TriggerDescription$ When CARDNAME enters, destroy all other creatures you control. If it was kicked, destroy all other creatures instead.
SVar:TrigDestroy:DB$ DestroyAll | ValidCards$ Creature.StrictlyOther+YouCtrl | ConditionDefined$ Self | ConditionPresent$ Card.!kicked | SubAbility$ TrigKicker SVar:TrigDestroy:DB$ DestroyAll | ValidCards$ Creature.StrictlyOther+YouCtrl | ConditionDefined$ Self | ConditionPresent$ Card.!kicked | SubAbility$ TrigKicker
SVar:TrigKicker:DB$ DestroyAll | ValidCards$ Creature.StrictlyOther | Condition$ Kicked SVar:TrigKicker:DB$ DestroyAll | ValidCards$ Creature.StrictlyOther | ConditionDefined$ Self | ConditionPresent$ Card.kicked
AI:RemoveDeck:All AI:RemoveDeck:All
AI:RemoveDeck:Random AI:RemoveDeck:Random
DeckNeeds:Color$White DeckNeeds:Color$White

View File

@@ -1,7 +1,7 @@
Name:Dragon Appeasement Name:Dragon Appeasement
ManaCost:3 B R G ManaCost:3 B R G
Types:Enchantment Types:Enchantment
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
T:Mode$ Sacrificed | ValidCard$ Creature.YouCtrl | Execute$ TrigDrawCard | OptionalDecider$ You | TriggerZones$ Battlefield | TriggerDescription$ Whenever you sacrifice a creature, you may draw a card. T:Mode$ Sacrificed | ValidCard$ Creature.YouCtrl | Execute$ TrigDrawCard | OptionalDecider$ You | TriggerZones$ Battlefield | TriggerDescription$ Whenever you sacrifice a creature, you may draw a card.
SVar:TrigDrawCard:DB$ Draw | Defined$ You | NumCards$ 1 SVar:TrigDrawCard:DB$ Draw | Defined$ You | NumCards$ 1
AI:RemoveDeck:Random AI:RemoveDeck:Random

View File

@@ -1,7 +1,7 @@
Name:Eon Hub Name:Eon Hub
ManaCost:5 ManaCost:5
Types:Artifact Types:Artifact
R:Event$ BeginPhase | ActiveZones$ Battlefield | ActivePhases$ Upkeep | Skip$ True | Description$ Players skip their upkeep steps. R:Event$ BeginPhase | ActiveZones$ Battlefield | Phase$ Upkeep | Skip$ True | Description$ Players skip their upkeep steps.
SVar:NonStackingEffect:True SVar:NonStackingEffect:True
AI:RemoveDeck:Random AI:RemoveDeck:Random
Oracle:Players skip their upkeep steps. Oracle:Players skip their upkeep steps.

View File

@@ -4,7 +4,7 @@ Types:Enchantment
T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigPutHunger | TriggerDescription$ At the beginning of your upkeep, put a hunger counter on CARDNAME. Then destroy CARDNAME if it has five or more hunger counters on it. T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigPutHunger | TriggerDescription$ At the beginning of your upkeep, put a hunger counter on CARDNAME. Then destroy CARDNAME if it has five or more hunger counters on it.
SVar:TrigPutHunger:DB$ PutCounter | Defined$ Self | CounterType$ HUNGER | CounterNum$ 1 | SubAbility$ DBDestroyHunger SVar:TrigPutHunger:DB$ PutCounter | Defined$ Self | CounterType$ HUNGER | CounterNum$ 1 | SubAbility$ DBDestroyHunger
SVar:DBDestroyHunger:DB$ Destroy | Defined$ Self | ConditionDefined$ Self | ConditionPresent$ Card.counters_GE5_HUNGER SVar:DBDestroyHunger:DB$ Destroy | Defined$ Self | ConditionDefined$ Self | ConditionPresent$ Card.counters_GE5_HUNGER
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Layer$ Other | Optional$ True | ReplaceWith$ DBGainLife | Description$ If you would begin your draw step, you may skip that step instead. If you do, you gain 2 life. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Layer$ Other | Optional$ True | ReplaceWith$ DBGainLife | Description$ If you would begin your draw step, you may skip that step instead. If you do, you gain 2 life.
SVar:DBGainLife:DB$ GainLife | Defined$ You | LifeAmount$ 2 SVar:DBGainLife:DB$ GainLife | Defined$ You | LifeAmount$ 2
T:Mode$ Drawn | ValidCard$ Card.YouCtrl | TriggerZones$ Battlefield | Execute$ DBDestroySelf | TriggerDescription$ When you draw a card, destroy CARDNAME. T:Mode$ Drawn | ValidCard$ Card.YouCtrl | TriggerZones$ Battlefield | Execute$ DBDestroySelf | TriggerDescription$ When you draw a card, destroy CARDNAME.
SVar:DBDestroySelf:DB$ Destroy | Defined$ Self SVar:DBDestroySelf:DB$ Destroy | Defined$ Self

View File

@@ -2,7 +2,7 @@ Name:Gibbering Descent
ManaCost:4 B B ManaCost:4 B B
Types:Enchantment Types:Enchantment
K:Madness:2 B B K:Madness:2 B B
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Upkeep | Skip$ True | Hellbent$ True | Description$ Hellbent — Skip your upkeep step if you have no cards in hand. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Upkeep | Skip$ True | Hellbent$ True | Description$ Hellbent — Skip your upkeep step if you have no cards in hand.
T:Mode$ Phase | Phase$ Upkeep | Execute$ TrigLoseLifeDiscard | TriggerZones$ Battlefield | TriggerDescription$ At the beginning of each player's upkeep, that player loses 1 life and discards a card. T:Mode$ Phase | Phase$ Upkeep | Execute$ TrigLoseLifeDiscard | TriggerZones$ Battlefield | TriggerDescription$ At the beginning of each player's upkeep, that player loses 1 life and discards a card.
SVar:TrigLoseLifeDiscard:DB$ LoseLife | Defined$ TriggeredPlayer | LifeAmount$ 1 | SubAbility$ DBDiscard SVar:TrigLoseLifeDiscard:DB$ LoseLife | Defined$ TriggeredPlayer | LifeAmount$ 1 | SubAbility$ DBDiscard
SVar:DBDiscard:DB$ Discard | Defined$ TriggeredPlayer | NumCards$ 1 | Mode$ TgtChoose SVar:DBDiscard:DB$ Discard | Defined$ TriggeredPlayer | NumCards$ 1 | Mode$ TgtChoose

View File

@@ -4,7 +4,7 @@ Types:Creature Demon
PT:6/6 PT:6/6
K:Flying K:Flying
K:Trample K:Trample
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
T:Mode$ SpellCast | ValidCard$ Card | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDraw | TriggerDescription$ Whenever you play a land or cast a spell, you draw a card and you lose 1 life. T:Mode$ SpellCast | ValidCard$ Card | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDraw | TriggerDescription$ Whenever you play a land or cast a spell, you draw a card and you lose 1 life.
T:Mode$ LandPlayed | ValidCard$ Land.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigDraw | Secondary$ True | TriggerDescription$ Whenever you play a land or cast a spell, you draw a card and you lose 1 life. T:Mode$ LandPlayed | ValidCard$ Land.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigDraw | Secondary$ True | TriggerDescription$ Whenever you play a land or cast a spell, you draw a card and you lose 1 life.
SVar:TrigDraw:DB$ Draw | Defined$ You | NumCards$ 1 | SubAbility$ DBLoseLife SVar:TrigDraw:DB$ Draw | Defined$ You | NumCards$ 1 | SubAbility$ DBLoseLife

View File

@@ -4,7 +4,7 @@ Types:Creature Leech Horror
PT:*/* PT:*/*
K:Kicker:U K:Kicker:U
K:ETBReplacement:Other:TrigMill K:ETBReplacement:Other:TrigMill
SVar:TrigMill:DB$ Mill | NumCards$ 4 | Defined$ You | Condition$ Kicked | SpellDescription$ As CARDNAME enters, if it was kicked, mill four cards. (To mill a card, put the top card of your library into your graveyard.) SVar:TrigMill:DB$ Mill | NumCards$ 4 | Defined$ You | ConditionDefined$ Self | ConditionPresent$ Card.kicked | SpellDescription$ As CARDNAME enters, if it was kicked, mill four cards. (To mill a card, put the top card of your library into your graveyard.)
S:Mode$ Continuous | CharacteristicDefining$ True | SetPower$ X | SetToughness$ X | Description$ CARDNAME's power and toughness are each equal to the highest mana value among cards in your graveyard. S:Mode$ Continuous | CharacteristicDefining$ True | SetPower$ X | SetToughness$ X | Description$ CARDNAME's power and toughness are each equal to the highest mana value among cards in your graveyard.
SVar:X:Count$ValidGraveyard Card.YouOwn$GreatestCMC SVar:X:Count$ValidGraveyard Card.YouOwn$GreatestCMC
SVar:NoZeroToughnessAI:True SVar:NoZeroToughnessAI:True

View File

@@ -1,7 +1,7 @@
Name:Necrodominance Name:Necrodominance
ManaCost:B B B ManaCost:B B B
Types:Legendary Enchantment Types:Legendary Enchantment
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDraw | TriggerDescription$ At the beginning of your end step, you may pay any amount of life. If you do, draw that many cards. T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDraw | TriggerDescription$ At the beginning of your end step, you may pay any amount of life. If you do, draw that many cards.
SVar:TrigDraw:AB$ Draw | Cost$ PayLife<X> | NumCards$ X SVar:TrigDraw:AB$ Draw | Cost$ PayLife<X> | NumCards$ X
SVar:X:Count$xPaid SVar:X:Count$xPaid

View File

@@ -1,7 +1,7 @@
Name:Necropotence Name:Necropotence
ManaCost:B B B ManaCost:B B B
Types:Enchantment Types:Enchantment
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
T:Mode$ Discarded | ValidCard$ Card.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigChange | TriggerDescription$ Whenever you discard a card, exile that card from your graveyard. T:Mode$ Discarded | ValidCard$ Card.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigChange | TriggerDescription$ Whenever you discard a card, exile that card from your graveyard.
SVar:TrigChange:DB$ ChangeZone | Defined$ TriggeredCard | Origin$ Graveyard | Destination$ Exile SVar:TrigChange:DB$ ChangeZone | Defined$ TriggeredCard | Origin$ Graveyard | Destination$ Exile
A:AB$ ChangeZone | Cost$ PayLife<1> | Defined$ TopOfLibrary | Origin$ Library | Destination$ Exile | ExileFaceDown$ True | RememberChanged$ True | SubAbility$ DelayedReturn | AILogic$ Necropotence | AILifeThreshold$ 1 | SpellDescription$ Exile the top card of your library face down. Put that card into your hand at the beginning of your next end step. A:AB$ ChangeZone | Cost$ PayLife<1> | Defined$ TopOfLibrary | Origin$ Library | Destination$ Exile | ExileFaceDown$ True | RememberChanged$ True | SubAbility$ DelayedReturn | AILogic$ Necropotence | AILifeThreshold$ 1 | SpellDescription$ Exile the top card of your library face down. Put that card into your hand at the beginning of your next end step.

View File

@@ -2,7 +2,7 @@ Name:Necropotence Avatar
ManaCost:no cost ManaCost:no cost
Types:Vanguard Types:Vanguard
HandLifeModifier:+0/+4 HandLifeModifier:+0/+4
R:Event$ BeginPhase | ActiveZones$ Command | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Command | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
T:Mode$ Phase | Phase$ End Of Turn | ValidPlayer$ You | TriggerZones$ Command | CheckSVar$ Turns | SVarCompare$ GT1 | Execute$ TrigPutCounter | TriggerDescription$ At the beginning of your end step, if it's not the first turn of the game, put a death counter on CARDNAME. You draw X cards and you lose X life, where X is the number of death counters on CARDNAME. T:Mode$ Phase | Phase$ End Of Turn | ValidPlayer$ You | TriggerZones$ Command | CheckSVar$ Turns | SVarCompare$ GT1 | Execute$ TrigPutCounter | TriggerDescription$ At the beginning of your end step, if it's not the first turn of the game, put a death counter on CARDNAME. You draw X cards and you lose X life, where X is the number of death counters on CARDNAME.
SVar:TrigPutCounter:DB$ PutCounter | Defined$ Self | CounterType$ DEATH | CounterNum$ 1 | SubAbility$ TrigDraw SVar:TrigPutCounter:DB$ PutCounter | Defined$ Self | CounterType$ DEATH | CounterNum$ 1 | SubAbility$ TrigDraw
SVar:TrigDraw:DB$ Draw | Defined$ You | NumCards$ X | SubAbility$ DBLoseLife SVar:TrigDraw:DB$ Draw | Defined$ You | NumCards$ X | SubAbility$ DBLoseLife

View File

@@ -1,7 +1,7 @@
Name:Null Profusion Name:Null Profusion
ManaCost:4 B B ManaCost:4 B B
Types:Enchantment Types:Enchantment
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
S:Mode$ Continuous | Affected$ You | SetMaxHandSize$ 2 | Description$ Your maximum hand size is 2. S:Mode$ Continuous | Affected$ You | SetMaxHandSize$ 2 | Description$ Your maximum hand size is 2.
T:Mode$ SpellCast | ValidCard$ Card | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDraw | TriggerDescription$ Whenever you play a card, draw a card. T:Mode$ SpellCast | ValidCard$ Card | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDraw | TriggerDescription$ Whenever you play a card, draw a card.
T:Mode$ LandPlayed | ValidCard$ Land.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigDraw | Secondary$ True | TriggerDescription$ Whenever you play a card, draw a card. T:Mode$ LandPlayed | ValidCard$ Land.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigDraw | Secondary$ True | TriggerDescription$ Whenever you play a card, draw a card.

View File

@@ -3,7 +3,7 @@ ManaCost:2 U U
Types:Enchantment Aura Types:Enchantment Aura
K:Enchant opponent K:Enchant opponent
A:SP$ Attach | ValidTgts$ Opponent | AILogic$ Curse A:SP$ Attach | ValidTgts$ Opponent | AILogic$ Curse
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
T:Mode$ Drawn | ValidCard$ Card.OwnedBy Player.EnchantedBy | TriggerZones$ Battlefield | Execute$ TrigDraw | OptionalDecider$ You | TriggerDescription$ Whenever enchanted opponent draws a card, you may draw a card. T:Mode$ Drawn | ValidCard$ Card.OwnedBy Player.EnchantedBy | TriggerZones$ Battlefield | Execute$ TrigDraw | OptionalDecider$ You | TriggerDescription$ Whenever enchanted opponent draws a card, you may draw a card.
SVar:TrigDraw:DB$ Draw | NumCards$ 1 SVar:TrigDraw:DB$ Draw | NumCards$ 1
AI:RemoveDeck:All AI:RemoveDeck:All

View File

@@ -1,7 +1,7 @@
Name:Recycle Name:Recycle
ManaCost:4 G G ManaCost:4 G G
Types:Enchantment Types:Enchantment
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
S:Mode$ Continuous | Affected$ You | SetMaxHandSize$ 2 | Description$ Your maximum hand size is 2. S:Mode$ Continuous | Affected$ You | SetMaxHandSize$ 2 | Description$ Your maximum hand size is 2.
T:Mode$ SpellCast | ValidCard$ Card | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDraw | TriggerDescription$ Whenever you play a card, draw a card. T:Mode$ SpellCast | ValidCard$ Card | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDraw | TriggerDescription$ Whenever you play a card, draw a card.
T:Mode$ LandPlayed | ValidCard$ Land.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigDraw | Secondary$ True | TriggerDescription$ Whenever you play a card, draw a card. T:Mode$ LandPlayed | ValidCard$ Land.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigDraw | Secondary$ True | TriggerDescription$ Whenever you play a card, draw a card.

View File

@@ -1,7 +1,7 @@
Name:Sands of Time Name:Sands of Time
ManaCost:4 ManaCost:4
Types:Artifact Types:Artifact
R:Event$ BeginPhase | ActiveZones$ Battlefield | ActivePhases$ Untap | Skip$ True | Description$ Each player skips their untap step. R:Event$ BeginPhase | ActiveZones$ Battlefield | Phase$ Untap | Skip$ True | Description$ Each player skips their untap step.
T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ Player | TriggerZones$ Battlefield | Execute$ TrigSands | TriggerDescription$ At the beginning of each player's upkeep, that player simultaneously untaps each tapped artifact, creature, and land they control and taps each untapped artifact, creature, and land they control. T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ Player | TriggerZones$ Battlefield | Execute$ TrigSands | TriggerDescription$ At the beginning of each player's upkeep, that player simultaneously untaps each tapped artifact, creature, and land they control and taps each untapped artifact, creature, and land they control.
SVar:TrigSands:DB$ UntapAll | Defined$ TriggeredPlayer | ValidCards$ Artifact.tapped,Creature.tapped,Land.tapped | RememberUntapped$ True | SubAbility$ DBTap SVar:TrigSands:DB$ UntapAll | Defined$ TriggeredPlayer | ValidCards$ Artifact.tapped,Creature.tapped,Land.tapped | RememberUntapped$ True | SubAbility$ DBTap
SVar:DBTap:DB$ TapAll | Defined$ TriggeredPlayer | ValidCards$ Artifact.untapped+IsNotRemembered,Creature.untapped+IsNotRemembered,Land.untapped+IsNotRemembered | TapperController$ True | SubAbility$ DBCleanup SVar:DBTap:DB$ TapAll | Defined$ TriggeredPlayer | ValidCards$ Artifact.untapped+IsNotRemembered,Creature.untapped+IsNotRemembered,Land.untapped+IsNotRemembered | TapperController$ True | SubAbility$ DBCleanup

View File

@@ -3,7 +3,7 @@ ManaCost:2 W
Types:Enchantment Types:Enchantment
T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigUpkeep | TriggerDescription$ At the beginning of your upkeep, sacrifice CARDNAME unless you discard a card. T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigUpkeep | TriggerDescription$ At the beginning of your upkeep, sacrifice CARDNAME unless you discard a card.
SVar:TrigUpkeep:DB$ Sacrifice | UnlessPayer$ You | UnlessCost$ Discard<1/Card> SVar:TrigUpkeep:DB$ Sacrifice | UnlessPayer$ You | UnlessCost$ Discard<1/Card>
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
S:Mode$ Continuous | Affected$ You | AddKeyword$ Shroud | Description$ You have shroud. (You can't be the target of spells or abilities.) S:Mode$ Continuous | Affected$ You | AddKeyword$ Shroud | Description$ You have shroud. (You can't be the target of spells or abilities.)
R:Event$ DamageDone | ActiveZones$ Battlefield | Prevent$ True | ValidTarget$ You | Description$ Prevent all damage that would be dealt to you. R:Event$ DamageDone | ActiveZones$ Battlefield | Prevent$ True | ValidTarget$ You | Description$ Prevent all damage that would be dealt to you.
AI:RemoveDeck:All AI:RemoveDeck:All

View File

@@ -1,7 +1,7 @@
Name:Stasis Name:Stasis
ManaCost:1 U ManaCost:1 U
Types:Enchantment Types:Enchantment
R:Event$ BeginPhase | ActiveZones$ Battlefield | ActivePhases$ Untap | Skip$ True | Description$ Players skip their untap steps. R:Event$ BeginPhase | ActiveZones$ Battlefield | Phase$ Untap | Skip$ True | Description$ Players skip their untap steps.
T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigUpkeep | TriggerDescription$ At the beginning of your upkeep, sacrifice CARDNAME unless you pay {U}. T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigUpkeep | TriggerDescription$ At the beginning of your upkeep, sacrifice CARDNAME unless you pay {U}.
SVar:TrigUpkeep:DB$ Sacrifice | UnlessPayer$ You | UnlessCost$ U SVar:TrigUpkeep:DB$ Sacrifice | UnlessPayer$ You | UnlessCost$ U
AI:RemoveDeck:Random AI:RemoveDeck:Random

View File

@@ -1,7 +1,7 @@
Name:Symbiotic Deployment Name:Symbiotic Deployment
ManaCost:2 G ManaCost:2 G
Types:Enchantment Types:Enchantment
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
A:AB$ Draw | Cost$ 1 tapXType<2/Creature> | Defined$ You | NumCards$ 1 | SpellDescription$ Draw a card. A:AB$ Draw | Cost$ 1 tapXType<2/Creature> | Defined$ You | NumCards$ 1 | SpellDescription$ Draw a card.
AI:RemoveDeck:Random AI:RemoveDeck:Random
SVar:NonStackingEffect:True SVar:NonStackingEffect:True

View File

@@ -2,7 +2,7 @@ Name:Taigam, Sidisi's Hand
ManaCost:3 U B ManaCost:3 U B
Types:Legendary Creature Human Wizard Types:Legendary Creature Human Wizard
PT:3/4 PT:3/4
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDig | TriggerDescription$ At the beginning of your upkeep, look at the top three cards of your library. Put one of them into your hand and the rest into your graveyard. T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigDig | TriggerDescription$ At the beginning of your upkeep, look at the top three cards of your library. Put one of them into your hand and the rest into your graveyard.
SVar:TrigDig:DB$ Dig | DigNum$ 3 | DestinationZone2$ Graveyard | NoReveal$ True | SpellDescription$ Look at the top three cards of your library. Put one of them into your hand and the rest into your graveyard. SVar:TrigDig:DB$ Dig | DigNum$ 3 | DestinationZone2$ Graveyard | NoReveal$ True | SpellDescription$ Look at the top three cards of your library. Put one of them into your hand and the rest into your graveyard.
A:AB$ Pump | Cost$ B T ExileFromGrave<X/Card> | CostDesc$ {B}, {T}, Exile X cards from your graveyard: | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumAtt$ -X | NumDef$ -X | IsCurse$ True | SpellDescription$ Target creature gets -X/-X until end of turn. A:AB$ Pump | Cost$ B T ExileFromGrave<X/Card> | CostDesc$ {B}, {T}, Exile X cards from your graveyard: | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumAtt$ -X | NumDef$ -X | IsCurse$ True | SpellDescription$ Target creature gets -X/-X until end of turn.

View File

@@ -1,7 +1,7 @@
Name:The Eon Fog Name:The Eon Fog
ManaCost:no cost ManaCost:no cost
Types:Plane Equilor Types:Plane Equilor
R:Event$ BeginPhase | ActiveZones$ Command | ActivePhases$ Untap | Skip$ True | Description$ Players skip their untap steps. R:Event$ BeginPhase | ActiveZones$ Command | Phase$ Untap | Skip$ True | Description$ Players skip their untap steps.
T:Mode$ ChaosEnsues | TriggerZones$ Command | Execute$ RolledChaos | TriggerDescription$ Whenever chaos ensues, untap all permanents you control. T:Mode$ ChaosEnsues | TriggerZones$ Command | Execute$ RolledChaos | TriggerDescription$ Whenever chaos ensues, untap all permanents you control.
SVar:RolledChaos:DB$ UntapAll | ValidCards$ Permanent.YouCtrl SVar:RolledChaos:DB$ UntapAll | ValidCards$ Permanent.YouCtrl
SVar:AIRollPlanarDieParams:Mode$ Always | LowPriority$ True | MaxRollsPerTurn$ 9 SVar:AIRollPlanarDieParams:Mode$ Always | LowPriority$ True | MaxRollsPerTurn$ 9

View File

@@ -1,7 +1,7 @@
Name:Wild Wasteland Name:Wild Wasteland
ManaCost:2 R ManaCost:2 R
Types:Enchantment Types:Enchantment
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | Execute$ ExileTwo | TriggerZones$ Battlefield | TriggerDescription$ At the beginning of your upkeep, exile the top two cards of your library. You may play those cards this turn. T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | Execute$ ExileTwo | TriggerZones$ Battlefield | TriggerDescription$ At the beginning of your upkeep, exile the top two cards of your library. You may play those cards this turn.
SVar:ExileTwo:DB$ Dig | Defined$ You | DigNum$ 2 | ChangeNum$ All | DestinationZone$ Exile | RememberChanged$ True | SubAbility$ DBEffect SVar:ExileTwo:DB$ Dig | Defined$ You | DigNum$ 2 | ChangeNum$ All | DestinationZone$ Exile | RememberChanged$ True | SubAbility$ DBEffect
SVar:DBEffect:DB$ Effect | RememberObjects$ RememberedCard | StaticAbilities$ STPlay | SubAbility$ DBCleanup | ForgetOnMoved$ Exile | Duration$ EndOfTurn SVar:DBEffect:DB$ Effect | RememberObjects$ RememberedCard | StaticAbilities$ STPlay | SubAbility$ DBCleanup | ForgetOnMoved$ Exile | Duration$ EndOfTurn

View File

@@ -1,7 +1,7 @@
Name:Yawgmoth's Bargain Name:Yawgmoth's Bargain
ManaCost:4 B B ManaCost:4 B B
Types:Enchantment Types:Enchantment
R:Event$ BeginPhase | ActiveZones$ Battlefield | PlayerTurn$ You | ActivePhases$ Draw | Skip$ True | Description$ Skip your draw step. R:Event$ BeginPhase | ActiveZones$ Battlefield | ValidPlayer$ You | Phase$ Draw | Skip$ True | Description$ Skip your draw step.
A:AB$ Draw | Cost$ PayLife<1> | NumCards$ 1 | AILogic$ YawgmothsBargain | AILifeThreshold$ 1 | SpellDescription$ Draw a card. A:AB$ Draw | Cost$ PayLife<1> | NumCards$ 1 | AILogic$ YawgmothsBargain | AILifeThreshold$ 1 | SpellDescription$ Draw a card.
SVar:AICastPreference:NeverCastIfLifeBelow$ 7 SVar:AICastPreference:NeverCastIfLifeBelow$ 7
AI:RemoveDeck:Random AI:RemoveDeck:Random