Fixed optional costs. Now new implemenation of kicker should work.

This commit is contained in:
magenoxx 2011-09-14 00:35:44 +04:00
parent a07c210ac0
commit cc415c586d
2 changed files with 72 additions and 47 deletions

View file

@ -164,12 +164,12 @@ public abstract class AbilityImpl<T extends AbilityImpl<T>> implements Ability {
logger.debug("activate failed - target");
return false;
}
ArrayList<Cost> addedOptionalCosts = new ArrayList<Cost>();
for (Cost cost : optionalCosts) {
if (game.getPlayer(this.controllerId).chooseUse(Outcome.Benefit, "Pay optional cost " + cost.getText() + "?", game)) {
if (cost instanceof ManaCost) {
if (cost instanceof ManaCost) {
cost.clearPaid();
if (game.getPlayer(this.controllerId).chooseUse(Outcome.Benefit, "Pay optional cost " + cost.getText() + "?", game)) {
manaCostsToPay.add((ManaCost) cost);
addedOptionalCosts.add(cost);
}
}
}