mirror of
https://github.com/correl/mage.git
synced 2024-11-29 03:00:12 +00:00
Implemented Skola Gravedancer
This commit is contained in:
parent
6b7d217f98
commit
135d7bce27
3 changed files with 76 additions and 26 deletions
|
@ -1,7 +1,6 @@
|
|||
|
||||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.BeginningOfUpkeepTriggeredAbility;
|
||||
|
@ -9,19 +8,16 @@ import mage.abilities.common.PutCardIntoGraveFromAnywhereAllTriggeredAbility;
|
|||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
|
||||
import mage.cards.*;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.TargetController;
|
||||
import mage.constants.Zone;
|
||||
import mage.constants.*;
|
||||
import mage.counters.CounterType;
|
||||
import mage.filter.common.FilterLandCard;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.players.Player;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
public final class CountrysideCrusher extends CardImpl {
|
||||
|
@ -35,16 +31,19 @@ public final class CountrysideCrusher extends CardImpl {
|
|||
this.toughness = new MageInt(3);
|
||||
|
||||
// At the beginning of your upkeep, reveal the top card of your library. If it's a land card, put it into your graveyard and repeat this process.
|
||||
this.addAbility(new BeginningOfUpkeepTriggeredAbility(new CountrysideCrusherEffect(), TargetController.YOU, false));
|
||||
this.addAbility(new BeginningOfUpkeepTriggeredAbility(
|
||||
new CountrysideCrusherEffect(), TargetController.YOU, false
|
||||
));
|
||||
|
||||
// Whenever a land card is put into your graveyard from anywhere, put a +1/+1 counter on Countryside Crusher.
|
||||
this.addAbility(new PutCardIntoGraveFromAnywhereAllTriggeredAbility(
|
||||
new AddCountersSourceEffect(CounterType.P1P1.createInstance()),
|
||||
false, new FilterLandCard("a land card"), TargetController.YOU
|
||||
false, StaticFilters.FILTER_CARD_LAND_A, TargetController.YOU
|
||||
));
|
||||
|
||||
}
|
||||
|
||||
public CountrysideCrusher(final CountrysideCrusher card) {
|
||||
private CountrysideCrusher(final CountrysideCrusher card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
|
@ -56,12 +55,12 @@ public final class CountrysideCrusher extends CardImpl {
|
|||
|
||||
class CountrysideCrusherEffect extends OneShotEffect {
|
||||
|
||||
public CountrysideCrusherEffect() {
|
||||
CountrysideCrusherEffect() {
|
||||
super(Outcome.Discard);
|
||||
this.staticText = "reveal the top card of your library. If it's a land card, put it into your graveyard and repeat this process";
|
||||
}
|
||||
|
||||
public CountrysideCrusherEffect(final CountrysideCrusherEffect effect) {
|
||||
private CountrysideCrusherEffect(final CountrysideCrusherEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
|
@ -74,7 +73,9 @@ class CountrysideCrusherEffect extends OneShotEffect {
|
|||
public boolean apply(Game game, Ability source) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId());
|
||||
if (controller != null && sourcePermanent != null) {
|
||||
if (controller == null || sourcePermanent == null) {
|
||||
return false;
|
||||
}
|
||||
Cards cards = new CardsImpl();
|
||||
for (Card card : controller.getLibrary().getCards(game)) {
|
||||
cards.add(card);
|
||||
|
@ -87,6 +88,4 @@ class CountrysideCrusherEffect extends OneShotEffect {
|
|||
controller.revealCards(sourcePermanent.getName(), cards, game);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
50
Mage.Sets/src/mage/cards/s/SkolaGrovedancer.java
Normal file
50
Mage.Sets/src/mage/cards/s/SkolaGrovedancer.java
Normal file
|
@ -0,0 +1,50 @@
|
|||
package mage.cards.s;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.common.PutCardIntoGraveFromAnywhereAllTriggeredAbility;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.effects.common.GainLifeEffect;
|
||||
import mage.abilities.effects.common.PutTopCardOfLibraryIntoGraveControllerEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.TargetController;
|
||||
import mage.filter.StaticFilters;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class SkolaGrovedancer extends CardImpl {
|
||||
|
||||
public SkolaGrovedancer(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT, CardType.CREATURE}, "{1}{G}");
|
||||
|
||||
this.subtype.add(SubType.SATYR);
|
||||
this.subtype.add(SubType.DRUID);
|
||||
this.power = new MageInt(2);
|
||||
this.toughness = new MageInt(2);
|
||||
|
||||
// Whenever a land card is put into your graveyard from anywhere, you gain 1 life.
|
||||
this.addAbility(new PutCardIntoGraveFromAnywhereAllTriggeredAbility(
|
||||
new GainLifeEffect(1), false, StaticFilters.FILTER_CARD_LAND_A, TargetController.YOU
|
||||
));
|
||||
|
||||
// {2}{G}: Put the top card of your library into your graveyard.
|
||||
this.addAbility(new SimpleActivatedAbility(
|
||||
new PutTopCardOfLibraryIntoGraveControllerEffect(1), new ManaCostsImpl("{2}{G}")
|
||||
));
|
||||
}
|
||||
|
||||
private SkolaGrovedancer(final SkolaGrovedancer card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public SkolaGrovedancer copy() {
|
||||
return new SkolaGrovedancer(this);
|
||||
}
|
||||
}
|
|
@ -209,6 +209,7 @@ public final class TherosBeyondDeath extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Shimmerwing Chimera", 64, Rarity.UNCOMMON, mage.cards.s.ShimmerwingChimera.class));
|
||||
cards.add(new SetCardInfo("Shoal Kraken", 65, Rarity.UNCOMMON, mage.cards.s.ShoalKraken.class));
|
||||
cards.add(new SetCardInfo("Siona, Captain of the Pyleas", 226, Rarity.UNCOMMON, mage.cards.s.SionaCaptainOfThePyleas.class));
|
||||
cards.add(new SetCardInfo("Skola Grovedancer", 202, Rarity.COMMON, mage.cards.s.SkolaGrovedancer.class));
|
||||
cards.add(new SetCardInfo("Skophos Maze-Warden", 153, Rarity.UNCOMMON, mage.cards.s.SkophosMazeWarden.class));
|
||||
cards.add(new SetCardInfo("Skophos Warleader", 154, Rarity.COMMON, mage.cards.s.SkophosWarleader.class));
|
||||
cards.add(new SetCardInfo("Slaughter-Priest of Mogis", 227, Rarity.UNCOMMON, mage.cards.s.SlaughterPriestOfMogis.class));
|
||||
|
|
Loading…
Reference in a new issue