merge changes from shawnieboyuk-magarena-cards
commit
03d79d2a58
|
@ -1,5 +1,5 @@
|
|||
name=Aladdin
|
||||
url=http://magiccards.info/4e/en/309.html
|
||||
url=http://magiccards.info/ch/en/44.html
|
||||
image=http://mtgimage.com/card/aladdin.jpg
|
||||
value=3.909
|
||||
rarity=R
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
[
|
||||
new MagicWhenDamageIsDealtTrigger() {
|
||||
@Override
|
||||
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicDamage damage) {
|
||||
final MagicPlayer player = permanent.getController();
|
||||
final MagicTarget target = damage.getTarget();
|
||||
if (player == target && player.getLife() < 1) {
|
||||
player.setLife(1);
|
||||
}
|
||||
return MagicEvent.NONE;
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,11 @@
|
|||
name=Ali from Cairo
|
||||
url=http://magiccards.info/an/en/44.html
|
||||
image=http://mtgimage.com/card/ali%20from%20cairo.jpg
|
||||
value=4.156
|
||||
rarity=R
|
||||
type=Creature
|
||||
subtype=Human
|
||||
cost={2}{R}{R}
|
||||
pt=0/1
|
||||
timing=main
|
||||
requires_groovy_code
|
|
@ -5,5 +5,5 @@ value=1.817
|
|||
rarity=C
|
||||
type=Instant
|
||||
cost={3}{R}
|
||||
timing=pump
|
||||
timing=block
|
||||
requires_groovy_code
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
[
|
||||
new MagicSpellCardEvent() {
|
||||
@Override
|
||||
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
cardOnStack,
|
||||
this,
|
||||
"Destroy all white permanents."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
final Collection<MagicPermanent> targets=game.filterPermanents(event.getPlayer(),MagicTargetFilter.TARGET_WHITE_PERMANENT);
|
||||
game.doAction(new MagicDestroyAction(targets));
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,9 @@
|
|||
name=Anarchy
|
||||
url=http://magiccards.info/ia/en/170.html
|
||||
image=http://mtgimage.com/card/anarchy.jpg
|
||||
value=4.358
|
||||
rarity=R
|
||||
type=Sorcery
|
||||
cost={2}{R}{R}
|
||||
timing=main
|
||||
requires_groovy_code
|
|
@ -0,0 +1,9 @@
|
|||
name=Arenson's Aura
|
||||
url=http://magiccards.info/5e/en/282.html
|
||||
image=http://mtgimage.com/card/arenson's%20aura.jpg
|
||||
value=2.679
|
||||
rarity=U
|
||||
type=Enchantment
|
||||
cost={2}{W}
|
||||
ability=pay {W},Sacrifice an enchantment:Destroy target enchantment.;pay {3}{U}{U}:Counter target enchantment spell.
|
||||
timing=enchantment
|
|
@ -0,0 +1,11 @@
|
|||
name=Auratog
|
||||
url=http://magiccards.info/tsts/en/2.html
|
||||
image=http://mtgimage.com/card/auratog.jpg
|
||||
value=3.527
|
||||
rarity=R
|
||||
type=Creature
|
||||
subtype=Atog
|
||||
cost={1}{W}
|
||||
pt=1/2
|
||||
ability=pay Sacrifice an enchantment:SN gets +2/+2 until end of turn.
|
||||
timing=main
|
|
@ -0,0 +1,9 @@
|
|||
name=Breath of Dreams
|
||||
url=http://magiccards.info/ia/en/62.html
|
||||
image=http://mtgimage.com/card/breath%20of%20dreams.jpg
|
||||
value=2.707
|
||||
rarity=U
|
||||
type=Enchantment
|
||||
cost={2}{U}{U}
|
||||
ability=cumulative upkeep {U};lord green creatures gain cumulative upkeep {1}
|
||||
timing=enchantment
|
|
@ -1,5 +1,5 @@
|
|||
name=Cessation
|
||||
url=http://magiccards.info/ul/pt/4.html
|
||||
url=http://magiccards.info/ul/en/4.html
|
||||
image=http://mtgimage.com/card/cessation.jpg
|
||||
value=3.333
|
||||
rarity=C
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
[
|
||||
new MagicCDA() {
|
||||
@Override
|
||||
public void modPowerToughness(final MagicGame game,final MagicPlayer player,final MagicPowerToughness pt) {
|
||||
final int size = game.filterPermanents(player,MagicTargetFilter.TARGET_SNOW_LAND_YOU_CONTROL).size();
|
||||
pt.set(size, size);
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,11 @@
|
|||
name=Drift of the Dead
|
||||
url=http://magiccards.info/me2/en/86.html
|
||||
image=http://mtgimage.com/card/drift%20of%20the%20dead.jpg
|
||||
value=3.162
|
||||
rarity=C
|
||||
type=Creature
|
||||
subtype=Wall
|
||||
cost={3}{B}
|
||||
ability=defender
|
||||
timing=main
|
||||
requires_groovy_code
|
|
@ -0,0 +1,19 @@
|
|||
[
|
||||
new MagicWhenOtherDiesTrigger() {
|
||||
@Override
|
||||
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPermanent otherPermanent) {
|
||||
return (otherPermanent.isCreature()) ?
|
||||
new MagicEvent(
|
||||
permanent,
|
||||
otherPermanent.getController(),
|
||||
this,
|
||||
"PN sacrifices a land."
|
||||
) :
|
||||
MagicEvent.NONE;
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
game.addEvent(new MagicSacrificePermanentEvent(event.getSource(),event.getPlayer(),MagicTargetChoice.SACRIFICE_LAND));
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,10 @@
|
|||
name=Earthlink
|
||||
url=http://magiccards.info/ia/en/363.html
|
||||
image=http://mtgimage.com/card/earthlink.jpg
|
||||
value=3.4
|
||||
rarity=R
|
||||
type=Enchantment
|
||||
cost={3}{B}{R}{G}
|
||||
ability=your upkeep effect PN may pay {2}. If you don't, sacrifice SN.
|
||||
timing=enchantment
|
||||
requires_groovy_code
|
|
@ -0,0 +1,49 @@
|
|||
def ATTACKING_CREATURE_YOU_CONTROL = new MagicPermanentFilterImpl() {
|
||||
public boolean accept(final MagicGame game,final MagicPlayer player,final MagicPermanent target) {
|
||||
return target.isController(player) && target.isCreature() && target.isAttacking();
|
||||
}
|
||||
};
|
||||
|
||||
def TARGET_ATTACKING_CREATURE_YOU_CONTROL = new MagicTargetChoice(
|
||||
ATTACKING_CREATURE_YOU_CONTROL,
|
||||
MagicTargetHint.Positive,
|
||||
"target attacking creature you control"
|
||||
);
|
||||
|
||||
[
|
||||
new MagicPermanentActivation(
|
||||
new MagicActivationHints(MagicTiming.Block),
|
||||
"Untap"
|
||||
) {
|
||||
@Override
|
||||
public Iterable<MagicEvent> getCostEvent(final MagicPermanent source) {
|
||||
return [
|
||||
new MagicTapEvent(source), new MagicPayManaCostEvent(source, "{2}")
|
||||
];
|
||||
}
|
||||
|
||||
@Override
|
||||
public MagicEvent getPermanentEvent(final MagicPermanent source, final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
source,
|
||||
TARGET_ATTACKING_CREATURE_YOU_CONTROL,
|
||||
MagicTapTargetPicker.Untap,
|
||||
this,
|
||||
"Untap target attacking creature you control\$. " +
|
||||
"Prevent all combat damage that would be dealt to and dealt by it this turn."
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
event.processTargetPermanent(game, {
|
||||
final MagicPermanent creature ->
|
||||
game.doAction(new MagicUntapAction(creature));
|
||||
game.doAction(new MagicAddTurnTriggerAction(
|
||||
creature,
|
||||
MagicIfDamageWouldBeDealtTrigger.PreventCombatDamageDealtToDealtBy
|
||||
));
|
||||
});
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,9 @@
|
|||
name=Ebony Horse
|
||||
url=http://magiccards.info/4e/en/336.html
|
||||
image=http://mtgimage.com/card/ebony%20horse.jpg
|
||||
value=2.406
|
||||
rarity=C
|
||||
type=Artifact
|
||||
cost={3}
|
||||
timing=artifact
|
||||
requires_groovy_code
|
|
@ -0,0 +1,11 @@
|
|||
name=El-Hajjaj
|
||||
url=http://magiccards.info/4e/en/18.html
|
||||
image=http://mtgimage.com/card/el-hajjaj.jpg
|
||||
value=2.396
|
||||
rarity=R
|
||||
type=Creature
|
||||
subtype=Human,Wizard
|
||||
cost={1}{B}{B}
|
||||
pt=1/1
|
||||
timing=main
|
||||
requires_groovy_code=Mourning Thrull
|
|
@ -12,7 +12,7 @@ def TARGET_ATTACKING_CREATURE_YOU_CONTROL = new MagicTargetChoice(
|
|||
|
||||
[
|
||||
new MagicPermanentActivation(
|
||||
new MagicActivationHints(MagicTiming.Tapping),
|
||||
new MagicActivationHints(MagicTiming.Block),
|
||||
"Untap"
|
||||
) {
|
||||
@Override
|
||||
|
|
|
@ -0,0 +1,26 @@
|
|||
[
|
||||
new MagicPermanentActivation(
|
||||
new MagicActivationHints(MagicTiming.Removal),
|
||||
"Gain Life"
|
||||
) {
|
||||
@Override
|
||||
public Iterable<MagicEvent> getCostEvent(final MagicPermanent source) {
|
||||
return [
|
||||
new MagicSacrificePermanentEvent(source,MagicTargetChoice.SACRIFICE_ENCHANTMENT)
|
||||
];
|
||||
}
|
||||
@Override
|
||||
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
source,
|
||||
payedCost.getTarget(),
|
||||
this,
|
||||
"PN gains life equal to RN's converted mana cost."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
game.doAction(new MagicChangeLifeAction(event.getPlayer(),event.getRefPermanent().getConvertedCost()));
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,11 @@
|
|||
name=Faith Healer
|
||||
url=http://magiccards.info/us/en/14.html
|
||||
image=http://mtgimage.com/card/faith%20healer.jpg
|
||||
value=3.655
|
||||
rarity=R
|
||||
type=Creature
|
||||
subtype=Human,Cleric
|
||||
cost={1}{W}
|
||||
pt=1/1
|
||||
timing=main
|
||||
requires_groovy_code
|
|
@ -0,0 +1,30 @@
|
|||
[
|
||||
new MagicAdditionalCost() {
|
||||
@Override
|
||||
public MagicEvent getEvent(final MagicSource source) {
|
||||
return new MagicSacrificePermanentEvent(source, MagicTargetChoice.SACRIFICE_CREATURE);
|
||||
}
|
||||
},
|
||||
|
||||
new MagicSpellCardEvent() {
|
||||
@Override
|
||||
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
cardOnStack,
|
||||
MagicTargetChoice.NEG_TARGET_CREATURE_OR_PLAYER,
|
||||
payedCost.getTarget(),
|
||||
this,
|
||||
"SN deals damage equal to RN's power to target creature or player\$."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
event.processTarget(game, {
|
||||
final MagicTarget target ->
|
||||
final MagicPermanent sacrificed=event.getRefPermanent();
|
||||
final MagicDamage damage=new MagicDamage(event.getSource(),target,sacrificed.getPower());
|
||||
game.doAction(new MagicDealDamageAction(damage));
|
||||
});
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,9 @@
|
|||
name=Fling
|
||||
url=http://magiccards.info/pc2/en/44.html
|
||||
image=http://mtgimage.com/card/fling.jpg
|
||||
value=4.459
|
||||
rarity=C
|
||||
type=Instant
|
||||
cost={1}{R}
|
||||
timing=removal
|
||||
requires_groovy_code
|
|
@ -0,0 +1,40 @@
|
|||
[
|
||||
new MagicStatic(MagicLayer.ModPT) {
|
||||
@Override
|
||||
public void modPowerToughness(
|
||||
final MagicPermanent source,
|
||||
final MagicPermanent permanent,
|
||||
final MagicPowerToughness pt) {
|
||||
if (permanent.isEnchanted()) {
|
||||
pt.add(
|
||||
permanent.getAuraPermanents().size(),
|
||||
permanent.getAuraPermanents().size()
|
||||
);
|
||||
}
|
||||
}
|
||||
},
|
||||
new MagicPermanentActivation(
|
||||
new MagicActivationHints(MagicTiming.Pump),
|
||||
"Regen"
|
||||
) {
|
||||
@Override
|
||||
public Iterable<MagicEvent> getCostEvent(final MagicPermanent source) {
|
||||
return [
|
||||
new MagicSacrificePermanentEvent(source,MagicTargetChoice.SACRIFICE_AURA),
|
||||
new MagicRegenerationConditionsEvent(source,this)
|
||||
];
|
||||
}
|
||||
@Override
|
||||
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
source,
|
||||
this,
|
||||
"Regenerate SN."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
game.doAction(new MagicRegenerateAction(event.getPermanent()));
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,11 @@
|
|||
name=Gatherer of Graces
|
||||
url=http://magiccards.info/gp/en/85.html
|
||||
image=http://mtgimage.com/card/gatherer%20of%20graces.jpg
|
||||
value=3.05
|
||||
rarity=U
|
||||
type=Creature
|
||||
subtype=Human,Druid
|
||||
cost={1}{G}
|
||||
pt=1/2
|
||||
timing=main
|
||||
requires_groovy_code
|
|
@ -0,0 +1,29 @@
|
|||
[
|
||||
new MagicSpellCardEvent() {
|
||||
@Override
|
||||
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
cardOnStack,
|
||||
this,
|
||||
"SN deals 2 damage to each attacking creature and 1 damage to PN and each creature PN controls."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
final Collection<MagicPermanent> targets =
|
||||
game.filterPermanents(event.getPlayer(),MagicTargetFilter.TARGET_ATTACKING_CREATURE);
|
||||
final Collection<MagicPermanent> targets2 =
|
||||
game.filterPermanents(event.getPlayer(),MagicTargetFilter.TARGET_CREATURE_YOU_CONTROL);
|
||||
for (final MagicPermanent target : targets) {
|
||||
final MagicDamage damage = new MagicDamage(event.getSource(),target,2);
|
||||
game.doAction(new MagicDealDamageAction(damage));
|
||||
}
|
||||
for (final MagicPermanent target : targets2) {
|
||||
final MagicDamage damage2 = new MagicDamage(event.getSource(),target,1);
|
||||
game.doAction(new MagicDealDamageAction(damage2));
|
||||
}
|
||||
final MagicDamage damage3 = new MagicDamage(event.getSource(),event.getPlayer(),1);
|
||||
game.doAction(new MagicDealDamageAction(damage3));
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,9 @@
|
|||
name=Hail Storm
|
||||
url=http://magiccards.info/tsts/en/79.html
|
||||
image=http://mtgimage.com/card/hail%20storm.jpg
|
||||
value=3.312
|
||||
rarity=U
|
||||
type=Instant
|
||||
cost={1}{G}{G}
|
||||
timing=block
|
||||
requires_groovy_code
|
|
@ -0,0 +1,21 @@
|
|||
[
|
||||
new MagicSpellCardEvent() {
|
||||
@Override
|
||||
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
cardOnStack,
|
||||
this,
|
||||
"PN puts a 2/2 green Wolf creature token onto the battlefield for each Forest PN controls."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
final MagicPlayer player = event.getPlayer();
|
||||
game.doAction(new MagicPlayTokensAction(
|
||||
player,
|
||||
TokenCardDefinitions.get("2/2 green Wolf creature token"),
|
||||
player.getNrOfPermanents(MagicTargetFilter.TARGET_FOREST)
|
||||
));
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,9 @@
|
|||
name=Howl of the Night Pack
|
||||
url=http://magiccards.info/m14/en/178.html
|
||||
image=http://mtgimage.com/card/howl%20of%20the%20night%20pack.jpg
|
||||
value=3.69
|
||||
rarity=U
|
||||
type=Sorcery
|
||||
cost={6}{G}
|
||||
timing=main
|
||||
requires_groovy_code
|
|
@ -0,0 +1,9 @@
|
|||
name=Hymn of Rebirth
|
||||
url=http://magiccards.info/ia/en/373.html
|
||||
image=http://mtgimage.com/card/hymn%20of%20rebirth.jpg
|
||||
value=4.25
|
||||
rarity=U
|
||||
type=Sorcery
|
||||
cost={3}{G}{W}
|
||||
effect=return target creature card from a graveyard to the battlefield.
|
||||
timing=main
|
|
@ -0,0 +1,24 @@
|
|||
[
|
||||
new MagicWhenBlocksOrBecomesBlockedTrigger() {
|
||||
@Override
|
||||
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPermanent blocker) {
|
||||
final MagicPermanent target = permanent == blocker ? blocker.getBlockedCreature() : blocker;
|
||||
return new MagicEvent(
|
||||
permanent,
|
||||
target,
|
||||
this,
|
||||
"Destroy RN at end of combat."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
event.processRefPermanent(game, {
|
||||
final MagicPermanent permanent ->
|
||||
game.doAction(new MagicAddTriggerAction(
|
||||
permanent,
|
||||
MagicAtEndOfCombatTrigger.Destroy
|
||||
))
|
||||
});
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,11 @@
|
|||
name=Kjeldoran Frostbeast
|
||||
url=http://magiccards.info/ia/en/374.html
|
||||
image=http://mtgimage.com/card/kjeldoran%20frostbeast.jpg
|
||||
value=3.375
|
||||
rarity=U
|
||||
type=Creature
|
||||
subtype=Elemental,Beast
|
||||
cost={3}{G}{W}
|
||||
pt=2/4
|
||||
timing=main
|
||||
requires_groovy_code
|
|
@ -23,7 +23,7 @@
|
|||
new MagicSimpleMayChoice(
|
||||
MagicSimpleMayChoice.DRAW_CARDS,
|
||||
1,
|
||||
MagicSimpleMayChoice.DEFAULT_NONE
|
||||
MagicSimpleMayChoice.DEFAULT_YES
|
||||
),
|
||||
this,
|
||||
"PN may\$ draw a card."
|
||||
|
|
|
@ -0,0 +1,26 @@
|
|||
[
|
||||
new MagicPermanentActivation(
|
||||
new MagicActivationHints(MagicTiming.Pump),
|
||||
"Pump"
|
||||
) {
|
||||
@Override
|
||||
public Iterable<MagicEvent> getCostEvent(final MagicPermanent source) {
|
||||
return [
|
||||
new MagicPayManaCostEvent(source,"{W}")
|
||||
];
|
||||
}
|
||||
@Override
|
||||
public MagicEvent getPermanentEvent(final MagicPermanent source, final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
source,
|
||||
source.getEnchantedCreature(),
|
||||
this,
|
||||
"RN gains vigilance until end of turn."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
game.doAction(new MagicGainAbilityAction(event.getRefPermanent(),MagicAbility.Vigilance));
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,12 @@
|
|||
name=Ocular Halo
|
||||
url=http://magiccards.info/di/en/28.html
|
||||
image=http://mtgimage.com/card/ocular%20halo.jpg
|
||||
value=3.455
|
||||
rarity=C
|
||||
type=Enchantment
|
||||
subtype=Aura
|
||||
cost={3}{U}
|
||||
given_ability=pay {T}:PN draws a card.
|
||||
enchant=pump,pos creature
|
||||
timing=aura
|
||||
requires_groovy_code
|
|
@ -0,0 +1,11 @@
|
|||
name=Phantatog
|
||||
url=http://magiccards.info/od/en/291.html
|
||||
image=http://mtgimage.com/card/phantatog.jpg
|
||||
value=3.387
|
||||
rarity=U
|
||||
type=Creature
|
||||
subtype=Atog
|
||||
cost={1}{W}{U}
|
||||
pt=1/2
|
||||
ability=pay Sacrifice an enchantment:SN gets +1/+1 until end of turn;Discard a card:SN gets +1/+1 until end of turn.
|
||||
timing=main
|
|
@ -9,4 +9,4 @@ cost={5}{G}{W}
|
|||
pt=0/0
|
||||
ability=trample;enters with counter +1/+1 7
|
||||
timing=main
|
||||
requires_groovy_code=Phantom_Nomad
|
||||
requires_groovy_code=Phantom Nomad;Mourning Thrull
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
[
|
||||
new MagicSpellCardEvent() {
|
||||
@Override
|
||||
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
cardOnStack,
|
||||
this,
|
||||
"Blocking creatures get +0/+2 until end of turn."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
final Collection<MagicPermanent> targets=
|
||||
game.filterPermanents(event.getPlayer(),MagicTargetFilter.TARGET_BLOCKING_CREATURE);
|
||||
for (final MagicPermanent target : targets) {
|
||||
game.doAction(new MagicChangeTurnPTAction(target,0,2));
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,9 @@
|
|||
name=Piety
|
||||
url=http://magiccards.info/4eb/es/291.html
|
||||
image=http://mtgimage.com/card/piety.jpg
|
||||
value=1.463
|
||||
rarity=C
|
||||
type=Instant
|
||||
cost={2}{W}
|
||||
timing=block
|
||||
requires_groovy_code
|
|
@ -0,0 +1,9 @@
|
|||
name=Rain of Blades
|
||||
url=http://magiccards.info/m13/en/28.html
|
||||
image=http://mtgimage.com/card/rain%20of%20blades.jpg
|
||||
value=2.875
|
||||
rarity=U
|
||||
type=Instant
|
||||
cost={W}
|
||||
timing=block
|
||||
requires_groovy_code=Sandstorm
|
|
@ -0,0 +1,21 @@
|
|||
[
|
||||
new MagicSpellCardEvent() {
|
||||
@Override
|
||||
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
cardOnStack,
|
||||
this,
|
||||
"SN deals 1 damage to each attacking creature."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
final Collection<MagicPermanent> targets =
|
||||
game.filterPermanents(event.getPlayer(),MagicTargetFilter.TARGET_ATTACKING_CREATURE);
|
||||
for (final MagicPermanent target : targets) {
|
||||
final MagicDamage damage = new MagicDamage(event.getSource(),target,1);
|
||||
game.doAction(new MagicDealDamageAction(damage));
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,9 @@
|
|||
name=Sandstorm
|
||||
url=http://magiccards.info/br/en/64.html
|
||||
image=http://mtgimage.com/card/sandstorm.jpg
|
||||
value=3.442
|
||||
rarity=C
|
||||
type=Instant
|
||||
cost={G}
|
||||
timing=block
|
||||
requires_groovy_code
|
|
@ -0,0 +1,9 @@
|
|||
name=Teferi's Care
|
||||
url=http://magiccards.info/in/en/43.html
|
||||
image=http://mtgimage.com/card/teferi's%20care.jpg
|
||||
value=2.317
|
||||
rarity=U
|
||||
type=Enchantment
|
||||
cost={2}{W}
|
||||
ability=pay {W},Sacrifice an enchantment:Destroy target enchantment.;pay {3}{U}{U}:Counter target enchantment spell.
|
||||
timing=enchantment
|
|
@ -0,0 +1,11 @@
|
|||
name=Thaumatog
|
||||
url=http://magiccards.info/od/en/295.html
|
||||
image=http://mtgimage.com/card/thaumatog.jpg
|
||||
value=2.531
|
||||
rarity=U
|
||||
type=Creature
|
||||
subtype=Atog
|
||||
cost={1}{G}{W}
|
||||
pt=1/2
|
||||
ability=pay Sacrifice a land:SN gets +1/+1 until end of turn.;pay Sacrifice an enchantment:SN gets +1/+1 until end of turn.
|
||||
timing=main
|
|
@ -0,0 +1,26 @@
|
|||
[
|
||||
new MagicPermanentActivation(
|
||||
new MagicActivationHints(MagicTiming.Removal),
|
||||
"Weaken"
|
||||
) {
|
||||
@Override
|
||||
public Iterable<MagicEvent> getCostEvent(final MagicPermanent source) {
|
||||
return [
|
||||
new MagicPayManaCostEvent(source,"{1}{B}")
|
||||
];
|
||||
}
|
||||
@Override
|
||||
public MagicEvent getPermanentEvent(final MagicPermanent source, final MagicPayedCost payedCost) {
|
||||
return new MagicEvent(
|
||||
source,
|
||||
source.getEnchantedCreature(),
|
||||
this,
|
||||
"PN puts a -1/-1 counter on RN."
|
||||
);
|
||||
}
|
||||
@Override
|
||||
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
||||
game.doAction(new MagicChangeCountersAction(event.getRefPermanent(),MagicCounterType.MinusOne,1,true));
|
||||
}
|
||||
}
|
||||
]
|
|
@ -0,0 +1,11 @@
|
|||
name=Torture
|
||||
url=http://magiccards.info/tr/pt/53.html
|
||||
image=http://mtgimage.com/card/torture.jpg
|
||||
value=2.978
|
||||
rarity=C
|
||||
type=Enchantment
|
||||
subtype=Aura
|
||||
cost={B}
|
||||
enchant=weaken,creature
|
||||
timing=aura
|
||||
requires_groovy_code
|
|
@ -78,6 +78,9 @@ public class MagicTargetChoice extends MagicChoice {
|
|||
public static final MagicTargetChoice NEG_TARGET_ARTIFACT_SPELL =
|
||||
MagicTargetChoice.Negative("target artifact spell");
|
||||
|
||||
public static final MagicTargetChoice NEG_TARGET_ENCHANTMENT_SPELL =
|
||||
MagicTargetChoice.Negative("target enchantment spell");
|
||||
|
||||
public static final MagicTargetChoice TARGET_PLAYER =
|
||||
new MagicTargetChoice("target player");
|
||||
|
||||
|
@ -444,6 +447,9 @@ public class MagicTargetChoice extends MagicChoice {
|
|||
public static final MagicTargetChoice SACRIFICE_ENCHANTMENT =
|
||||
new MagicTargetChoice("an enchantment to sacrifice");
|
||||
|
||||
public static final MagicTargetChoice SACRIFICE_AURA =
|
||||
new MagicTargetChoice("an aura to sacrifice");
|
||||
|
||||
public static final MagicTargetChoice SACRIFICE_MOUNTAIN =
|
||||
new MagicTargetChoice("a Mountain to sacrifice");
|
||||
|
||||
|
|
|
@ -180,6 +180,10 @@ public abstract class MagicPermanentActivation extends MagicActivation<MagicPerm
|
|||
events.add(new MagicSacrificeEvent(source));
|
||||
} else if (cost.equals("Sacrifice an artifact")) {
|
||||
events.add(new MagicSacrificePermanentEvent(source,MagicTargetChoice.SACRIFICE_ARTIFACT));
|
||||
} else if (cost.equals("Sacrifice an enchantment")) {
|
||||
events.add(new MagicSacrificePermanentEvent(source,MagicTargetChoice.SACRIFICE_ENCHANTMENT));
|
||||
} else if (cost.equals("Sacrifice an aura")) {
|
||||
events.add(new MagicSacrificePermanentEvent(source,MagicTargetChoice.SACRIFICE_AURA));
|
||||
} else if (cost.equals("Sacrifice a creature")) {
|
||||
events.add(new MagicSacrificePermanentEvent(source,MagicTargetChoice.SACRIFICE_CREATURE));
|
||||
} else if (cost.equals("Sacrifice a Goblin")) {
|
||||
|
|
|
@ -132,7 +132,13 @@ public interface MagicTargetFilter<T extends MagicTarget> {
|
|||
return itemOnStack.isSpell(MagicType.Artifact);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
MagicStackFilterImpl TARGET_ENCHANTMENT_SPELL = new MagicStackFilterImpl() {
|
||||
public boolean accept(final MagicGame game,final MagicPlayer player,final MagicItemOnStack itemOnStack) {
|
||||
return itemOnStack.isSpell(MagicType.Enchantment);
|
||||
}
|
||||
};
|
||||
|
||||
MagicPlayerFilterImpl TARGET_PLAYER=new MagicPlayerFilterImpl() {
|
||||
public boolean accept(final MagicGame game,final MagicPlayer player,final MagicPlayer target) {
|
||||
return true;
|
||||
|
@ -156,6 +162,8 @@ public interface MagicTargetFilter<T extends MagicTarget> {
|
|||
};
|
||||
|
||||
MagicPermanentFilterImpl TARGET_BLACK_PERMANENT = Factory.permanent(MagicColor.Black, Control.Any);
|
||||
|
||||
MagicPermanentFilterImpl TARGET_WHITE_PERMANENT = Factory.permanent(MagicColor.White, Control.Any);
|
||||
|
||||
MagicPermanentFilterImpl TARGET_WHITE_PERMANENT_YOU_CONTROL = Factory.permanent(MagicColor.White, Control.You);
|
||||
|
||||
|
|
|
@ -73,6 +73,7 @@ public class MagicTargetFilterFactory {
|
|||
single.put("creature spell", TARGET_CREATURE_SPELL);
|
||||
single.put("noncreature spell", TARGET_NONCREATURE_SPELL);
|
||||
single.put("artifact spell", TARGET_ARTIFACT_SPELL);
|
||||
single.put("enchantment spell", TARGET_ENCHANTMENT_SPELL);
|
||||
single.put("red or green spell", TARGET_RED_GREEN_SPELL);
|
||||
single.put("black spell", TARGET_BLACK_SPELL);
|
||||
single.put("white spell", TARGET_WHITE_SPELL);
|
||||
|
|
Loading…
Reference in New Issue