convert from java code to groovy code

master
melvin 2013-03-13 22:14:31 +08:00
parent d9a24d183c
commit dcaccab0e2
2 changed files with 7 additions and 17 deletions

View File

@ -1,28 +1,18 @@
package magic.card; [
new MagicStatic(MagicLayer.ModPT) {
import magic.model.MagicAbility;
import magic.model.MagicPermanent;
import magic.model.MagicPowerToughness;
import magic.model.mstatic.MagicLayer;
import magic.model.mstatic.MagicStatic;
import java.util.Set;
public class Guul_Draz_Vampire {
public static final MagicStatic S1 = new MagicStatic(MagicLayer.ModPT) {
@Override @Override
public void modPowerToughness(final MagicPermanent source,final MagicPermanent permanent,final MagicPowerToughness pt) { public void modPowerToughness(final MagicPermanent source,final MagicPermanent permanent,final MagicPowerToughness pt) {
if (permanent.getOpponent().getLife() <= 10) { if (permanent.getOpponent().getLife() <= 10) {
pt.add(2,1); pt.add(2,1);
} }
} }
}; },
public static final MagicStatic S2 = new MagicStatic(MagicLayer.Ability) { new MagicStatic(MagicLayer.Ability) {
@Override @Override
public void modAbilityFlags(final MagicPermanent source,final MagicPermanent permanent,final Set<MagicAbility> flags) { public void modAbilityFlags(final MagicPermanent source,final MagicPermanent permanent,final Set<MagicAbility> flags) {
if (permanent.getOpponent().getLife() <= 10) { if (permanent.getOpponent().getLife() <= 10) {
flags.add(MagicAbility.Intimidate); flags.add(MagicAbility.Intimidate);
} }
} }
}; }
} ]

View File

@ -8,4 +8,4 @@ subtype=Vampire,Rogue
cost={B} cost={B}
pt=1/1 pt=1/1
timing=main timing=main
requires_card_code requires_groovy_code