[BRO] Implement Steel Exemplar

This commit is contained in:
Evan Kranzler 2022-11-06 09:11:50 -05:00
parent 4586527fb2
commit e65867eea3
2 changed files with 60 additions and 0 deletions

View file

@ -0,0 +1,59 @@
package mage.cards.s;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldAbility;
import mage.abilities.condition.Condition;
import mage.abilities.dynamicvalue.common.ColorsOfManaSpentToCastCount;
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
import mage.abilities.keyword.TrampleAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.SubType;
import mage.counters.CounterType;
import mage.game.Game;
import java.util.UUID;
/**
* @author TheElk801
*/
public final class SteelExemplar extends CardImpl {
public SteelExemplar(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{5}");
this.subtype.add(SubType.WIZARD);
this.power = new MageInt(4);
this.toughness = new MageInt(4);
// Trample
this.addAbility(TrampleAbility.getInstance());
// Steel Exemplar enters the battlefield with two +1/+1 counters on it unless two or more colors of mana were spent to cast it.
this.addAbility(new EntersBattlefieldAbility(
new AddCountersSourceEffect(CounterType.P1P1.createInstance(2)),
SteelExemplarCondition.instance, "{this} enters the battlefield with " +
"two +1/+1 counters on it unless two or more colors of mana were spent to cast it.", ""
));
}
private SteelExemplar(final SteelExemplar card) {
super(card);
}
@Override
public SteelExemplar copy() {
return new SteelExemplar(this);
}
}
enum SteelExemplarCondition implements Condition {
instance;
@Override
public boolean apply(Game game, Ability source) {
return ColorsOfManaSpentToCastCount.getInstance().calculate(game, source, null) < 2;
}
}

View file

@ -214,6 +214,7 @@ public final class TheBrothersWar extends ExpansionSet {
cards.add(new SetCardInfo("Splitting the Powerstone", 63, Rarity.UNCOMMON, mage.cards.s.SplittingThePowerstone.class));
cards.add(new SetCardInfo("Spotter Thopter", 80, Rarity.UNCOMMON, mage.cards.s.SpotterThopter.class));
cards.add(new SetCardInfo("Static Net", 27, Rarity.UNCOMMON, mage.cards.s.StaticNet.class));
cards.add(new SetCardInfo("Steel Exemplar", 246, Rarity.UNCOMMON, mage.cards.s.SteelExemplar.class));
cards.add(new SetCardInfo("Stern Lesson", 64, Rarity.COMMON, mage.cards.s.SternLesson.class));
cards.add(new SetCardInfo("Stone Retrieval Unit", 248, Rarity.COMMON, mage.cards.s.StoneRetrievalUnit.class));
cards.add(new SetCardInfo("Su-Chi Cave Guard", 249, Rarity.UNCOMMON, mage.cards.s.SuChiCaveGuard.class));