From dbc1ceada3c39f70f2cbe120e35210fea04a59ec Mon Sep 17 00:00:00 2001 From: jendave Date: Sat, 6 Aug 2011 04:11:05 +0000 Subject: [PATCH] fix indentation for Hurkyl's Recall --- src/forge/CardFactory.java | 110 ++++++++++++++++++------------------- 1 file changed, 54 insertions(+), 56 deletions(-) diff --git a/src/forge/CardFactory.java b/src/forge/CardFactory.java index 0a57e195353..34eed4fa235 100644 --- a/src/forge/CardFactory.java +++ b/src/forge/CardFactory.java @@ -17795,62 +17795,60 @@ public class CardFactory implements NewConstants { //*************** START *********** START ************************** else if(cardName.equals("Hurkyl's Recall")) { - /* - * Return all artifacts target player owns to his or her hand. - */ - SpellAbility spell = new Spell(card) { - private static final long serialVersionUID = -4098702062413878046L; - - @Override - public boolean canPlayAI() { - PlayerZone humanPlay = AllZone.getZone(Constant.Zone.Play, Constant.Player.Human); - CardList humanArts = new CardList(humanPlay.getCards()); - humanArts = humanArts.getType("Artifact"); - if(humanArts.size() > 0) { - return true; - } - else { - return false; - } - }//canPlayAI - - @Override - public void chooseTargetAI() { - setTargetPlayer(Constant.Player.Human); - }//chooseTargetAI() - - @Override - public void resolve() { - String player = getTargetPlayer(); - PlayerZone play = AllZone.getZone(Constant.Zone.Play, player); - PlayerZone hand = AllZone.getZone(Constant.Zone.Hand, player); - final String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone oppPlay = AllZone.getZone(Constant.Zone.Play, opponent); - CardList artifacts = new CardList(play.getCards()); - artifacts.addAll(oppPlay.getCards()); - artifacts = artifacts.getType("Artifact"); - - for(int i = 0; i < artifacts.size(); i++) { - Card thisArtifact = artifacts.get(i); - //if is token, remove token from play, else return artifact to hand - if(thisArtifact.getOwner().equals(player)) { - if(thisArtifact.isToken()) { - play.remove(thisArtifact); - } - else { - AllZone.GameAction.moveTo(hand, thisArtifact); - } - } - } - }//resolve() - }; - card.clearSpellAbility(); - card.addSpellAbility(spell); - spell.setBeforePayMana(CardFactoryUtil.input_targetPlayer(spell)); - }//*************** END ************ END ************************** - - - + /* + * Return all artifacts target player owns to his or her hand. + */ + SpellAbility spell = new Spell(card) { + private static final long serialVersionUID = -4098702062413878046L; + + @Override + public boolean canPlayAI() { + PlayerZone humanPlay = AllZone.getZone(Constant.Zone.Play, Constant.Player.Human); + CardList humanArts = new CardList(humanPlay.getCards()); + humanArts = humanArts.getType("Artifact"); + if(humanArts.size() > 0) { + return true; + } + else { + return false; + } + }//canPlayAI + + @Override + public void chooseTargetAI() { + setTargetPlayer(Constant.Player.Human); + }//chooseTargetAI() + + @Override + public void resolve() { + String player = getTargetPlayer(); + PlayerZone play = AllZone.getZone(Constant.Zone.Play, player); + PlayerZone hand = AllZone.getZone(Constant.Zone.Hand, player); + final String opponent = AllZone.GameAction.getOpponent(player); + PlayerZone oppPlay = AllZone.getZone(Constant.Zone.Play, opponent); + CardList artifacts = new CardList(play.getCards()); + artifacts.addAll(oppPlay.getCards()); + artifacts = artifacts.getType("Artifact"); + + for(int i = 0; i < artifacts.size(); i++) { + Card thisArtifact = artifacts.get(i); + //if is token, remove token from play, else return artifact to hand + if(thisArtifact.getOwner().equals(player)) { + if(thisArtifact.isToken()) { + play.remove(thisArtifact); + } + else { + AllZone.GameAction.moveTo(hand, thisArtifact); + } + } + } + }//resolve() + }; + card.clearSpellAbility(); + card.addSpellAbility(spell); + spell.setBeforePayMana(CardFactoryUtil.input_targetPlayer(spell)); + }//*************** END ************ END ************************** + //*************** START *********** START ************************** else if(cardName.equals("Fracturing Gust")) { /*