[C14] 11 white cards + 1 Artifact + white deck list + some minor fixes to framework and other cards.

This commit is contained in:
LevelX2 2014-12-01 16:59:36 +01:00
parent 6514e30b59
commit 2af52cfd3a
28 changed files with 1492 additions and 22 deletions

View file

@ -29,6 +29,7 @@
package mage.abilities.decorator;
import mage.abilities.Ability;
import mage.abilities.Mode;
import mage.abilities.condition.Condition;
import mage.abilities.effects.OneShotEffect;
import mage.game.Game;
@ -44,6 +45,10 @@ public class ConditionalOneShotEffect extends OneShotEffect {
private OneShotEffect otherwiseEffect;
private Condition condition;
public ConditionalOneShotEffect(OneShotEffect effect, Condition condition) {
this(effect, null, condition, null);
}
public ConditionalOneShotEffect(OneShotEffect effect, Condition condition, String text) {
this(effect, null, condition, text);
}
@ -82,4 +87,15 @@ public class ConditionalOneShotEffect extends OneShotEffect {
return new ConditionalOneShotEffect(this);
}
@Override
public String getText(Mode mode) {
if (staticText != null && !staticText.isEmpty()) {
return staticText;
}
if (otherwiseEffect == null) {
return "If " + condition.toString() + ", " + effect.getText(mode);
}
return effect.getText(mode) + ". If " + condition.toString() + ", " + otherwiseEffect.getText(mode);
}
}

View file

@ -64,12 +64,7 @@ public class CreateTokenTargetEffect extends OneShotEffect {
if (value < 1) {
return true;
}
if(token.putOntoBattlefield(value, game, source.getSourceId(), targetPointer.getFirst(game, source), tapped, attacking)) {
game.informPlayers(new StringBuilder(controller.getName())
.append(" puts ").append(CardUtil.numberToText(value,"a")).append(" ").append(token.getName())
.append(value == 1?" token":" tokens").append(" onto the Battlefield").toString());
return true;
}
return token.putOntoBattlefield(value, game, source.getSourceId(), targetPointer.getFirst(game, source), tapped, attacking);
}
return false;
}

View file

@ -10,9 +10,9 @@ public class AngelToken extends Token {
this("M14");
}
public AngelToken(String tokenImageSetCode) {
public AngelToken(String setCode) {
super("Angel", "4/4 white Angel creature token with flying");
this.setOriginalExpansionSetCode(tokenImageSetCode);
this.setOriginalExpansionSetCode(setCode);
cardType.add(CardType.CREATURE);
color.setWhite(true);