- Conversion to StringBuilder. This finishes CardFactoryUtil.java.

This commit is contained in:
jendave
2011-08-06 09:56:56 +00:00
parent 158954944b
commit 67b014070a

View File

@@ -1768,7 +1768,10 @@ public class CardFactoryUtil {
equip.setBeforePayMana(runtime); equip.setBeforePayMana(runtime);
equip.setDescription("Equip: " + Manacost); StringBuilder sbDesc = new StringBuilder();
sbDesc.append("Equip: ").append(Manacost);
equip.setDescription(sbDesc.toString());
return equip; return equip;
}//eqPump_Equip() ( was vanila_equip() ) }//eqPump_Equip() ( was vanila_equip() )
@@ -2020,7 +2023,10 @@ public class CardFactoryUtil {
"Creature", "Spirit"}, 1, 1, new String[] {""}); "Creature", "Spirit"}, 1, 1, new String[] {""});
} }
}; };
ability.setStackDescription(card + " - put a 1/1 colorless Spirit creature token onto the battlefield under target opponent's control."); StringBuilder sb = new StringBuilder();
sb.append(card);
sb.append(" - put a 1/1 colorless Spirit creature token onto the battlefield under target opponent's control.");
ability.setStackDescription(sb.toString());
return ability; return ability;
} }
@@ -2251,11 +2257,16 @@ public class CardFactoryUtil {
} }
} }
}; };
desc.setDescription("Soulshift " StringBuilder sbDesc = new StringBuilder();
+ Manacost sbDesc.append("Soulshift ").append(Manacost);
+ " - When this permanent is put into a graveyard from play, you may return target Spirit card with converted mana cost " sbDesc.append(" - When this permanent is put into a graveyard from play, you may return target Spirit card with converted mana cost ");
+ Manacost + " or less from your graveyard to your hand."); sbDesc.append(Manacost).append(" or less from your graveyard to your hand.");
desc.setStackDescription(sourceCard.getName() + " - Soulshift " + Manacost); desc.setDescription(sbDesc.toString());
StringBuilder sbStack = new StringBuilder();
sbStack.append(sourceCard.getName()).append(" - Soulshift ").append(Manacost);
desc.setStackDescription(sbStack.toString());
return desc; return desc;
}//soul_desc() }//soul_desc()
@@ -4529,7 +4540,10 @@ public class CardFactoryUtil {
player.drawCard(); player.drawCard();
} }
}; };
ability.setStackDescription("Horn of Greed - " + player + " draws a card."); StringBuilder sb = new StringBuilder();
sb.append("Horn of Greed - ").append(player).append(" draws a card.");
ability.setStackDescription(sb.toString());
AllZone.Stack.add(ability); AllZone.Stack.add(ability);
} }
} }
@@ -4581,7 +4595,10 @@ public class CardFactoryUtil {
AllZone.GameAction.moveToHand(c); AllZone.GameAction.moveToHand(c);
} }
}; };
ability.setStackDescription(c + " - return CARDNAME to its owner's hand."); StringBuilder sb = new StringBuilder();
sb.append(c).append(" - return CARDNAME to its owner's hand.");
ability.setStackDescription(sb.toString());
AllZone.Stack.add(ability); AllZone.Stack.add(ability);
} }
if (c.getKeyword().contains("When CARDNAME becomes the target of a spell or ability, destroy CARDNAME.") if (c.getKeyword().contains("When CARDNAME becomes the target of a spell or ability, destroy CARDNAME.")
@@ -4594,7 +4611,10 @@ public class CardFactoryUtil {
AllZone.GameAction.destroy(c); AllZone.GameAction.destroy(c);
} }
}; };
ability.setStackDescription(c + " - destroy CARDNAME."); StringBuilder sb = new StringBuilder();
sb.append(c).append(" - destroy CARDNAME.");
ability.setStackDescription(sb.toString());
AllZone.Stack.add(ability); AllZone.Stack.add(ability);
} }
if (c.getKeyword().contains("When CARDNAME becomes the target of a spell or ability, sacrifice it.")) { if (c.getKeyword().contains("When CARDNAME becomes the target of a spell or ability, sacrifice it.")) {
@@ -4605,7 +4625,10 @@ public class CardFactoryUtil {
AllZone.GameAction.sacrifice(c); AllZone.GameAction.sacrifice(c);
} }
}; };
ability.setStackDescription(c + " - sacrifice CARDNAME."); StringBuilder sb = new StringBuilder();
sb.append(c).append(" - sacrifice CARDNAME.");
ability.setStackDescription(sb.toString());
AllZone.Stack.add(ability); AllZone.Stack.add(ability);
} }
//} //}