Commit e529765c authored by swordshine's avatar swordshine

Merge branch 'patch' into 'master'

More ELD cards

See merge request !2129
parents 5ded6fcf c8cb56c4
......@@ -259,7 +259,19 @@ public abstract class CardTraitBase extends GameObject implements IHasCardView {
return false;
}
final String payingMana = StringUtils.join(hostCard.getCastSA().getPayingMana());
if (StringUtils.countMatches(payingMana, MagicColor.toShortString(params.get("Adamant"))) < 3) {
final String color = params.get("Adamant");
if ("Any".equals(color)) {
boolean bFlag = false;
for (byte c : MagicColor.WUBRG) {
if (StringUtils.countMatches(payingMana, MagicColor.toShortString(c)) >= 3) {
bFlag = true;
break;
}
}
if (!bFlag) {
return false;
}
} else if (StringUtils.countMatches(payingMana, MagicColor.toShortString(color)) < 3) {
return false;
}
}
......
......@@ -1620,7 +1620,8 @@ public class AbilityUtils {
// Count$Adamant.<Color>.<True>.<False>
if (sq[0].startsWith("Adamant")) {
final String payingMana = StringUtils.join(sa.getRootAbility().getPayingMana());
final boolean adamant = StringUtils.countMatches(payingMana, MagicColor.toShortString(sq[1])) >= 3;
final int num = sq[0].length() > 7 ? Integer.parseInt(sq[0].split("_")[1]) : 3;
final boolean adamant = StringUtils.countMatches(payingMana, MagicColor.toShortString(sq[1])) >= num;
return CardFactoryUtil.doXMath(Integer.parseInt(sq[adamant ? 2 : 3]), expr, c);
}
......
......@@ -56,7 +56,8 @@ public final class CardUtil {
"Transmute", "Replicate", "Recover", "Suspend", "Aura swap",
"Fortify", "Transfigure", "Champion", "Evoke", "Prowl", "IfReach",
"Reinforce", "Unearth", "Level up", "Miracle", "Overload",
"Scavenge", "Bestow", "Outlast", "Dash", "Surge", "Emerge", "Hexproof:").build();
"Scavenge", "Bestow", "Outlast", "Dash", "Surge", "Emerge", "Hexproof:",
"etbCounter").build();
/** List of keyword endings of keywords that could be modified by text changes. */
public static final ImmutableList<String> modifiableKeywordEndings = ImmutableList.<String>builder().add(
"walk", "cycling", "offering").build();
......
......@@ -4,12 +4,7 @@ Types:Plane Ravnica
S:Mode$ CantAttack | EffectZone$ Command | ValidCard$ Creature.YouCtrl | CheckSVar$ CheckThisTurnCast | Description$ If you cast a spell this turn, you can't attack with creatures.
SVar:CheckThisTurnCast:Count$ThisTurnCast_Card.YouCtrl
S:Mode$ CantBeCast | EffectZone$ Command | ValidCard$ Card | Caster$ You | CheckSVar$ CheckThisTurnAttacked | Description$ If you attacked with creatures this turn, you can't cast spells.
SVar:CheckThisTurnAttacked:Number$0
T:Mode$ Attacks | ValidCard$ Creature.YouCtrl | Execute$ DBStoreSVar | Static$ True
SVar:DBStoreSVar:DB$ StoreSVar | SVar$ CheckThisTurnAttacked | Type$ Number | Expression$ 1
T:Mode$ PlaneswalkedFrom | ValidCard$ Plane.Self | Execute$ DBReset | Static$ True
T:Mode$ Phase | Phase$ Cleanup | Execute$ DBReset | Static$ True
SVar:DBReset:DB$ StoreSVar | SVar$ CheckThisTurnAttacked | Type$ Number | Expression$ 0
SVar:CheckThisTurnAttacked:Count$AttackersDeclared
T:Mode$ PlanarDice | Result$ Chaos | TriggerZones$ Command | Execute$ RolledChaos | TriggerDescription$ Whenever you roll {CHAOS}, you gain life equal to the number of cards in your hand.
SVar:RolledChaos:DB$ GainLife | LifeAmount$ PrahvX | References$ PrahvX | Defined$ You
SVar:PrahvX:Count$InYourHand
......
......@@ -2,10 +2,8 @@ Name:Psychic Intrusion
ManaCost:3 U B
Types:Sorcery
A:SP$ ChangeZone | Cost$ 3 U B | Origin$ Hand,Graveyard | Destination$ Exile | ValidTgts$ Opponent | DefinedPlayer$ Targeted | Chooser$ You | TgtPrompt$ Select target opponent | ChangeType$ Card.nonLand | ChangeNum$ 1 | IsCurse$ True | RememberChanged$ True | SubAbility$ DBEffect | StackDescription$ SpellDescription | SpellDescription$ Target opponent reveals their hand. You choose a nonland card from that player's graveyard or hand and exile it. You may cast that card for as long as it remains exiled, and you may spend mana as though it were mana of any color to cast that spell.
SVar:DBEffect:DB$ Effect | StaticAbilities$ STPlay | Triggers$ TriggerCastPI | SVars$ TrigRemoveSelf | RememberObjects$ Remembered | Duration$ Permanent | SubAbility$ DBCleanup
SVar:DBEffect:DB$ Effect | StaticAbilities$ STPlay | RememberObjects$ Remembered | Duration$ Permanent | ExileOnMoved$ Exile | SubAbility$ DBCleanup
SVar:STPlay:Mode$ Continuous | MayPlay$ True | MayPlayIgnoreColor$ True | EffectZone$ Command | Affected$ Card.IsRemembered | AffectedZone$ Exile | Description$ You may cast that card and you may spend mana as though it were mana of any color to cast it.
SVar:TriggerCastPI:Mode$ SpellCast | ValidCard$ Card.IsRemembered | TriggerZones$ Command | Execute$ TrigRemoveSelf | Static$ True
SVar:TrigRemoveSelf:DB$ ChangeZone | Defined$ Self | Origin$ Command | Destination$ Exile
SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True
AI:RemoveDeck:All
SVar:Picture:http://www.wizards.com/global/images/magic/general/psychic_intrusion.jpg
......
Name:Blow Your House Down
ManaCost:2 R
Types:Sorcery
A:SP$ Pump | Cost$ 2 R | ValidTgts$ Creature | TargetMin$ 0 | TargetMax$ 3 | KW$ HIDDEN CARDNAME can't block. | IsCurse$ True | TgtPrompt$ Select target creature | SubAbility$ DBDestroy | SpellDescription$ Up to three target creatures can't block this turn. Destroy any of them that are Walls.
SVar:DBDestroy:DB$ DestroyAll | ValidCards$ Targeted.Wall
Oracle:Up to three target creatures can't block this turn. Destroy any of them that are Walls.
Name:Clockwork Servant
ManaCost:3
Types:Artifact Creature Gnome
PT:2/3
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Adamant$ Any | Execute$ TrigDraw | TriggerDescription$ Adamant — When CARDNAME enters the battlefield, if at least three mana of the same color was spent to cast it, draw a card.
SVar:TrigDraw:DB$ Draw | Defined$ You | NumCards$ 1
Oracle:Adamant — When Clockwork Servant enters the battlefield, if at least three mana of the same color was spent to cast it, draw a card.
Name:Covetous Urge
ManaCost:U/B U/B U/B U/B
Types:Sorcery
A:SP$ ChangeZone | Cost$ U/B U/B U/B U/B | Origin$ Hand,Graveyard | Destination$ Exile | ValidTgts$ Opponent | DefinedPlayer$ Targeted | Chooser$ You | TgtPrompt$ Select target opponent | ChangeType$ Card.nonLand | ChangeNum$ 1 | IsCurse$ True | RememberChanged$ True | SubAbility$ DBEffect | StackDescription$ SpellDescription | SpellDescription$ Target opponent reveals their hand. You choose a nonland card from that player's graveyard or hand and exile it. You may cast that card for as long as it remains exiled, and you may spend mana as though it were mana of any color to cast that spell.
SVar:DBEffect:DB$ Effect | StaticAbilities$ STPlay | RememberObjects$ Remembered | Duration$ Permanent | ExileOnMoved$ Exile | SubAbility$ DBCleanup
SVar:STPlay:Mode$ Continuous | MayPlay$ True | MayPlayIgnoreColor$ True | EffectZone$ Command | Affected$ Card.IsRemembered | AffectedZone$ Exile | Description$ You may cast that card and you may spend mana as though it were mana of any color to cast it.
SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True
AI:RemoveDeck:All
Oracle:Target opponent reveals their hand. You choose a nonland card from that player's graveyard or hand and exile it. You may cast that card for as long as it remains exiled, and you may spend mana as though it were mana of any color to cast that spell.
......@@ -3,7 +3,5 @@ ManaCost:3 R
Types:Creature Human Knight
PT:4/1
K:Haste
R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | Adamant$ Red | ReplaceWith$ ETBAddCounter | Description$ Adamant — If at least three red mana was spent to cast this spell, CARDNAME enters the battlefield with a +1/+1 counter on it.
SVar:ETBAddCounter:DB$ PutCounter | ETB$ True | Defined$ Self | CounterType$ P1P1 | CounterNum$ 1 | SubAbility$ MoveToPlay
SVar:MoveToPlay:DB$ ChangeZone | Hidden$ True | Origin$ All | Destination$ Battlefield | Defined$ ReplacedCard
K:etbCounter:P1P1:1:Adamant$ Red:Adamant — If at least three red mana was spent to cast this spell, CARDNAME enters the battlefield with a +1/+1 counter on it.
Oracle:Haste\nAdamant — If at least three red mana was spent to cast this spell, Embereth Paladin enters the battlefield with a +1/+1 counter on it.
Name:Folio of Fancies
ManaCost:1 U
Types:Artifact
S:Mode$ Continuous | Affected$ Player | SetMaxHandSize$ Unlimited | Description$ Players have no maximum hand size.
SVar:NonStackingEffect:True
A:AB$ Draw | Cost$ X X T | NumCards$ X | References$ X | Defined$ Player | SpellDescription$ Each player draws X cards.
SVar:X:Count$xPaid
A:AB$ RepeatEach | Cost$ 2 U T | RepeatPlayers$ Player.Opponent | RepeatSubAbility$ DBMill | SpellDescription$ Each opponent puts a number of cards equal to the number of cards in their hand from the top of their library into their graveyard.
SVar:DBMill:DB$ Mill | Defined$ Remembered | NumCards$ Y | References$ Y
SVar:Y:Count$ValidHand Card.RememberedPlayerCtrl
AI:RemoveDeck:All
Oracle:Players have no maximum hand size.\n{X}{X}, {T}: Each player draws X cards.\n{2}{U}, {T}: Each opponent puts a number of cards equal to the number of cards in their hand from the top of their library into their graveyard.
......@@ -2,8 +2,6 @@ Name:Garenbrig Paladin
ManaCost:4 G
Types:Creature Giant Knight
PT:4/4
R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | Adamant$ Green | ReplaceWith$ ETBAddCounter | Description$ Adamant — If at least three green mana was spent to cast this spell, CARDNAME enters the battlefield with a +1/+1 counter on it.
SVar:ETBAddCounter:DB$ PutCounter | ETB$ True | Defined$ Self | CounterType$ P1P1 | CounterNum$ 1 | SubAbility$ MoveToPlay
SVar:MoveToPlay:DB$ ChangeZone | Hidden$ True | Origin$ All | Destination$ Battlefield | Defined$ ReplacedCard
K:etbCounter:P1P1:1:Adamant$ Green:Adamant — If at least three green mana was spent to cast this spell, CARDNAME enters the battlefield with a +1/+1 counter on it.
K:CantBeBlockedBy Creature.powerLE2
Oracle:Adamant — If at least three green mana was spent to cast this spell, Garenbrig Paladin enters the battlefield with a +1/+1 counter on it.\nGarenbrig Paladin can't be blocked by creatures with power 2 or less.
Name:Henge Walker
ManaCost:3
Types:Artifact Creature Golem
PT:2/2
K:etbCounter:P1P1:1:Adamant$ Any:Adamant — If at least three mana of the same color was spent to cast this spell, CARDNAME enters the battlefield with a +1/+1 counter on it.
Oracle:Adamant — If at least three mana of the same color was spent to cast this spell, Henge Walker enters the battlefield with a +1/+1 counter on it.
Name:Sundering Stroke
ManaCost:6 R
Types:Sorcery
A:SP$ DealDamage | Cost$ 6 R | ValidTgts$ Creature,Player,Planeswalker | TgtPrompt$ Select any target to distribute damage to | NumDmg$ 7 | TargetMin$ 1 | TargetMax$ 3 | DividedAsYouChoose$ 7 | ConditionCheckSVar$ X | ConditionSVarCompare$ EQ0 | References$ X | SubAbility$ DBDmgAll | StackDescription$ SpellDescription | SpellDescription$ CARDNAME deals 7 damage divided as you choose among one, two, or three targets. If at least seven red mana was spent to cast this spell, instead CARDNAME deals 7 damage to each of those permanents and/or players.
SVar:DBDmgAll:DB$ DealDamage | Defined$ Targeted | NumDmg$ 7 | ConditionCheckSVar$ X | References$ X | StackDescription$ None
SVar:X:Count$Adamant_7.Red.1.0
Oracle:Sundering Stroke deals 7 damage divided as you choose among one, two, or three targets. If at least seven red mana was spent to cast this spell, instead Sundering Stroke deals 7 damage to each of those permanents and/or players.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment