added Nantuko Monastery and Treetop Village

master
beholder 2011-10-24 08:23:12 +02:00
parent 025811dd52
commit cb72e3be59
5 changed files with 216 additions and 1 deletions

View File

@ -16841,3 +16841,22 @@ type=Land
mana=r3 mana=r3
timing=land timing=land
mana_or_combat mana_or_combat
>Nantuko Monastery
url=http://magiccards.info/arc/en/131.html
image=http://magiccards.info/scans/en/arc/131.jpg
value=4
rarity=U
type=Land
timing=land
mana_or_combat
>Treetop Village
url=http://magiccards.info/10e/en/361.html
image=http://magiccards.info/scans/en/10e/361.jpg
value=4
rarity=U
type=Land
mana=g3
timing=land
mana_or_combat

View File

@ -62,7 +62,7 @@ public class Dread_Statuary {
new Object[]{source}, new Object[]{source},
this, this,
"Until end of turn, " + source + "Until end of turn, " + source +
" becomes a 4/2 Golem artifact creature until end of turn. " + " becomes a 4/2 Golem artifact creature. " +
"It's still a land."); "It's still a land.");
} }
@Override @Override

View File

@ -0,0 +1,96 @@
package magic.card;
import magic.model.MagicAbility;
import magic.model.MagicColor;
import magic.model.MagicGame;
import magic.model.MagicManaCost;
import magic.model.MagicManaType;
import magic.model.MagicPayedCost;
import magic.model.MagicPermanent;
import magic.model.MagicPowerToughness;
import magic.model.MagicSource;
import magic.model.MagicSubType;
import magic.model.MagicType;
import magic.model.action.MagicBecomesCreatureAction;
import magic.model.condition.MagicCondition;
import magic.model.event.MagicActivationHints;
import magic.model.event.MagicEvent;
import magic.model.event.MagicManaActivation;
import magic.model.event.MagicPayManaCostEvent;
import magic.model.event.MagicPermanentActivation;
import magic.model.event.MagicTapManaActivation;
import magic.model.event.MagicTiming;
import magic.model.mstatic.MagicStatic;
import magic.model.mstatic.MagicLayer;
import java.util.Arrays;
import java.util.EnumSet;
public class Nantuko_Monastery {
private static final MagicStatic PT = new MagicStatic(MagicLayer.SetPT, MagicStatic.UntilEOT) {
@Override
public void getPowerToughness(final MagicGame game,final MagicPermanent permanent,final MagicPowerToughness pt) {
pt.set(4,4);
}
};
private static final MagicStatic AB = new MagicStatic(MagicLayer.Ability, MagicStatic.UntilEOT) {
@Override
public long getAbilityFlags(final MagicGame game,final MagicPermanent permanent,final long flags) {
return flags|MagicAbility.FirstStrike.getMask();
}
};
private static final MagicStatic ST = new MagicStatic(MagicLayer.Type, MagicStatic.UntilEOT) {
@Override
public EnumSet<MagicSubType> getSubTypeFlags(final MagicPermanent permanent,final EnumSet<MagicSubType> flags) {
final EnumSet<MagicSubType> mod = flags.clone();
mod.add(MagicSubType.Insect);
mod.add(MagicSubType.Monk);
return mod;
}
@Override
public int getTypeFlags(final MagicPermanent permanent,final int flags) {
return flags | MagicType.Creature.getMask();
}
};
private static final MagicStatic C = new MagicStatic(MagicLayer.Color, MagicStatic.UntilEOT) {
@Override
public int getColorFlags(final MagicPermanent permanent,final int flags) {
return MagicColor.Green.getMask() | MagicColor.White.getMask();
}
};
public static final MagicPermanentActivation A = new MagicPermanentActivation(
new MagicCondition[]{
MagicCondition.THRESHOLD_CONDITION,
MagicManaCost.GREEN_WHITE.getCondition(),
},
new MagicActivationHints(MagicTiming.Animate),
"Animate") {
@Override
public MagicEvent[] getCostEvent(final MagicSource source) {
return new MagicEvent[]{new MagicPayManaCostEvent(source,source.getController(),MagicManaCost.GREEN_WHITE)};
}
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
source.getController(),
new Object[]{source},
this,
"Until end of turn, " + source +
" becomes a 4/4 green and white Insect Monk creature with first strike. " +
"It's still a land.");
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event,
final Object[] data,
final Object[] choiceResults) {
game.doAction(new MagicBecomesCreatureAction((MagicPermanent)data[0],PT,AB,ST,C));
}
};
public static final MagicManaActivation M = new MagicTapManaActivation(
Arrays.asList(MagicManaType.Colorless),0);
}

View File

