* Some minor fixed to tooltip texts.

This commit is contained in:
LevelX2 2015-05-06 15:58:18 +02:00
parent 5dbd5401fa
commit bc990ad24a
4 changed files with 17 additions and 12 deletions

View file

@ -47,7 +47,11 @@ public class DoIfCostPaid extends OneShotEffect {
if (player != null && mageObject != null) {
String message;
if (chooseUseText == null) {
message = new StringBuilder(getCostText()).append(" and ").append(executingEffects.getText(source.getModes().getMode())).append("?").toString();
String effectText = executingEffects.getText(source.getModes().getMode());
if (effectText.length() > 0 && effectText.charAt(effectText.length()-1)=='.') {
effectText = effectText.substring(0, effectText.length()-1);
}
message = getCostText() +" and " + effectText + "?";
} else {
message = chooseUseText;
}
@ -82,13 +86,14 @@ public class DoIfCostPaid extends OneShotEffect {
if (!staticText.isEmpty()) {
return staticText;
}
return new StringBuilder("you may ").append(getCostText()).append(". If you do, ").append(executingEffects.getText(mode)).toString();
return "you may " + getCostText() + ". If you do, " + executingEffects.getText(mode);
}
protected String getCostText() {
StringBuilder sb = new StringBuilder();
String costText = cost.getText();
if (costText != null
&& !costText.toLowerCase().startsWith("exile")
&& !costText.toLowerCase().startsWith("discard")
&& !costText.toLowerCase().startsWith("sacrifice")
&& !costText.toLowerCase().startsWith("remove")

View file

@ -96,7 +96,7 @@ public class ReturnSourceFromGraveyardToBattlefieldEffect extends OneShotEffect
}
private void setText() {
StringBuilder sb = new StringBuilder("Return {this} from your graveyard to the battlefield");
StringBuilder sb = new StringBuilder("return {this} from your graveyard to the battlefield");
if (tapped) {
sb.append(" tapped");
}