merged new cards

master
melvin 2011-09-21 14:34:12 +08:00
commit befc28ae65
7 changed files with 282 additions and 0 deletions

View File

@ -1,3 +1,16 @@
>Elvish Champion
image=http://magiccards.info/scans/en/10e/261.jpg
value=3
rarity=R
type=Creature
subtype=Elf
color=g
converted=3
cost={1}{G}{G}
power=2
toughness=2
timing=fmain
>Bogardan Firefiend
image=http://magiccards.info/scans/en/10e/193.jpg
value=2
@ -1341,6 +1354,19 @@ power=1
toughness=1
timing=main
>Crafty Pathmage
image=http://magiccards.info/scans/en/10e/77.jpg
value=2
rarity=C
type=Creature
subtype=Human,Wizard
color=u
converted=3
cost={2}{U}
power=1
toughness=1
timing=main
>Goldenglow Moth
image=http://magiccards.info/scans/en/m11/15.jpg
value=2
@ -3696,6 +3722,17 @@ converted=1
cost={W}
timing=removal
>Condemn
image=http://magiccards.info/scans/en/m11/11.jpg
value=2
removal=3
rarity=U
type=Instant
color=w
converted=1
cost={W}
timing=removal
>Cancel
image=http://magiccards.info/scans/en/m12/47.jpg
value=3
@ -4320,6 +4357,16 @@ converted=2
cost={X}{R}{G}
timing=removal
>Counsel of the Soratami
image=http://magiccards.info/scans/en/10e/76.jpg
value=2
rarity=C
type=Sorcery
color=u
converted=3
cost={2}{U}
timing=draw
>Divination
image=http://magiccards.info/scans/en/m10/49.jpg
value=2
@ -6668,6 +6715,17 @@ converted=4
cost={3}{R}
timing=removal
>Creeping Mold
image=http://magiccards.info/scans/en/10e/258.jpg
value=3
removal=2
rarity=U
type=Sorcery
color=g
converted=4
cost={2}{G}{G}
timing=removal
>Into the Roil
image=http://magiccards.info/scans/en/zen/48.jpg
value=3

View File

@ -0,0 +1,48 @@
package magic.card;
import magic.model.MagicGame;
import magic.model.MagicLocationType;
import magic.model.MagicPayedCost;
import magic.model.MagicPermanent;
import magic.model.action.MagicChangeLifeAction;
import magic.model.action.MagicMoveCardAction;
import magic.model.action.MagicPermanentAction;
import magic.model.action.MagicRemoveFromPlayAction;
import magic.model.choice.MagicTargetChoice;
import magic.model.event.MagicEvent;
import magic.model.event.MagicSpellCardEvent;
import magic.model.stack.MagicCardOnStack;
import magic.model.target.MagicExileTargetPicker;
public class Condemn {
public static final MagicSpellCardEvent S = new MagicSpellCardEvent() {
@Override
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
return new MagicEvent(
cardOnStack.getCard(),
cardOnStack.getController(),
MagicTargetChoice.NEG_TARGET_ATTACKING_CREATURE,
MagicExileTargetPicker.getInstance(), // could use a better TargetPicker
new Object[]{cardOnStack},
this,
"Put target creature$ on the bottom of its owner's library. " +
"Its controller gains life equal to its toughness.");
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event,
final Object[] data,
final Object[] choiceResults) {
game.doAction(new MagicMoveCardAction((MagicCardOnStack)data[0]));
event.processTargetPermanent(game,choiceResults,0,new MagicPermanentAction() {
public void doAction(final MagicPermanent creature) {
game.doAction(new MagicChangeLifeAction(
creature.getController(),
creature.getToughness(game)));
game.doAction(new MagicRemoveFromPlayAction(creature,MagicLocationType.BottomOfOwnersLibrary));
}
});
}
};
}

View File

@ -0,0 +1,34 @@
package magic.card;
import magic.model.MagicGame;
import magic.model.MagicPayedCost;
import magic.model.MagicPlayer;
import magic.model.action.MagicDrawAction;
import magic.model.action.MagicMoveCardAction;
import magic.model.event.MagicEvent;
import magic.model.event.MagicSpellCardEvent;
import magic.model.stack.MagicCardOnStack;
public class Counsel_of_the_Soratami {
public static final MagicSpellCardEvent S = new MagicSpellCardEvent() {
@Override
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
final MagicPlayer player = cardOnStack.getController();
return new MagicEvent(
cardOnStack.getCard(),
player,
new Object[]{cardOnStack,player},
this,
"Draw two cards.");
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event,
final Object[] data,
final Object[] choiceResults) {
game.doAction(new MagicMoveCardAction((MagicCardOnStack)data[0]));
game.doAction(new MagicDrawAction((MagicPlayer)data[1],2));
}
};
}

View File

