- Updated the code for Creakwood Liege, it now creates a token named "bg_1_1_worm.jpg".

This commit is contained in:
jendave
2011-08-06 13:02:58 +00:00
parent 74063f5895
commit fae09458d3

View File

@@ -11305,25 +11305,21 @@ public class GameActionUtil {
list = list.getName("Creakwood Liege"); list = list.getName("Creakwood Liege");
Ability ability; Ability ability;
for(int i = 0; i < list.size(); i++) { for (int i = 0; i < list.size(); i++) {
final Card crd = list.get(i); final Card crd = list.get(i);
ability = new Ability(list.get(i), "0") { ability = new Ability(list.get(i), "0") {
@Override @Override
public void resolve() { public void resolve() {
String[] choices = {"Yes", "No"};
Object q = null; if (player.equals(AllZone.HumanPlayer)) {
if(player.equals(AllZone.HumanPlayer)) { String question = "Put a 1/1 black and green Worm creature token onto the battlefield?";
q = AllZone.Display.getChoiceOptional("Use Creakwood Liege?", choices); if (showYesNoDialog(crd, question)) {
CardFactoryUtil.makeToken("Worm", "BG 1 1 Worm", crd.getController(), "BG",
if(q == null || q.equals("No")) return; new String[] {"Creature", "Worm"}, 1, 1, new String[] {""});
if(q.equals("Yes")) {
CardFactoryUtil.makeToken("Worm", "B G 1 1 Worm", crd.getController(), "B G", new String[] {
"Creature", "Worm"}, 1, 1, new String[] {""});
} }
} else if(player.equals(AllZone.ComputerPlayer)) { } else {
CardFactoryUtil.makeToken("Worm", "B G 1 1 Worm", crd.getController(), "B G", new String[] { CardFactoryUtil.makeToken("Worm", "BG 1 1 Worm", crd.getController(), "BG",
"Creature", "Worm"}, 1, 1, new String[] {""}); new String[] {"Creature", "Worm"}, 1, 1, new String[] {""});
} }
}// resolve() }// resolve()
};// Ability };// Ability