Add Shapeshifter (from Antiquities)

This commit is contained in:
jendave
2011-08-06 13:29:53 +00:00
parent 2c3ccf4ad8
commit 09f9edce07
4 changed files with 66 additions and 0 deletions

1
.gitattributes vendored
View File

@@ -4181,6 +4181,7 @@ res/cardsfolder/shambling_remains.txt -text svneol=native#text/plain
res/cardsfolder/shambling_strider.txt -text svneol=native#text/plain res/cardsfolder/shambling_strider.txt -text svneol=native#text/plain
res/cardsfolder/shanodin_dryads.txt -text svneol=native#text/plain res/cardsfolder/shanodin_dryads.txt -text svneol=native#text/plain
res/cardsfolder/shaper_guildmage.txt -text svneol=native#text/plain res/cardsfolder/shaper_guildmage.txt -text svneol=native#text/plain
res/cardsfolder/shapeshifter.txt -text svneol=native#text/plain
res/cardsfolder/shard_volley.txt -text svneol=native#text/plain res/cardsfolder/shard_volley.txt -text svneol=native#text/plain
res/cardsfolder/shared_triumph.txt -text svneol=native#text/plain res/cardsfolder/shared_triumph.txt -text svneol=native#text/plain
res/cardsfolder/sharuum_the_hegemon.txt -text svneol=native#text/plain res/cardsfolder/sharuum_the_hegemon.txt -text svneol=native#text/plain

View File

@@ -0,0 +1,8 @@
Name:Shapeshifter
ManaCost:6
Types:Artifact Creature Shapeshifter
Text:As Shapeshifter enters the battlefield, choose a number between 0 and 7.\r\nAt the beginning of your upkeep, you may choose a number between 0 and 7.\r\nShapeshifter's power is equal to the last chosen number and its toughness is equal to 7 minus that number.
PT:*/7-*
SVar:Rarity:Uncommon
SVar:Picture:http://www.wizards.com/global/images/magic/general/shapeshifter.jpg
End

View File

@@ -16446,6 +16446,33 @@ public class CardFactory_Creatures {
card.addSpellAbility(ability); card.addSpellAbility(ability);
}//*************** END ************ END ************************** }//*************** END ************ END **************************
//*************** START *********** START **************************
else if(cardName.equals("Shapeshifter")) {
Command intoPlay = new Command() {
private static final long serialVersionUID = 5447692676152380940L;
public void execute() {
int num = 0;
if(card.getController().isHuman()) {
String[] choices = new String[7];
for(int j = 0; j < 7; j++) {
choices[j] = ""+j;
}
String answer = (String)(AllZone.Display.getChoiceOptional(
card.getName()+" - Choose a number", choices));
num = Integer.parseInt(answer);
}
else {
num = 3;
}
card.setBaseAttack(num);
card.setBaseDefense(7-num);
}
};
card.addComesIntoPlayCommand(intoPlay);
}//*************** END ************ END **************************
if(hasKeyword(card, "Level up") != -1 && hasKeyword(card, "maxLevel") != -1) if(hasKeyword(card, "Level up") != -1 && hasKeyword(card, "maxLevel") != -1)
{ {

View File

@@ -71,6 +71,7 @@ public class GameActionUtil {
upkeep_Nath(); upkeep_Nath();
upkeep_Anowon(); upkeep_Anowon();
upkeep_Cunning_Lethemancer(); upkeep_Cunning_Lethemancer();
upkeep_Shapeshifter();
upkeep_Ink_Dissolver(); upkeep_Ink_Dissolver();
upkeep_Kithkin_Zephyrnaut(); upkeep_Kithkin_Zephyrnaut();
@@ -10037,6 +10038,35 @@ public class GameActionUtil {
} }
}//list > 0 }//list > 0
}//cursed land }//cursed land
private static void upkeep_Shapeshifter() {
final Player player = AllZone.Phase.getPlayerTurn();
CardList list = AllZoneUtil.getPlayerCardsInPlay(player, "Shapeshifter");
for(final Card c:list) {
SpellAbility ability = new Ability(c, "0") {
@Override
public void resolve() {
int num = 0;
if(player.isHuman()) {
String[] choices = new String[7];
for(int j = 0; j < 7; j++) {
choices[j] = ""+j;
}
String answer = (String)(AllZone.Display.getChoiceOptional(c.getName()+" - Choose a number", choices));
num = Integer.parseInt(answer);
}
else {
num = 3;
}
c.setBaseAttack(num);
c.setBaseDefense(7-num);
}
};
ability.setStackDescription(c.getName()+" - choose a new number");
AllZone.Stack.add(ability);
}//foreach(Card)
}//upkeep_Shapeshifter
private static void upkeep_Pillory_of_the_Sleepless() { private static void upkeep_Pillory_of_the_Sleepless() {
final Player player = AllZone.Phase.getPlayerTurn(); final Player player = AllZone.Phase.getPlayerTurn();