@ -0,0 +1,51 @@
package magic.card;
import magic.model.MagicAbility;
import magic.model.MagicGame;
import magic.model.MagicPayedCost;
import magic.model.MagicPermanent;
import magic.model.MagicSource;
import magic.model.action.MagicPermanentAction;
import magic.model.action.MagicSetAbilityAction;
import magic.model.choice.MagicTargetChoice;
import magic.model.condition.MagicCondition;
import magic.model.event.MagicActivationHints;
import magic.model.event.MagicEvent;
import magic.model.event.MagicPermanentActivation;
import magic.model.event.MagicTapEvent;
import magic.model.event.MagicTiming;
import magic.model.target.MagicUnblockableTargetPicker;
public class Crafty_Pathmage {
public static final MagicPermanentActivation A = new MagicPermanentActivation(
new MagicCondition[]{MagicCondition.CAN_TAP_CONDITION},
new MagicActivationHints(MagicTiming.Attack),
"Unblockable") {
@Override
public MagicEvent[] getCostEvent(final MagicSource source) {
return new MagicEvent[]{new MagicTapEvent((MagicPermanent)source)};
}
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
source.getController(),
MagicTargetChoice.TARGET_CREATURE_POWER_2_OR_LESS,
MagicUnblockableTargetPicker.getInstance(),
MagicEvent.NO_DATA,
this,
"Target creature$ with power 2 or less is unblockable this turn.");
}
@Override
public void executeEvent(final MagicGame game,final MagicEvent event,final Object[] data,final Object[] choiceResults) {
event.processTargetPermanent(game,choiceResults,0,new MagicPermanentAction() {
public void doAction(final MagicPermanent creature) {
game.doAction(new MagicSetAbilityAction(creature,MagicAbility.Unblockable));
}
});
}
};
}

View File

@ -0,0 +1,43 @@
package magic.card;
import magic.model.MagicGame;
import magic.model.MagicPayedCost;
import magic.model.MagicPermanent;
import magic.model.action.MagicDestroyAction;
import magic.model.action.MagicMoveCardAction;
import magic.model.action.MagicPermanentAction;
import magic.model.choice.MagicTargetChoice;
import magic.model.event.MagicEvent;
import magic.model.event.MagicSpellCardEvent;
import magic.model.stack.MagicCardOnStack;
import magic.model.target.MagicDestroyTargetPicker;
public class Creeping_Mold {
public static final MagicSpellCardEvent S = new MagicSpellCardEvent() {
@Override
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
return new MagicEvent(
cardOnStack.getCard(),
cardOnStack.getController(),
MagicTargetChoice.TARGET_ARTIFACT_OR_ENCHANTMENT_OR_LAND,
new MagicDestroyTargetPicker(false),
new Object[]{cardOnStack},
this,
"Destroy target artifact, enchantment or land$.");
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event,
final Object[] data,
final Object[] choiceResults) {
final MagicCardOnStack cardOnStack=(MagicCardOnStack)data[0];
game.doAction(new MagicMoveCardAction(cardOnStack));
event.processTargetPermanent(game,choiceResults,0,new MagicPermanentAction() {
public void doAction(final MagicPermanent permanent) {
game.doAction(new MagicDestroyAction(permanent));
}
});
}
};
}

View File

@ -0,0 +1,38 @@
package magic.card;
import magic.model.MagicAbility;
import magic.model.MagicGame;
import magic.model.MagicPermanent;
import magic.model.MagicPowerToughness;
import magic.model.mstatic.MagicLayer;
import magic.model.mstatic.MagicStatic;
import magic.model.target.MagicTargetFilter;
public class Elvish_Champion {
public static final MagicStatic S1 = new MagicStatic(
MagicLayer.Ability,
MagicTargetFilter.TARGET_ELF) {
@Override
public long getAbilityFlags(final MagicGame game,final MagicPermanent permanent,final long flags) {
return flags | MagicAbility.Forestwalk.getMask();
}
@Override
public boolean condition(final MagicGame game,final MagicPermanent source,final MagicPermanent target) {
return source != target;
}
};
public static final MagicStatic S2 = new MagicStatic(
MagicLayer.ModPT,
MagicTargetFilter.TARGET_ELF) {
@Override
public void getPowerToughness(final MagicGame game,final MagicPermanent permanent,final MagicPowerToughness pt) {
pt.add(1,1);
}
@Override
public boolean condition(final MagicGame game,final MagicPermanent source,final MagicPermanent target) {
return source != target;
}
};
}

View File

@ -724,6 +724,16 @@ public interface MagicTargetFilter {
}
};
MagicTargetFilter TARGET_ELF = new MagicTargetFilter() {
public boolean accept(final MagicGame game,final MagicPlayer player,final MagicTarget target) {
return ((MagicPermanent)target).isCreature(game) &&
((MagicPermanent)target).hasSubType(MagicSubType.Elf,game);
}
public boolean acceptType(final MagicTargetType targetType) {
return targetType == MagicTargetType.Permanent;
}
};
MagicTargetFilter TARGET_ELF_YOU_CONTROL = new MagicTargetFilter() {
public boolean accept(final MagicGame game,final MagicPlayer player,final MagicTarget target) {
return target.getController() == player &&