Minor framework fixes.

This commit is contained in:
LevelX2 2014-01-22 23:59:33 +01:00
parent 83e1290fb7
commit 199af48a43
2 changed files with 4 additions and 1 deletions

View file

@ -62,6 +62,7 @@ public abstract class RestrictionEffect<T extends RestrictionEffect<T>> extends
public RestrictionEffect(final RestrictionEffect effect) { public RestrictionEffect(final RestrictionEffect effect) {
super(effect); super(effect);
this.notMoreThanRestriction = effect.notMoreThanRestriction; this.notMoreThanRestriction = effect.notMoreThanRestriction;
this.notMoreThanNumber = effect.notMoreThanNumber;
if (this.notMoreThanNumberFilter != null) { if (this.notMoreThanNumberFilter != null) {
this.notMoreThanNumberFilter = effect.notMoreThanNumberFilter.copy(); this.notMoreThanNumberFilter = effect.notMoreThanNumberFilter.copy();
} }

View file

@ -39,6 +39,7 @@ import mage.game.permanent.Permanent;
import mage.players.Player; import mage.players.Player;
import mage.target.Target; import mage.target.Target;
import mage.target.common.TargetOpponent; import mage.target.common.TargetOpponent;
import mage.util.CardUtil;
/** /**
* *
@ -114,7 +115,8 @@ class TributeEffect extends OneShotEffect<TributeEffect> {
if (opponent != null) { if (opponent != null) {
StringBuilder sb = new StringBuilder("Pay tribute to "); StringBuilder sb = new StringBuilder("Pay tribute to ");
sb.append(sourcePermanent.getName()); sb.append(sourcePermanent.getName());
sb.append(" (add ").append(tributeValue).append(" +1/+1 counters to it)?"); sb.append(" (add ").append(CardUtil.numberToText(tributeValue)).append(" +1/+1 counter");
sb.append(tributeValue > 1 ? "s":"").append("to it)?");
if (opponent.chooseUse(outcome, sb.toString(), game)) { if (opponent.chooseUse(outcome, sb.toString(), game)) {
sourcePermanent.addCounters(CounterType.P1P1.createInstance(tributeValue), game); sourcePermanent.addCounters(CounterType.P1P1.createInstance(tributeValue), game);
game.getState().setValue(new StringBuilder("tributeValue").append(source.getSourceId()).toString(), "yes"); game.getState().setValue(new StringBuilder("tributeValue").append(source.getSourceId()).toString(), "yes");