- Added Dream Halls.

This commit is contained in:
Sloth
2012-08-27 21:04:46 +00:00
parent fdaca93066
commit 49b79ec4ae
5 changed files with 38 additions and 1 deletions

View File

@@ -2264,6 +2264,8 @@ public class Card extends GameEntity implements Comparable<Card> {
final String costDesc = upkeepCostParams.length > 2 ? "- " + upkeepCostParams[2] : cost;
sbLong.append(costDesc);
sbLong.append("\r\n");
} else if (keyword.get(i).startsWith("Alternative Cost")) {
sbLong.append("Has alternative cost.");
} else if (keyword.get(i).startsWith("Champion")) {
final String k = this.getKeyword().get(i);
final String[] kk = k.split(":");

View File

@@ -1909,7 +1909,7 @@ public final class GameActionUtil {
newSA.setBasicSpell(false);
newSA.setPayCosts(cost);
newSA.setManaCost("");
newSA.setDescription(sa.getDescription() + " (by paying " + keyword.substring(17) + " instead of its mana cost)");
newSA.setDescription(sa.getDescription() + " (by paying " + cost.toSimpleString() + " instead of its mana cost)");
alternatives.add(newSA);
}
}

View File

@@ -476,6 +476,29 @@ public class Cost {
return this.spellToString(false);
}
/**
* <p>
* toSimpleString.
* </p>
*
* @return a {@link java.lang.String} object.
*/
public final String toSimpleString() {
final StringBuilder cost = new StringBuilder();
boolean first = true;
for (final CostPart part : this.costParts) {
if (part instanceof CostMana) {
continue;
}
if (!first) {
cost.append(" and ");
}
cost.append(part.toString());
first = false;
}
return cost.toString();
}
/**
* <p>
* spellToString.