mirror of
https://github.com/correl/mage.git
synced 2024-12-25 11:11:16 +00:00
[CMR] Implemented Armix, Filigree Thrasher
This commit is contained in:
parent
37617cec9f
commit
f1b5d3ba4d
2 changed files with 93 additions and 0 deletions
92
Mage.Sets/src/mage/cards/a/ArmixFiligreeThrasher.java
Normal file
92
Mage.Sets/src/mage/cards/a/ArmixFiligreeThrasher.java
Normal file
|
@ -0,0 +1,92 @@
|
|||
package mage.cards.a;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.AttacksTriggeredAbility;
|
||||
import mage.abilities.common.delayed.ReflexiveTriggeredAbility;
|
||||
import mage.abilities.costs.common.DiscardCardCost;
|
||||
import mage.abilities.dynamicvalue.DynamicValue;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DoWhenCostPaid;
|
||||
import mage.abilities.effects.common.continuous.BoostTargetEffect;
|
||||
import mage.abilities.keyword.PartnerAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.SuperType;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class ArmixFiligreeThrasher extends CardImpl {
|
||||
|
||||
public ArmixFiligreeThrasher(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{2}{B}");
|
||||
|
||||
this.addSuperType(SuperType.LEGENDARY);
|
||||
this.subtype.add(SubType.GOLEM);
|
||||
this.power = new MageInt(3);
|
||||
this.toughness = new MageInt(2);
|
||||
|
||||
// Whenever Armix, Filigree Thrasher attacks, you may discard a card. When you do, target creature defending player controls gets -X/-X until end of turn, where X is the number of artifacts you control plus the number of artifact cards in your graveyard.
|
||||
ReflexiveTriggeredAbility ability = new ReflexiveTriggeredAbility(
|
||||
new BoostTargetEffect(
|
||||
ArmixFiligreeThrasherValue.instance,
|
||||
ArmixFiligreeThrasherValue.instance,
|
||||
Duration.EndOfTurn, true
|
||||
), false, "target creature defending player controls gets -X/-X until end of turn, " +
|
||||
"where X is the number of artifacts you control plus the number of artifact cards in your graveyard"
|
||||
);
|
||||
this.addAbility(new AttacksTriggeredAbility(new DoWhenCostPaid(
|
||||
ability, new DiscardCardCost(), "Discard a card?"
|
||||
), false));
|
||||
|
||||
// Partner
|
||||
this.addAbility(PartnerAbility.getInstance());
|
||||
}
|
||||
|
||||
private ArmixFiligreeThrasher(final ArmixFiligreeThrasher card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ArmixFiligreeThrasher copy() {
|
||||
return new ArmixFiligreeThrasher(this);
|
||||
}
|
||||
}
|
||||
|
||||
enum ArmixFiligreeThrasherValue implements DynamicValue {
|
||||
instance;
|
||||
|
||||
@Override
|
||||
public int calculate(Game game, Ability sourceAbility, Effect effect) {
|
||||
Player player = game.getPlayer(sourceAbility.getControllerId());
|
||||
if (player == null) {
|
||||
return 0;
|
||||
}
|
||||
return -(player.getGraveyard().count(
|
||||
StaticFilters.FILTER_CARD_ARTIFACT, player.getId(), game
|
||||
) + game.getBattlefield().count(
|
||||
StaticFilters.FILTER_PERMANENT_ARTIFACT,
|
||||
sourceAbility.getSourceId(),
|
||||
sourceAbility.getControllerId(), game
|
||||
));
|
||||
}
|
||||
|
||||
@Override
|
||||
public ArmixFiligreeThrasherValue copy() {
|
||||
return instance;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getMessage() {
|
||||
return "";
|
||||
}
|
||||
}
|
|
@ -37,6 +37,7 @@ public final class CommanderLegends extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Arcane Signet", 297, Rarity.UNCOMMON, mage.cards.a.ArcaneSignet.class));
|
||||
cards.add(new SetCardInfo("Archon of Coronation", 9, Rarity.MYTHIC, mage.cards.a.ArchonOfCoronation.class));
|
||||
cards.add(new SetCardInfo("Armillary Sphere", 298, Rarity.COMMON, mage.cards.a.ArmillarySphere.class));
|
||||
cards.add(new SetCardInfo("Armix, Filigree Thrasher", 108, Rarity.UNCOMMON, mage.cards.a.ArmixFiligreeThrasher.class));
|
||||
cards.add(new SetCardInfo("Aurora Phoenix", 161, Rarity.RARE, mage.cards.a.AuroraPhoenix.class));
|
||||
cards.add(new SetCardInfo("Austere Command", 12, Rarity.RARE, mage.cards.a.AustereCommand.class));
|
||||
cards.add(new SetCardInfo("Averna, the Chaos Bloom", 269, Rarity.RARE, mage.cards.a.AvernaTheChaosBloom.class));
|
||||
|
|
Loading…
Reference in a new issue