@ -0,0 +1,99 @@
package magic.card;
import magic.model.MagicAbility;
import magic.model.MagicColor;
import magic.model.MagicGame;
import magic.model.MagicManaCost;
import magic.model.MagicManaType;
import magic.model.MagicPayedCost;
import magic.model.MagicPermanent;
import magic.model.MagicPowerToughness;
import magic.model.MagicSource;
import magic.model.MagicSubType;
import magic.model.MagicType;
import magic.model.action.MagicBecomesCreatureAction;
import magic.model.condition.MagicArtificialCondition;
import magic.model.condition.MagicCondition;
import magic.model.event.MagicActivationHints;
import magic.model.event.MagicEvent;
import magic.model.event.MagicManaActivation;
import magic.model.event.MagicPayManaCostEvent;
import magic.model.event.MagicPermanentActivation;
import magic.model.event.MagicTapManaActivation;
import magic.model.event.MagicTiming;
import magic.model.trigger.MagicTappedIntoPlayTrigger;
import magic.model.trigger.MagicTrigger;
import magic.model.mstatic.MagicStatic;
import magic.model.mstatic.MagicLayer;
import java.util.Arrays;
import java.util.EnumSet;
public class Treetop_Village {
private static final MagicStatic PT = new MagicStatic(MagicLayer.SetPT, MagicStatic.UntilEOT) {
@Override
public void getPowerToughness(final MagicGame game,final MagicPermanent permanent,final MagicPowerToughness pt) {
pt.set(3,3);
}
};
private static final MagicStatic AB = new MagicStatic(MagicLayer.Ability, MagicStatic.UntilEOT) {
@Override
public long getAbilityFlags(final MagicGame game,final MagicPermanent permanent,final long flags) {
return flags|MagicAbility.Trample.getMask();
}
};
private static final MagicStatic ST = new MagicStatic(MagicLayer.Type, MagicStatic.UntilEOT) {
@Override
public EnumSet<MagicSubType> getSubTypeFlags(final MagicPermanent permanent,final EnumSet<MagicSubType> flags) {
final EnumSet<MagicSubType> mod = flags.clone();
mod.add(MagicSubType.Ape);
return mod;
}
@Override
public int getTypeFlags(final MagicPermanent permanent,final int flags) {
return flags|MagicType.Creature.getMask();
}
};
private static final MagicStatic C = new MagicStatic(MagicLayer.Color, MagicStatic.UntilEOT) {
@Override
public int getColorFlags(final MagicPermanent permanent,final int flags) {
return MagicColor.Green.getMask();
}
};
public static final MagicPermanentActivation A = new MagicPermanentActivation(
new MagicCondition[]{new MagicArtificialCondition(
MagicManaCost.ONE_GREEN.getCondition(),
MagicManaCost.GREEN_GREEN.getCondition())},
new MagicActivationHints(MagicTiming.Animate),
"Animate") {
@Override
public MagicEvent[] getCostEvent(final MagicSource source) {
return new MagicEvent[]{new MagicPayManaCostEvent(source,source.getController(),MagicManaCost.ONE_GREEN)};
}
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
source.getController(),
new Object[]{source},
this,
"Until end of turn, " + source +
" becomes a 3/3 green Ape creature with trample. " +
"It's still a land.");
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event,
final Object[] data,
final Object[] choiceResults) {
game.doAction(new MagicBecomesCreatureAction((MagicPermanent)data[0],PT,AB,ST,C));
}
};
public static final MagicTrigger T = new MagicTappedIntoPlayTrigger();
public static final MagicManaActivation M = new MagicTapManaActivation(
Arrays.asList(MagicManaType.Green),1);
}

View File

@ -60,6 +60,7 @@ public class MagicManaCost {
public static final MagicManaCost THREE_GREEN=MagicManaCost.createCost("{3}{G}"); public static final MagicManaCost THREE_GREEN=MagicManaCost.createCost("{3}{G}");
public static final MagicManaCost TWO_GREEN_GREEN=MagicManaCost.createCost("{2}{G}{G}"); public static final MagicManaCost TWO_GREEN_GREEN=MagicManaCost.createCost("{2}{G}{G}");
public static final MagicManaCost TWO_GREEN_GREEN_GREEN=MagicManaCost.createCost("{2}{G}{G}{G}"); public static final MagicManaCost TWO_GREEN_GREEN_GREEN=MagicManaCost.createCost("{2}{G}{G}{G}");
public static final MagicManaCost GREEN_GREEN=MagicManaCost.createCost("{G}{G}");
public static final MagicManaCost X_RED=MagicManaCost.createCost("{X}{R}"); public static final MagicManaCost X_RED=MagicManaCost.createCost("{X}{R}");
public static final MagicManaCost ONE_RED=MagicManaCost.createCost("{1}{R}"); public static final MagicManaCost ONE_RED=MagicManaCost.createCost("{1}{R}");
public static final MagicManaCost TWO_RED=MagicManaCost.createCost("{2}{R}"); public static final MagicManaCost TWO_RED=MagicManaCost.createCost("{2}{R}");