mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
[BRO] Implement Machine Over Matter
This commit is contained in:
parent
3ee1a0e53c
commit
49aa4cf9c9
2 changed files with 50 additions and 0 deletions
49
Mage.Sets/src/mage/cards/m/MachineOverMatter.java
Normal file
49
Mage.Sets/src/mage/cards/m/MachineOverMatter.java
Normal file
|
@ -0,0 +1,49 @@
|
|||
package mage.cards.m;
|
||||
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.condition.Condition;
|
||||
import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition;
|
||||
import mage.abilities.effects.common.ReturnToHandTargetEffect;
|
||||
import mage.abilities.effects.common.cost.SpellCostReductionSourceEffect;
|
||||
import mage.abilities.hint.ConditionHint;
|
||||
import mage.abilities.hint.Hint;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.common.TargetNonlandPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class MachineOverMatter extends CardImpl {
|
||||
|
||||
private static final Condition condition
|
||||
= new PermanentsOnTheBattlefieldCondition(StaticFilters.FILTER_PERMANENT_ARTIFACT_CREATURE);
|
||||
private static final Hint hint = new ConditionHint(condition, "You control an artifact creature");
|
||||
|
||||
public MachineOverMatter(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{U}");
|
||||
|
||||
// This spell costs {1} less to cast if you control an artifact creature.
|
||||
this.addAbility(new SimpleStaticAbility(
|
||||
Zone.ALL, new SpellCostReductionSourceEffect(1, condition)
|
||||
).setRuleAtTheTop(true).addHint(hint));
|
||||
|
||||
// Return target nonland permanent to its owner's hand.
|
||||
this.getSpellAbility().addEffect(new ReturnToHandTargetEffect());
|
||||
this.getSpellAbility().addTarget(new TargetNonlandPermanent());
|
||||
}
|
||||
|
||||
private MachineOverMatter(final MachineOverMatter card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public MachineOverMatter copy() {
|
||||
return new MachineOverMatter(this);
|
||||
}
|
||||
}
|
|
@ -96,6 +96,7 @@ public final class TheBrothersWar extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Llanowar Wastes", 264, Rarity.RARE, mage.cards.l.LlanowarWastes.class));
|
||||
cards.add(new SetCardInfo("Loran of the Third Path", 12, Rarity.RARE, mage.cards.l.LoranOfTheThirdPath.class));
|
||||
cards.add(new SetCardInfo("Loran, Disciple of History", 13, Rarity.UNCOMMON, mage.cards.l.LoranDiscipleOfHistory.class));
|
||||
cards.add(new SetCardInfo("Machine Over Matter", 57, Rarity.COMMON, mage.cards.m.MachineOverMatter.class));
|
||||
cards.add(new SetCardInfo("Mass Production", 15, Rarity.UNCOMMON, mage.cards.m.MassProduction.class));
|
||||
cards.add(new SetCardInfo("Mine Worker", 239, Rarity.COMMON, mage.cards.m.MineWorker.class));
|
||||
cards.add(new SetCardInfo("Mishra's Command", 141, Rarity.RARE, mage.cards.m.MishrasCommand.class));
|
||||
|
|
Loading…
Reference in a new issue