[MIR] Implement Sand Golem (#11519)

This commit is contained in:
Cameron Merkel 2023-12-06 22:19:59 -06:00 committed by GitHub
parent 9e1645a1bc
commit 7f0558ff3c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 47 additions and 0 deletions

View file

@ -0,0 +1,46 @@
package mage.cards.s;
import mage.MageInt;
import mage.abilities.common.DiscardedByOpponentTriggeredAbility;
import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility;
import mage.abilities.effects.Effect;
import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect;
import mage.abilities.effects.common.ReturnSourceFromGraveyardToBattlefieldWithCounterEffect;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.SubType;
import mage.counters.CounterType;
import java.util.UUID;
/**
* @author Cguy7777
*/
public final class SandGolem extends CardImpl {
public SandGolem(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{5}");
this.subtype.add(SubType.GOLEM);
this.power = new MageInt(3);
this.toughness = new MageInt(3);
// When a spell or ability an opponent controls causes you to discard Sand Golem,
// return Sand Golem from your graveyard to the battlefield with a +1/+1 counter on it at the beginning of the next end step.
Effect effect = new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextEndStepDelayedTriggeredAbility(
new ReturnSourceFromGraveyardToBattlefieldWithCounterEffect(CounterType.P1P1.createInstance(), false)));
effect.setText("return {this} from your graveyard to the battlefield with a +1/+1 counter on it at the beginning of the next end step");
this.addAbility(new DiscardedByOpponentTriggeredAbility(effect, true));
}
private SandGolem(final SandGolem card) {
super(card);
}
@Override
public SandGolem copy() {
return new SandGolem(this);
}
}

View file

@ -268,6 +268,7 @@ public final class Mirage extends ExpansionSet {
cards.add(new SetCardInfo("Roots of Life", 237, Rarity.UNCOMMON, mage.cards.r.RootsOfLife.class));
cards.add(new SetCardInfo("Sabertooth Cobra", 238, Rarity.COMMON, mage.cards.s.SabertoothCobra.class));
cards.add(new SetCardInfo("Sacred Mesa", 37, Rarity.RARE, mage.cards.s.SacredMesa.class));
cards.add(new SetCardInfo("Sand Golem", 318, Rarity.UNCOMMON, mage.cards.s.SandGolem.class));
cards.add(new SetCardInfo("Sandbar Crocodile", 88, Rarity.COMMON, mage.cards.s.SandbarCrocodile.class));
cards.add(new SetCardInfo("Sandstorm", 239, Rarity.COMMON, mage.cards.s.Sandstorm.class));
cards.add(new SetCardInfo("Sapphire Charm", 89, Rarity.COMMON, mage.cards.s.SapphireCharm.class));