[PIP] Implement Mister Gutsy (#11952)

This commit is contained in:
Cameron Merkel 2024-03-16 17:29:12 -05:00 committed by GitHub
parent f3ab9d737a
commit 600f992aa0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 64 additions and 0 deletions

View file

@ -0,0 +1,60 @@
package mage.cards.m;
import java.util.UUID;
import mage.MageInt;
import mage.abilities.common.DiesSourceTriggeredAbility;
import mage.abilities.common.SpellCastControllerTriggeredAbility;
import mage.abilities.dynamicvalue.common.CountersSourceCount;
import mage.abilities.effects.common.CreateTokenEffect;
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
import mage.constants.SubType;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.counters.CounterType;
import mage.filter.FilterSpell;
import mage.filter.predicate.Predicates;
import mage.game.permanent.token.JunkToken;
/**
* @author Cguy7777
*/
public final class MisterGutsy extends CardImpl {
private static final FilterSpell filter = new FilterSpell("an Aura or Equipment spell");
static {
filter.add(Predicates.or(
SubType.AURA.getPredicate(),
SubType.EQUIPMENT.getPredicate()));
}
public MisterGutsy(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{2}");
this.subtype.add(SubType.ROBOT);
this.subtype.add(SubType.SOLDIER);
this.power = new MageInt(1);
this.toughness = new MageInt(1);
// Whenever you cast an Aura or Equipment spell, put a +1/+1 counter on Mister Gutsy.
this.addAbility(new SpellCastControllerTriggeredAbility(
new AddCountersSourceEffect(CounterType.P1P1.createInstance()), filter, false));
// When Mister Gutsy dies, create X Junk tokens, where X is the number of +1/+1 counters on it.
this.addAbility(new DiesSourceTriggeredAbility(new CreateTokenEffect(new JunkToken(), new CountersSourceCount(CounterType.P1P1))
.setText("create X Junk tokens, where X is the number of +1/+1 counters on it. " +
"<i>(They're artifacts with \"{T}, Sacrifice this artifact: Exile the top card of your library. " +
"You may play that card this turn. Activate only as a sorcery.\")</i>")));
}
private MisterGutsy(final MisterGutsy card) {
super(card);
}
@Override
public MisterGutsy copy() {
return new MisterGutsy(this);
}
}

View file

@ -153,6 +153,10 @@ public final class Fallout extends ExpansionSet {
cards.add(new SetCardInfo("Mechanized Production", 178, Rarity.MYTHIC, mage.cards.m.MechanizedProduction.class));
cards.add(new SetCardInfo("Memorial to Glory", 271, Rarity.UNCOMMON, mage.cards.m.MemorialToGlory.class));
cards.add(new SetCardInfo("Mind Stone", 235, Rarity.UNCOMMON, mage.cards.m.MindStone.class));
cards.add(new SetCardInfo("Mister Gutsy", 136, Rarity.RARE, mage.cards.m.MisterGutsy.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Mister Gutsy", 433, Rarity.RARE, mage.cards.m.MisterGutsy.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Mister Gutsy", 664, Rarity.RARE, mage.cards.m.MisterGutsy.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Mister Gutsy", 961, Rarity.RARE, mage.cards.m.MisterGutsy.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Morbid Opportunist", 186, Rarity.UNCOMMON, mage.cards.m.MorbidOpportunist.class));
cards.add(new SetCardInfo("Mortuary Mire", 272, Rarity.COMMON, mage.cards.m.MortuaryMire.class));
cards.add(new SetCardInfo("Mossfire Valley", 273, Rarity.RARE, mage.cards.m.MossfireValley.class));