mirror of
https://github.com/magefree/mage.git
synced 2026-01-10 21:02:08 -08:00
[LCI] Implement Corpses of the Lost
This commit is contained in:
parent
c279696fd6
commit
726f72dd12
3 changed files with 106 additions and 0 deletions
76
Mage.Sets/src/mage/cards/c/CorpsesOfTheLost.java
Normal file
76
Mage.Sets/src/mage/cards/c/CorpsesOfTheLost.java
Normal file
|
|
@ -0,0 +1,76 @@
|
|||
package mage.cards.c;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.BeginningOfEndStepTriggeredAbility;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.condition.common.DescendedThisTurnCondition;
|
||||
import mage.abilities.costs.common.PayLifeCost;
|
||||
import mage.abilities.dynamicvalue.common.DescendedThisTurnCount;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
import mage.abilities.effects.common.DoIfCostPaid;
|
||||
import mage.abilities.effects.common.ReturnToHandSourceEffect;
|
||||
import mage.abilities.effects.common.continuous.BoostControlledEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityControlledEffect;
|
||||
import mage.abilities.keyword.HasteAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.TargetController;
|
||||
import mage.filter.FilterPermanent;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.game.permanent.token.SkeletonPirateToken;
|
||||
import mage.watchers.common.DescendedWatcher;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author Susucr
|
||||
*/
|
||||
public final class CorpsesOfTheLost extends CardImpl {
|
||||
|
||||
private static final FilterCreaturePermanent filter =
|
||||
new FilterCreaturePermanent(SubType.SKELETON, "Skeletons you control");
|
||||
private static final FilterPermanent filter2 =
|
||||
new FilterPermanent(SubType.SKELETON, "Skeletons you control");
|
||||
|
||||
public CorpsesOfTheLost(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}");
|
||||
|
||||
// Skeletons you control get +1/+0 and have haste.
|
||||
Ability ability = new SimpleStaticAbility(
|
||||
new BoostControlledEffect(
|
||||
1, 0, Duration.WhileOnBattlefield,
|
||||
filter, false
|
||||
)
|
||||
);
|
||||
ability.addEffect(new GainAbilityControlledEffect(
|
||||
HasteAbility.getInstance(),
|
||||
Duration.WhileOnBattlefield,
|
||||
filter2
|
||||
).setText("and have haste"));
|
||||
this.addAbility(ability);
|
||||
|
||||
// When Corpses of the Lost enters the battlefield, create a 2/2 black Skeleton Pirate creature token.
|
||||
this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new SkeletonPirateToken())));
|
||||
|
||||
// At the beginning of your end step, if you descended this turn, you may pay 1 life. If you do, return Corpses of the Lost to its owner's hand.
|
||||
this.addAbility(new BeginningOfEndStepTriggeredAbility(
|
||||
new DoIfCostPaid(
|
||||
new ReturnToHandSourceEffect(),
|
||||
new PayLifeCost(1)
|
||||
), TargetController.YOU, DescendedThisTurnCondition.instance, false
|
||||
).addHint(DescendedThisTurnCount.getHint()), new DescendedWatcher());
|
||||
}
|
||||
|
||||
private CorpsesOfTheLost(final CorpsesOfTheLost card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public CorpsesOfTheLost copy() {
|
||||
return new CorpsesOfTheLost(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -51,6 +51,7 @@ public final class TheLostCavernsOfIxalan extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Colossadactyl", 180, Rarity.UNCOMMON, mage.cards.c.Colossadactyl.class));
|
||||
cards.add(new SetCardInfo("Compass Gnome", 250, Rarity.COMMON, mage.cards.c.CompassGnome.class));
|
||||
cards.add(new SetCardInfo("Confounding Riddle", 50, Rarity.UNCOMMON, mage.cards.c.ConfoundingRiddle.class));
|
||||
cards.add(new SetCardInfo("Corpses of the Lost", 98, Rarity.RARE, mage.cards.c.CorpsesOfTheLost.class));
|
||||
cards.add(new SetCardInfo("Cosmium Confluence", 181, Rarity.RARE, mage.cards.c.CosmiumConfluence.class));
|
||||
cards.add(new SetCardInfo("Cosmium Kiln", 6, Rarity.UNCOMMON, mage.cards.c.CosmiumKiln.class));
|
||||
cards.add(new SetCardInfo("Dauntless Dismantler", 8, Rarity.UNCOMMON, mage.cards.d.DauntlessDismantler.class));
|
||||
|
|
|
|||
|
|
@ -0,0 +1,29 @@
|
|||
package mage.game.permanent.token;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
|
||||
/**
|
||||
* @author Susucr
|
||||
*/
|
||||
public final class SkeletonPirateToken extends TokenImpl {
|
||||
|
||||
public SkeletonPirateToken() {
|
||||
super("Skeleton Pirate Token", "2/2 black Skeleton Pirate creature token");
|
||||
cardType.add(CardType.CREATURE);
|
||||
this.subtype.add(SubType.SKELETON);
|
||||
this.subtype.add(SubType.PIRATE);
|
||||
color.setBlack(true);
|
||||
power = new MageInt(2);
|
||||
toughness = new MageInt(2);
|
||||
}
|
||||
|
||||
protected SkeletonPirateToken(final SkeletonPirateToken token) {
|
||||
super(token);
|
||||
}
|
||||
|
||||
public SkeletonPirateToken copy() {
|
||||
return new SkeletonPirateToken(this);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue