mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 12:18:00 +00:00
@@ -118,6 +118,7 @@ public enum AbilityKey {
|
|||||||
ScryBottom("ScryBottom"),
|
ScryBottom("ScryBottom"),
|
||||||
ScryNum("ScryNum"),
|
ScryNum("ScryNum"),
|
||||||
Sides("Sides"),
|
Sides("Sides"),
|
||||||
|
SimultaneousETB("SimultaneousETB"),
|
||||||
Source("Source"),
|
Source("Source"),
|
||||||
Sources("Sources"),
|
Sources("Sources"),
|
||||||
SourceSA("SourceSA"),
|
SourceSA("SourceSA"),
|
||||||
|
|||||||
@@ -107,8 +107,6 @@ public class ChangeZoneAllEffect extends SpellAbilityEffect {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
cards = (CardCollection)AbilityUtils.filterListByType(cards, sa.getParam("ChangeType"), sa);
|
|
||||||
|
|
||||||
if (sa.hasParam("Optional")) {
|
if (sa.hasParam("Optional")) {
|
||||||
final String targets = Lang.joinHomogenous(cards);
|
final String targets = Lang.joinHomogenous(cards);
|
||||||
final String message;
|
final String message;
|
||||||
@@ -123,6 +121,12 @@ public class ChangeZoneAllEffect extends SpellAbilityEffect {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
cards = (CardCollection)AbilityUtils.filterListByType(cards, sa.getParam("ChangeType"), sa);
|
||||||
|
|
||||||
|
if (sa.hasParam("TypeLimit")) {
|
||||||
|
cards = new CardCollection(Iterables.limit(cards, AbilityUtils.calculateAmount(source, sa.getParam("TypeLimit"), sa)));
|
||||||
|
}
|
||||||
|
|
||||||
if (sa.hasParam("ForgetOtherRemembered")) {
|
if (sa.hasParam("ForgetOtherRemembered")) {
|
||||||
source.clearRemembered();
|
source.clearRemembered();
|
||||||
}
|
}
|
||||||
@@ -171,6 +175,7 @@ public class ChangeZoneAllEffect extends SpellAbilityEffect {
|
|||||||
moveParams.put(AbilityKey.LastStateGraveyard, lastStateGraveyard);
|
moveParams.put(AbilityKey.LastStateGraveyard, lastStateGraveyard);
|
||||||
|
|
||||||
if (destination == ZoneType.Battlefield) {
|
if (destination == ZoneType.Battlefield) {
|
||||||
|
moveParams.put(AbilityKey.SimultaneousETB, cards);
|
||||||
if (sa.hasAdditionalAbility("AnimateSubAbility")) {
|
if (sa.hasAdditionalAbility("AnimateSubAbility")) {
|
||||||
// need LKI before Animate does apply
|
// need LKI before Animate does apply
|
||||||
moveParams.put(AbilityKey.CardLKI, CardUtil.getLKICopy(c));
|
moveParams.put(AbilityKey.CardLKI, CardUtil.getLKICopy(c));
|
||||||
|
|||||||
@@ -573,11 +573,11 @@ public class ChangeZoneEffect extends SpellAbilityEffect {
|
|||||||
}
|
}
|
||||||
|
|
||||||
movedCard = game.getAction().moveToLibrary(gameCard, libraryPosition, sa);
|
movedCard = game.getAction().moveToLibrary(gameCard, libraryPosition, sa);
|
||||||
} else {
|
} else if (destination.equals(ZoneType.Battlefield)) {
|
||||||
if (destination.equals(ZoneType.Battlefield)) {
|
|
||||||
Map<AbilityKey, Object> moveParams = AbilityKey.newMap();
|
Map<AbilityKey, Object> moveParams = AbilityKey.newMap();
|
||||||
moveParams.put(AbilityKey.LastStateBattlefield, lastStateBattlefield);
|
moveParams.put(AbilityKey.LastStateBattlefield, lastStateBattlefield);
|
||||||
moveParams.put(AbilityKey.LastStateGraveyard, lastStateGraveyard);
|
moveParams.put(AbilityKey.LastStateGraveyard, lastStateGraveyard);
|
||||||
|
moveParams.put(AbilityKey.SimultaneousETB, tgtCards);
|
||||||
if (sa.isReplacementAbility()) {
|
if (sa.isReplacementAbility()) {
|
||||||
ReplacementEffect re = sa.getReplacementEffect();
|
ReplacementEffect re = sa.getReplacementEffect();
|
||||||
moveParams.put(AbilityKey.ReplacementEffect, re);
|
moveParams.put(AbilityKey.ReplacementEffect, re);
|
||||||
@@ -763,7 +763,6 @@ public class ChangeZoneEffect extends SpellAbilityEffect {
|
|||||||
movedCard.setDiscarded(true);
|
movedCard.setDiscarded(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (!movedCard.getZone().equals(originZone)) {
|
if (!movedCard.getZone().equals(originZone)) {
|
||||||
Card meld = null;
|
Card meld = null;
|
||||||
triggerList.put(originZone.getZoneType(), movedCard.getZone().getZoneType(), movedCard);
|
triggerList.put(originZone.getZoneType(), movedCard.getZone().getZoneType(), movedCard);
|
||||||
@@ -1305,6 +1304,7 @@ public class ChangeZoneEffect extends SpellAbilityEffect {
|
|||||||
movedCard = game.getAction().moveToLibrary(c, libraryPos, sa, moveParams);
|
movedCard = game.getAction().moveToLibrary(c, libraryPos, sa, moveParams);
|
||||||
}
|
}
|
||||||
else if (destination.equals(ZoneType.Battlefield)) {
|
else if (destination.equals(ZoneType.Battlefield)) {
|
||||||
|
moveParams.put(AbilityKey.SimultaneousETB, chosenCards);
|
||||||
if (sa.hasParam("Tapped")) {
|
if (sa.hasParam("Tapped")) {
|
||||||
c.setTapped(true);
|
c.setTapped(true);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -398,11 +398,14 @@ public class DigEffect extends SpellAbilityEffect {
|
|||||||
if (sa.hasParam("Tapped")) {
|
if (sa.hasParam("Tapped")) {
|
||||||
c.setTapped(true);
|
c.setTapped(true);
|
||||||
}
|
}
|
||||||
if (destZone1.equals(ZoneType.Battlefield) && sa.hasParam("WithCounter")) {
|
if (destZone1.equals(ZoneType.Battlefield)) {
|
||||||
|
moveParams.put(AbilityKey.SimultaneousETB, movedCards);
|
||||||
|
if (sa.hasParam("WithCounter")) {
|
||||||
final int numCtr = AbilityUtils.calculateAmount(host,
|
final int numCtr = AbilityUtils.calculateAmount(host,
|
||||||
sa.getParamOrDefault("WithCounterNum", "1"), sa);
|
sa.getParamOrDefault("WithCounterNum", "1"), sa);
|
||||||
c.addEtbCounter(CounterType.getType(sa.getParam("WithCounter")), numCtr, player);
|
c.addEtbCounter(CounterType.getType(sa.getParam("WithCounter")), numCtr, player);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (sa.hasAdditionalAbility("AnimateSubAbility")) {
|
if (sa.hasAdditionalAbility("AnimateSubAbility")) {
|
||||||
// need LKI before Animate does apply
|
// need LKI before Animate does apply
|
||||||
moveParams.put(AbilityKey.CardLKI, CardUtil.getLKICopy(c));
|
moveParams.put(AbilityKey.CardLKI, CardUtil.getLKICopy(c));
|
||||||
@@ -477,8 +480,7 @@ public class DigEffect extends SpellAbilityEffect {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// just move them randomly
|
// just move them randomly
|
||||||
for (int i = 0; i < rest.size(); i++) {
|
for (Card c : rest) {
|
||||||
Card c = rest.get(i);
|
|
||||||
final ZoneType origin = c.getZone().getZoneType();
|
final ZoneType origin = c.getZone().getZoneType();
|
||||||
final PlayerZone toZone = c.getOwner().getZone(destZone2);
|
final PlayerZone toZone = c.getOwner().getZone(destZone2);
|
||||||
c = game.getAction().moveTo(toZone, c, sa);
|
c = game.getAction().moveTo(toZone, c, sa);
|
||||||
|
|||||||
@@ -99,11 +99,6 @@ public class DigUntilEffect extends SpellAbilityEffect {
|
|||||||
final Card host = sa.getHostCard();
|
final Card host = sa.getHostCard();
|
||||||
final Game game = host.getGame();
|
final Game game = host.getGame();
|
||||||
|
|
||||||
String[] type = new String[]{"Card"};
|
|
||||||
if (sa.hasParam("Valid")) {
|
|
||||||
type = sa.getParam("Valid").split(",");
|
|
||||||
}
|
|
||||||
|
|
||||||
int untilAmount = 1;
|
int untilAmount = 1;
|
||||||
if (sa.hasParam("Amount")) {
|
if (sa.hasParam("Amount")) {
|
||||||
untilAmount = AbilityUtils.calculateAmount(host, sa.getParam("Amount"), sa);
|
untilAmount = AbilityUtils.calculateAmount(host, sa.getParam("Amount"), sa);
|
||||||
@@ -115,6 +110,11 @@ public class DigUntilEffect extends SpellAbilityEffect {
|
|||||||
maxRevealed = AbilityUtils.calculateAmount(host, sa.getParam("MaxRevealed"), sa);
|
maxRevealed = AbilityUtils.calculateAmount(host, sa.getParam("MaxRevealed"), sa);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
String[] type = new String[]{"Card"};
|
||||||
|
if (sa.hasParam("Valid")) {
|
||||||
|
type = sa.getParam("Valid").split(",");
|
||||||
|
}
|
||||||
|
|
||||||
final boolean remember = sa.hasParam("RememberFound");
|
final boolean remember = sa.hasParam("RememberFound");
|
||||||
final boolean imprint = sa.hasParam("ImprintFound");
|
final boolean imprint = sa.hasParam("ImprintFound");
|
||||||
|
|
||||||
@@ -210,6 +210,7 @@ public class DigUntilEffect extends SpellAbilityEffect {
|
|||||||
moveParams.put(AbilityKey.LastStateGraveyard, lastStateGraveyard);
|
moveParams.put(AbilityKey.LastStateGraveyard, lastStateGraveyard);
|
||||||
Card m = null;
|
Card m = null;
|
||||||
if (foundDest.equals(ZoneType.Battlefield)) {
|
if (foundDest.equals(ZoneType.Battlefield)) {
|
||||||
|
moveParams.put(AbilityKey.SimultaneousETB, new CardCollection(c));
|
||||||
if (sa.hasParam("GainControl")) {
|
if (sa.hasParam("GainControl")) {
|
||||||
c.setController(sa.getActivatingPlayer(), game.getNextTimestamp());
|
c.setController(sa.getActivatingPlayer(), game.getNextTimestamp());
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -312,6 +312,7 @@ public class ReplacementHandler {
|
|||||||
replacementEffect.setReplacingObjects(runParams, tailend);
|
replacementEffect.setReplacingObjects(runParams, tailend);
|
||||||
//set original Params to update them later
|
//set original Params to update them later
|
||||||
tailend.setReplacingObject(AbilityKey.OriginalParams, runParams);
|
tailend.setReplacingObject(AbilityKey.OriginalParams, runParams);
|
||||||
|
tailend.setReplacingObjectsFrom(runParams, AbilityKey.SimultaneousETB);
|
||||||
tailend = tailend.getSubAbility();
|
tailend = tailend.getSubAbility();
|
||||||
} while(tailend != null);
|
} while(tailend != null);
|
||||||
|
|
||||||
|
|||||||
@@ -3,12 +3,12 @@ ManaCost:3 B B
|
|||||||
Types:Legendary Planeswalker Ashiok
|
Types:Legendary Planeswalker Ashiok
|
||||||
Loyalty:5
|
Loyalty:5
|
||||||
R:Event$ PayLife | ActiveZones$ Battlefield | ValidPlayer$ You | ReplaceWith$ ExileTop | Amount$ LEY | Description$ If you would pay life while your library has at least that many cards in it, exile that many cards from the top of your library instead.
|
R:Event$ PayLife | ActiveZones$ Battlefield | ValidPlayer$ You | ReplaceWith$ ExileTop | Amount$ LEY | Description$ If you would pay life while your library has at least that many cards in it, exile that many cards from the top of your library instead.
|
||||||
SVar:ExileTop:DB$ Dig | DigNum$ X | ChangeNum$ All | DestinationZone$ Exile
|
SVar:ExileTop:DB$ ChangeZoneAll | TypeLimit$ X | ChangeType$ Card.NotDefinedReplacedSimultaneousETB | Defined$ You | Origin$ Library | Destination$ Exile
|
||||||
SVar:X:ReplaceCount$Amount
|
SVar:X:ReplaceCount$Amount
|
||||||
SVar:Y:Count$ValidLibrary Card
|
SVar:Y:Count$ValidLibrary Card.YouOwn
|
||||||
A:AB$ Dig | Cost$ AddCounter<1/LOYALTY> | Planeswalker$ True | DigNum$ 2 | ChangeNum$ 1 | DestinationZone2$ Exile | NoReveal$ True | SpellDescription$ Look at the top two cards of your library. Exile one of them and put the other into your hand.
|
A:AB$ Dig | Cost$ AddCounter<1/LOYALTY> | Planeswalker$ True | DigNum$ 2 | ChangeNum$ 1 | DestinationZone2$ Exile | NoReveal$ True | SpellDescription$ Look at the top two cards of your library. Exile one of them and put the other into your hand.
|
||||||
A:AB$ Token | Cost$ SubCounter<2/LOYALTY> | Planeswalker$ True | TokenAmount$ 2 | TokenScript$ b_1_1_nightmare_exile_counter | TokenOwner$ You | SpellDescription$ Create two 1/1 black Nightmare creature tokens with "At the beginning of combat on your turn, if a card was put into exile this turn, put a +1/+1 counter on this creature."
|
A:AB$ Token | Cost$ SubCounter<2/LOYALTY> | Planeswalker$ True | TokenAmount$ 2 | TokenScript$ b_1_1_nightmare_exile_counter | TokenOwner$ You | SpellDescription$ Create two 1/1 black Nightmare creature tokens with "At the beginning of combat on your turn, if a card was put into exile this turn, put a +1/+1 counter on this creature."
|
||||||
A:AB$ Discard | Cost$ SubCounter<7/LOYALTY> | Planeswalker$ True | Ultimate$ True | ValidTgts$ Player | NumCards$ Z | Mode$ TgtChoose | SpellDescription$ Target player exiles the top X cards of their library, where X is the total mana value of cards you own in exile.
|
A:AB$ Dig | Cost$ SubCounter<7/LOYALTY> | Planeswalker$ True | Ultimate$ True | ValidTgts$ Player | DigNum$ Z | ChangeNum$ All | DestinationZone$ Exile | SpellDescription$ Target player exiles the top X cards of their library, where X is the total mana value of cards you own in exile.
|
||||||
SVar:Z:Count$ValidExile Card.YouOwn$SumCMC
|
SVar:Z:Count$ValidExile Card.YouOwn$SumCMC
|
||||||
AI:RemoveDeck:Random
|
AI:RemoveDeck:Random
|
||||||
Oracle:If you would pay life while your library has at least that many cards in it, exile that many cards from the top of your library instead.\n+1: Look at the top two cards of your library. Exile one of them and put the other into your hand.\n−2: Create two 1/1 black Nightmare creature tokens with "At the beginning of combat on your turn, if a card was put into exile this turn, put a +1/+1 counter on this creature."\n−7: Target player exiles the top X cards of their library, where X is the total mana value of cards you own in exile.
|
Oracle:If you would pay life while your library has at least that many cards in it, exile that many cards from the top of your library instead.\n+1: Look at the top two cards of your library. Exile one of them and put the other into your hand.\n−2: Create two 1/1 black Nightmare creature tokens with "At the beginning of combat on your turn, if a card was put into exile this turn, put a +1/+1 counter on this creature."\n−7: Target player exiles the top X cards of their library, where X is the total mana value of cards you own in exile.
|
||||||
|
|||||||
Reference in New Issue
Block a user