implement [M3C] Jyoti, Moag Ancient (#12313)

This commit is contained in:
grimreap124 2024-05-29 02:09:44 +10:00 committed by GitHub
parent 77a8f57026
commit 83abaac356
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 66 additions and 0 deletions

View file

@ -0,0 +1,65 @@
package mage.cards.j;
import java.util.UUID;
import mage.MageInt;
import mage.abilities.common.BeginningOfCombatTriggeredAbility;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
import mage.abilities.dynamicvalue.common.CommanderCastFromCommandZoneValue;
import mage.abilities.dynamicvalue.common.SourcePermanentPowerCount;
import mage.abilities.effects.common.CreateTokenEffect;
import mage.abilities.effects.common.continuous.BoostControlledEffect;
import mage.constants.SubType;
import mage.constants.SuperType;
import mage.constants.TargetController;
import mage.game.permanent.token.ForestDryadToken;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.Duration;
import mage.filter.common.FilterCreaturePermanent;
/**
*
* @author grimreap124
*/
public final class JyotiMoagAncient extends CardImpl {
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("land creatures");
private static final SourcePermanentPowerCount xValue = new SourcePermanentPowerCount();
static {
filter.add(CardType.LAND.getPredicate());
}
public JyotiMoagAncient(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[] { CardType.CREATURE }, "{2}{G}{U}");
this.supertype.add(SuperType.LEGENDARY);
this.subtype.add(SubType.ELEMENTAL);
this.power = new MageInt(2);
this.toughness = new MageInt(4);
// When Jyoti, Moag Ancient enters the battlefield, create a 1/1 green Forest Dryad land creature token
// for each time you've cast your commander from the command zone this game.
this.addAbility(new EntersBattlefieldTriggeredAbility(
new CreateTokenEffect(new ForestDryadToken(), CommanderCastFromCommandZoneValue.instance).setText(
"create a 1/1 green Forest Dryad land creature token for each time you've cast your commander from the command zone this game"))
.addHint(CommanderCastFromCommandZoneValue.getHint()));
// At the beginning of each combat, land creatures you control get +X/+X until end of turn, where X is Jyoti's power.
this.addAbility(new BeginningOfCombatTriggeredAbility(
new BoostControlledEffect(xValue, xValue, Duration.EndOfTurn, filter, false),
TargetController.ANY, false));
}
private JyotiMoagAncient(final JyotiMoagAncient card) {
super(card);
}
@Override
public JyotiMoagAncient copy() {
return new JyotiMoagAncient(this);
}
}

View file

@ -31,6 +31,7 @@ public final class ModernHorizons3Commander extends ExpansionSet {
cards.add(new SetCardInfo("Drowner of Hope", 182, Rarity.RARE, mage.cards.d.DrownerOfHope.class)); cards.add(new SetCardInfo("Drowner of Hope", 182, Rarity.RARE, mage.cards.d.DrownerOfHope.class));
cards.add(new SetCardInfo("Final Act", 52, Rarity.RARE, mage.cards.f.FinalAct.class)); cards.add(new SetCardInfo("Final Act", 52, Rarity.RARE, mage.cards.f.FinalAct.class));
cards.add(new SetCardInfo("Hideous Taskmaster", 57, Rarity.RARE, mage.cards.h.HideousTaskmaster.class)); cards.add(new SetCardInfo("Hideous Taskmaster", 57, Rarity.RARE, mage.cards.h.HideousTaskmaster.class));
cards.add(new SetCardInfo("Jyoti, Moag Ancient", 8, Rarity.MYTHIC, mage.cards.j.JyotiMoagAncient.class));
cards.add(new SetCardInfo("March from Velis Vel", 48, Rarity.RARE, mage.cards.m.MarchFromVelisVel.class)); cards.add(new SetCardInfo("March from Velis Vel", 48, Rarity.RARE, mage.cards.m.MarchFromVelisVel.class));
cards.add(new SetCardInfo("Oblivion Sower", 158, Rarity.MYTHIC, mage.cards.o.OblivionSower.class)); cards.add(new SetCardInfo("Oblivion Sower", 158, Rarity.MYTHIC, mage.cards.o.OblivionSower.class));
cards.add(new SetCardInfo("Siege-Gang Lieutenant", 61, Rarity.RARE, mage.cards.s.SiegeGangLieutenant.class)); cards.add(new SetCardInfo("Siege-Gang Lieutenant", 61, Rarity.RARE, mage.cards.s.SiegeGangLieutenant.class));