mirror of
https://github.com/magefree/mage.git
synced 2026-01-10 04:42:07 -08:00
Merge remote-tracking branch 'upstream/master'
This commit is contained in:
commit
217b4919f3
202 changed files with 2718 additions and 1929 deletions
|
|
@ -43,11 +43,6 @@ import mage.filter.predicate.permanent.AnotherPredicate;
|
|||
* @author stravant
|
||||
*/
|
||||
public class AhnCropChampion extends CardImpl {
|
||||
private final static FilterControlledCreaturePermanent otherCreaturesFilter = new FilterControlledCreaturePermanent("other creatures you control");
|
||||
static {
|
||||
otherCreaturesFilter.add(new AnotherPredicate());
|
||||
}
|
||||
|
||||
public AhnCropChampion(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{G}{W}");
|
||||
|
||||
|
|
@ -57,7 +52,7 @@ public class AhnCropChampion extends CardImpl {
|
|||
this.toughness = new MageInt(4);
|
||||
|
||||
// You may exert Ahn-Crop Champion as it attacks. When you do, untap all other creatures you control.
|
||||
addAbility(new ExertAbility(new BecomesExertSourceTriggeredAbility(new UntapAllControllerEffect(otherCreaturesFilter))));
|
||||
addAbility(new ExertAbility(new BecomesExertSourceTriggeredAbility(new UntapAllControllerEffect(new FilterControlledCreaturePermanent("creatures you control"), null, false))));
|
||||
}
|
||||
|
||||
public AhnCropChampion(final AhnCropChampion card) {
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
|
|
@ -34,13 +35,12 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterControlledCreaturePermanent;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.token.CentaurToken;
|
||||
import mage.players.Player;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
|
|
@ -48,7 +48,7 @@ import java.util.UUID;
|
|||
public class AliveWell extends SplitCard {
|
||||
|
||||
public AliveWell(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{G}", "{W}", true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{G}", "{W}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Alive
|
||||
// Create a 3/3 green Centaur creature token.
|
||||
|
|
|
|||
|
|
@ -1,7 +1,8 @@
|
|||
package mage.cards.a;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.SpellAbility;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.CardImpl;
|
||||
|
|
@ -9,24 +10,20 @@ import mage.cards.CardSetInfo;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.WatcherScope;
|
||||
import mage.constants.Zone;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.DamagedPlayerEvent;
|
||||
import mage.game.events.GameEvent;
|
||||
import mage.game.stack.Spell;
|
||||
import mage.players.Player;
|
||||
import mage.watchers.Watcher;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author stravant
|
||||
*/
|
||||
public class ApproachOfTheSecondSun extends CardImpl {
|
||||
|
||||
public ApproachOfTheSecondSun(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{6}{W}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{6}{W}");
|
||||
|
||||
getSpellAbility().addEffect(new ApproachOfTheSecondSunEffect());
|
||||
getSpellAbility().addWatcher(new ApproachOfTheSecondSunWatcher());
|
||||
|
|
@ -43,11 +40,12 @@ public class ApproachOfTheSecondSun extends CardImpl {
|
|||
}
|
||||
|
||||
class ApproachOfTheSecondSunEffect extends OneShotEffect {
|
||||
|
||||
public ApproachOfTheSecondSunEffect() {
|
||||
super(Outcome.Win);
|
||||
this.staticText =
|
||||
"If you cast {this} from you hand and you cast another spell named {this} this game, you win the game. " +
|
||||
"If not, you gain 7 life and put {this} back into your library as the seventh card from the top.";
|
||||
this.staticText
|
||||
= "If {this} was cast from your hand and you've cast another spell named Approach of the Second Sun this game, you win the game. "
|
||||
+ "Otherwise, put {this} into its owner's library seventh from the top and you gain 7 life.";
|
||||
}
|
||||
|
||||
public ApproachOfTheSecondSunEffect(final ApproachOfTheSecondSunEffect effect) {
|
||||
|
|
@ -62,10 +60,11 @@ class ApproachOfTheSecondSunEffect extends OneShotEffect {
|
|||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
if (controller != null) {
|
||||
ApproachOfTheSecondSunWatcher watcher =
|
||||
(ApproachOfTheSecondSunWatcher) game.getState().getWatchers().get("approachOfTheSecondSunWatcher", source.getControllerId());
|
||||
if (watcher != null && watcher.getApproachesCast() > 1) {
|
||||
Spell spell = game.getStack().getSpell(source.getSourceId());
|
||||
if (controller != null && spell != null) {
|
||||
ApproachOfTheSecondSunWatcher watcher
|
||||
= (ApproachOfTheSecondSunWatcher) game.getState().getWatchers().get(ApproachOfTheSecondSunWatcher.class.getName());
|
||||
if (watcher != null && watcher.getApproachesCast(controller.getId()) > 1 && spell.getFromZone() == Zone.HAND) {
|
||||
// Win the game
|
||||
controller.won(game);
|
||||
} else {
|
||||
|
|
@ -73,21 +72,32 @@ class ApproachOfTheSecondSunEffect extends OneShotEffect {
|
|||
controller.gainLife(7, game);
|
||||
|
||||
// Put this into the library as the 7th from the top
|
||||
List<Card> top6 = new ArrayList<>();
|
||||
// Cut the top 6 cards off into a temporary array
|
||||
for (int i = 0; i < 6 && controller.getLibrary().hasCards(); ++i) {
|
||||
top6.add(controller.getLibrary().removeFromTop(game));
|
||||
}
|
||||
// Put this card (if the ability came from an ApproachOfTheSecondSun spell card) on top
|
||||
Card sourceCard = game.getCard(source.getSourceId());
|
||||
if (sourceCard != null) {
|
||||
controller.getLibrary().putOnTop(sourceCard, game);
|
||||
}
|
||||
Card spellCard = game.getStack().getSpell(source.getSourceId()).getCard();
|
||||
if (spellCard != null) {
|
||||
List<Card> top6 = new ArrayList<>();
|
||||
// Cut the top 6 cards off into a temporary array
|
||||
for (int i = 0; i < 6 && controller.getLibrary().hasCards(); ++i) {
|
||||
top6.add(controller.getLibrary().removeFromTop(game));
|
||||
}
|
||||
|
||||
// put the top 6 we took earlier back on top (going in reverse order this time to get them back
|
||||
// on top in the proper order)
|
||||
for (int i = top6.size() - 1; i >= 0; --i) {
|
||||
controller.getLibrary().putOnTop(top6.get(i), game);
|
||||
// Is the library now empty, thus the rise is on the bottom (for the message to the players)?
|
||||
boolean isOnBottom = !controller.getLibrary().hasCards();
|
||||
|
||||
// Put this card (if the ability came from an ApproachOfTheSecondSun spell card) on top
|
||||
spellCard.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
|
||||
|
||||
// put the top 6 we took earlier back on top (going in reverse order this time to get them back
|
||||
// on top in the proper order)
|
||||
for (int i = top6.size() - 1; i >= 0; --i) {
|
||||
controller.getLibrary().putOnTop(top6.get(i), game);
|
||||
}
|
||||
|
||||
// Inform the players
|
||||
if (isOnBottom) {
|
||||
game.informPlayers(controller.getLogName() + " puts " + spell.getLogName() + " on the bottom of his or her library.");
|
||||
} else {
|
||||
game.informPlayers(controller.getLogName() + " puts " + spell.getLogName() + " into his or her library 6th from the top.");
|
||||
}
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
|
@ -96,28 +106,37 @@ class ApproachOfTheSecondSunEffect extends OneShotEffect {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
class ApproachOfTheSecondSunWatcher extends Watcher {
|
||||
private int approachesCast = 0;
|
||||
|
||||
private Map<UUID, Integer> approachesCast = new HashMap<>();
|
||||
|
||||
public ApproachOfTheSecondSunWatcher() {
|
||||
super("approachOfTheSecondSunWatcher", WatcherScope.PLAYER);
|
||||
super(ApproachOfTheSecondSunWatcher.class.getName(), WatcherScope.GAME);
|
||||
}
|
||||
|
||||
public ApproachOfTheSecondSunWatcher(final ApproachOfTheSecondSunWatcher watcher) {
|
||||
super(watcher);
|
||||
approachesCast = watcher.approachesCast;
|
||||
approachesCast = new HashMap<>(approachesCast);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void watch(GameEvent event, Game game) {
|
||||
if (event.getType() == GameEvent.EventType.SPELL_CAST && event.getPlayerId().equals(this.getControllerId())) {
|
||||
++approachesCast;
|
||||
if (event.getType() == GameEvent.EventType.SPELL_CAST) {
|
||||
Spell spell = game.getStack().getSpell(event.getSourceId());
|
||||
if (spell != null && spell.getName().equals("Approach of the Second Sun")) {
|
||||
int cast = getApproachesCast(event.getPlayerId());
|
||||
approachesCast.put(event.getPlayerId(), cast + 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public int getApproachesCast() {
|
||||
return approachesCast;
|
||||
public int getApproachesCast(UUID player) {
|
||||
Integer cast = approachesCast.get(player);
|
||||
if (cast == null) {
|
||||
return 0;
|
||||
} else {
|
||||
return cast;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.common.combat.MustBeBlockedByAllTargetEffect;
|
||||
import mage.abilities.effects.common.continuous.BoostTargetEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityTargetEffect;
|
||||
|
|
@ -36,24 +36,17 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class ArmedDangerous extends SplitCard {
|
||||
|
||||
public ArmedDangerous(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{1}{R}","{3}{G}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{R}", "{3}{G}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Armed
|
||||
// Target creature gets +1/+1 and gains double strike until end of turn.
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(1,1, Duration.EndOfTurn));
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(1, 1, Duration.EndOfTurn));
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new GainAbilityTargetEffect(DoubleStrikeAbility.getInstance(), Duration.EndOfTurn));
|
||||
getLeftHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
|
|
@ -42,8 +43,6 @@ import mage.game.permanent.Permanent;
|
|||
import mage.target.common.TargetCreaturePermanent;
|
||||
import mage.util.functions.ApplyToPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
|
|
@ -51,7 +50,7 @@ import java.util.UUID;
|
|||
public class ArtisanOfForms extends CardImpl {
|
||||
|
||||
public ArtisanOfForms(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{1}{U}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{U}");
|
||||
this.subtype.add("Human");
|
||||
this.subtype.add("Wizard");
|
||||
|
||||
|
|
@ -79,7 +78,7 @@ public class ArtisanOfForms extends CardImpl {
|
|||
class ArtisanOfFormsApplyToPermanent extends ApplyToPermanent {
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
Effect effect = new CopyPermanentEffect(new ArtisanOfFormsApplyToPermanent());
|
||||
effect.setText("have {this} become a copy of target creature and gain this ability");
|
||||
mageObject.getAbilities().add(new HeroicAbility(effect, true));
|
||||
|
|
@ -87,7 +86,7 @@ class ArtisanOfFormsApplyToPermanent extends ApplyToPermanent {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
Effect effect = new CopyPermanentEffect(new ArtisanOfFormsApplyToPermanent());
|
||||
effect.setText("have {this} become a copy of target creature and gain this ability");
|
||||
permanent.addAbility(new HeroicAbility(effect, true), game);
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ import mage.watchers.Watcher;
|
|||
public class AsForetold extends CardImpl {
|
||||
public AsForetold(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}");
|
||||
|
||||
|
||||
|
||||
// At the beginning of your upkeep, put a time counter on As Foretold.
|
||||
addAbility(
|
||||
|
|
@ -145,7 +145,7 @@ class AsForetoldAlternativeCost extends AlternativeCostSourceAbility {
|
|||
class AsForetoldAddAltCostEffect extends ContinuousEffectImpl {
|
||||
public AsForetoldAddAltCostEffect() {
|
||||
super(Duration.WhileOnBattlefield, Outcome.Benefit);
|
||||
staticText = "Once each turn, you may pay {0} rather than pay the mana cost for a spelly ou cast with converted mana cost X or less, where X is the number of time counters on {this}.";
|
||||
staticText = "Once each turn, you may pay {0} rather than pay the mana cost for a spell you cast with converted mana cost X or less, where X is the number of time counters on {this}.";
|
||||
}
|
||||
|
||||
public AsForetoldAddAltCostEffect(final AsForetoldAddAltCostEffect effect) {
|
||||
|
|
|
|||
|
|
@ -25,30 +25,23 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
import mage.abilities.effects.common.DamageTargetEffect;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.game.permanent.token.ElephantToken;
|
||||
import mage.target.common.TargetCreatureOrPlayer;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class AssaultBattery extends SplitCard {
|
||||
|
||||
public AssaultBattery(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{R}","{3}{G}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{R}", "{3}{G}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Assault
|
||||
// Assault deals 2 damage to target creature or player.
|
||||
|
|
|
|||
|
|
@ -35,15 +35,14 @@ import mage.abilities.effects.common.continuous.GainAbilityControlledEffect;
|
|||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.abilities.keyword.VigilanceAbility;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.keyword.EmbalmAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.v.Vigilance;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.filter.predicate.permanent.TokenPredicate;
|
||||
|
||||
/**
|
||||
*
|
||||
|
|
@ -53,7 +52,7 @@ public class AvenWindGuide extends CardImpl {
|
|||
|
||||
public AvenWindGuide(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}{U}");
|
||||
|
||||
|
||||
this.subtype.add("Bird");
|
||||
this.subtype.add("Warrior");
|
||||
this.power = new MageInt(2);
|
||||
|
|
@ -66,18 +65,18 @@ public class AvenWindGuide extends CardImpl {
|
|||
this.addAbility(VigilanceAbility.getInstance());
|
||||
|
||||
// Creature tokens you control have flying and vigilance.
|
||||
Ability ability =
|
||||
new SimpleStaticAbility(
|
||||
Zone.BATTLEFIELD,
|
||||
new GainAbilityControlledEffect(
|
||||
Effect effect = new GainAbilityControlledEffect(
|
||||
FlyingAbility.getInstance(),
|
||||
Duration.WhileOnBattlefield,
|
||||
StaticFilters.FILTER_CREATURE_TOKENS));
|
||||
ability.addEffect(
|
||||
new GainAbilityControlledEffect(
|
||||
StaticFilters.FILTER_CREATURE_TOKENS);
|
||||
effect.setText("Creature tokens you control have flying");
|
||||
Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, effect);
|
||||
effect = new GainAbilityControlledEffect(
|
||||
VigilanceAbility.getInstance(),
|
||||
Duration.WhileOnBattlefield,
|
||||
StaticFilters.FILTER_CREATURE_TOKENS));
|
||||
StaticFilters.FILTER_CREATURE_TOKENS);
|
||||
effect.setText("and vigilance");
|
||||
ability.addEffect(effect);
|
||||
this.addAbility(ability);
|
||||
|
||||
// Embalm {4}{W}{U}
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.b;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.DelayedTriggeredAbility;
|
||||
import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
|
|
@ -35,6 +36,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
|
|
@ -42,12 +44,10 @@ import mage.game.events.GameEvent.EventType;
|
|||
import mage.game.permanent.Permanent;
|
||||
import mage.game.permanent.token.BirdToken;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
public class BeckCall extends SplitCard {
|
||||
|
||||
public BeckCall(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{G}{U}","{4}{W}{U}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{G}{U}", "{4}{W}{U}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Beck
|
||||
// Whenever a creature enters the battlefield this turn, you may draw a card.
|
||||
|
|
|
|||
|
|
@ -97,7 +97,7 @@ class BonePickerCostAdjustmentAbility extends SimpleStaticAbility implements Adj
|
|||
|
||||
@Override
|
||||
public String getRule() {
|
||||
return "If a creature died this turn, {this} costs 3 less to cast.";
|
||||
return "If a creature died this turn, {this} costs {3} less to cast.";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ import mage.watchers.common.CreaturesDiedWatcher;
|
|||
*/
|
||||
public class BontuTheGlorified extends CardImpl {
|
||||
|
||||
private static final FilterControlledPermanent filter = new FilterControlledPermanent();
|
||||
private static final FilterControlledPermanent filter = new FilterControlledPermanent("another creature");
|
||||
|
||||
static {
|
||||
filter.add(new AnotherPredicate());
|
||||
|
|
|
|||
|
|
@ -27,19 +27,19 @@
|
|||
*/
|
||||
package mage.cards.b;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DestroyAllEffect;
|
||||
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.TargetController;
|
||||
import mage.filter.common.FilterLandPermanent;
|
||||
import mage.filter.predicate.permanent.ControllerPredicate;
|
||||
import mage.target.TargetPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
public class BoomBust extends SplitCard {
|
||||
|
||||
private static final FilterLandPermanent filter1 = new FilterLandPermanent("land you control");
|
||||
|
|
@ -51,7 +51,7 @@ public class BoomBust extends SplitCard {
|
|||
}
|
||||
|
||||
public BoomBust(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{1}{R}","{5}{R}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{R}", "{5}{R}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Boom
|
||||
// Destroy target land you control and target land you don't control.
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.b;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.ContinuousRuleModifyingEffectImpl;
|
||||
|
|
@ -40,6 +41,7 @@ import mage.cards.SplitCard;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.filter.FilterSpell;
|
||||
|
|
@ -53,8 +55,6 @@ import mage.players.Player;
|
|||
import mage.target.common.TargetCardInYourGraveyard;
|
||||
import mage.target.common.TargetControlledPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
|
|
@ -68,7 +68,7 @@ public class BoundDetermined extends SplitCard {
|
|||
}
|
||||
|
||||
public BoundDetermined(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{3}{B}{G}","{G}{U}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{3}{B}{G}", "{G}{U}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Bound
|
||||
// Sacrifice a creature. Return up to X cards from your graveyard to your hand, where X is the number of colors that creature was. Exile this card.
|
||||
|
|
|
|||
|
|
@ -1,112 +1,116 @@
|
|||
/*
|
||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are
|
||||
* permitted provided that the following conditions are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
* conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
||||
* provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* The views and conclusions contained in the software and documentation are those of the
|
||||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
package mage.cards.b;
|
||||
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import java.util.UUID;
|
||||
import mage.Mana;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.BeginningOfPreCombatMainTriggeredAbility;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.TargetController;
|
||||
import mage.counters.CounterType;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.players.Player;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author jeffwadsworth
|
||||
*/
|
||||
public class BountyOfTheLuxa extends CardImpl {
|
||||
|
||||
public BountyOfTheLuxa(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{G}{U}");
|
||||
|
||||
//At the beginning of your precombat main phase, remove all flood counters from Bounty of the Luxa. If no flood counters were removed this way, put a flood counter on Bounty of the Luxa and draw a card. Otherwise, add {C}{G}{U} to your mana pool.
|
||||
this.addAbility(new BeginningOfPreCombatMainTriggeredAbility(new BountyOfTheLuxaEffect(), TargetController.YOU, false));
|
||||
|
||||
}
|
||||
|
||||
public BountyOfTheLuxa(final BountyOfTheLuxa card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BountyOfTheLuxa copy() {
|
||||
return new BountyOfTheLuxa(this);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
class BountyOfTheLuxaEffect extends OneShotEffect {
|
||||
|
||||
public BountyOfTheLuxaEffect() {
|
||||
super(Outcome.Benefit);
|
||||
staticText = "remove all flood counters from {this}. If no flood counters were removed this way, put a flood counter on {this} and draw a card. Otherwise, add {C}{G}{U} to your mana pool";
|
||||
}
|
||||
|
||||
public BountyOfTheLuxaEffect(final BountyOfTheLuxaEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BountyOfTheLuxaEffect copy() {
|
||||
return new BountyOfTheLuxaEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
Permanent bountyOfLuxa = game.getPermanent(source.getSourceId());
|
||||
if (controller != null
|
||||
&& bountyOfLuxa != null) {
|
||||
if (bountyOfLuxa.getCounters(game).getCount(CounterType.FLOOD) > 0) {
|
||||
bountyOfLuxa.removeCounters(CounterType.FLOOD.createInstance(bountyOfLuxa.getCounters(game).getCount(CounterType.FLOOD)), game);
|
||||
if (bountyOfLuxa.getCounters(game).getCount(CounterType.FLOOD) == 0) {
|
||||
Mana manaToAdd = new Mana();
|
||||
manaToAdd.increaseColorless();
|
||||
manaToAdd.increaseGreen();
|
||||
manaToAdd.increaseBlue();
|
||||
controller.getManaPool().addMana(manaToAdd, game, source);
|
||||
}
|
||||
} else {
|
||||
new AddCountersSourceEffect(CounterType.FLOOD.createInstance()).apply(game, source);
|
||||
new DrawCardSourceControllerEffect(1).apply(game, source);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
/*
|
||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are
|
||||
* permitted provided that the following conditions are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
* conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
||||
* provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* The views and conclusions contained in the software and documentation are those of the
|
||||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
package mage.cards.b;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.Mana;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.BeginningOfPreCombatMainTriggeredAbility;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.TargetController;
|
||||
import mage.counters.CounterType;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.players.Player;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author jeffwadsworth
|
||||
*/
|
||||
public class BountyOfTheLuxa extends CardImpl {
|
||||
|
||||
public BountyOfTheLuxa(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{G}{U}");
|
||||
|
||||
//At the beginning of your precombat main phase, remove all flood counters from Bounty of the Luxa. If no counters were removed this way, put a flood counter on Bounty of the Luxa and draw a card. Otherwise, add {C}{G}{U} to your mana pool.
|
||||
this.addAbility(new BeginningOfPreCombatMainTriggeredAbility(new BountyOfTheLuxaEffect(), TargetController.YOU, false));
|
||||
|
||||
}
|
||||
|
||||
public BountyOfTheLuxa(final BountyOfTheLuxa card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BountyOfTheLuxa copy() {
|
||||
return new BountyOfTheLuxa(this);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
class BountyOfTheLuxaEffect extends OneShotEffect {
|
||||
|
||||
public BountyOfTheLuxaEffect() {
|
||||
super(Outcome.Benefit);
|
||||
staticText = "remove all flood counters from {this}. If no counters were removed this way, put a flood counter on {this} and draw a card. Otherwise, add {C}{G}{U} to your mana pool";
|
||||
}
|
||||
|
||||
public BountyOfTheLuxaEffect(final BountyOfTheLuxaEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BountyOfTheLuxaEffect copy() {
|
||||
return new BountyOfTheLuxaEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
Permanent bountyOfLuxa = game.getPermanent(source.getSourceId());
|
||||
if (bountyOfLuxa != null && bountyOfLuxa.getZoneChangeCounter(game) != source.getSourceObjectZoneChangeCounter()) {
|
||||
bountyOfLuxa = null;
|
||||
}
|
||||
if (controller != null) {
|
||||
if (bountyOfLuxa != null
|
||||
&& bountyOfLuxa.getCounters(game).getCount(CounterType.FLOOD) > 0) {
|
||||
bountyOfLuxa.removeCounters(CounterType.FLOOD.createInstance(bountyOfLuxa.getCounters(game).getCount(CounterType.FLOOD)), game);
|
||||
if (bountyOfLuxa.getCounters(game).getCount(CounterType.FLOOD) == 0) {
|
||||
Mana manaToAdd = new Mana();
|
||||
manaToAdd.increaseColorless();
|
||||
manaToAdd.increaseGreen();
|
||||
manaToAdd.increaseBlue();
|
||||
controller.getManaPool().addMana(manaToAdd, game, source);
|
||||
}
|
||||
} else {
|
||||
if (bountyOfLuxa != null) {
|
||||
new AddCountersSourceEffect(CounterType.FLOOD.createInstance()).apply(game, source);
|
||||
}
|
||||
controller.drawCards(1, game);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.b;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.ContinuousEffect;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
|
|
@ -39,6 +40,7 @@ import mage.cards.SplitCard;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.game.Game;
|
||||
|
|
@ -48,12 +50,10 @@ import mage.target.TargetPlayer;
|
|||
import mage.target.common.TargetCardInGraveyard;
|
||||
import mage.target.targetpointer.FixedTarget;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
public class BreakingEntering extends SplitCard {
|
||||
|
||||
public BreakingEntering(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{U}{B}","{4}{B}{R}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{U}{B}", "{4}{B}{R}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Breaking
|
||||
// Target player puts the top eight cards of his or her library into his or her graveyard.
|
||||
|
|
|
|||
|
|
@ -27,6 +27,9 @@
|
|||
*/
|
||||
package mage.cards.c;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
|
|
@ -39,6 +42,7 @@ import mage.cards.SplitCard;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.FilterPermanent;
|
||||
import mage.filter.common.*;
|
||||
import mage.game.Game;
|
||||
|
|
@ -48,14 +52,10 @@ import mage.target.Target;
|
|||
import mage.target.TargetPermanent;
|
||||
import mage.target.common.TargetControlledPermanent;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
|
||||
public class CatchRelease extends SplitCard {
|
||||
|
||||
public CatchRelease(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{1}{U}{R}","{4}{R}{W}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{U}{R}", "{4}{R}{W}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Catch
|
||||
// Gain control of target permanent until end of turn. Untap it. It gains haste until end of turn.
|
||||
|
|
|
|||
|
|
@ -45,12 +45,6 @@ import mage.filter.predicate.permanent.AnotherPredicate;
|
|||
*/
|
||||
public class CombatCelebrant extends CardImpl {
|
||||
|
||||
private final static FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("other creatures you control");
|
||||
|
||||
static {
|
||||
filter.add(new AnotherPredicate());
|
||||
}
|
||||
|
||||
public CombatCelebrant(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{R}");
|
||||
|
||||
|
|
@ -60,7 +54,7 @@ public class CombatCelebrant extends CardImpl {
|
|||
this.toughness = new MageInt(1);
|
||||
|
||||
// If Combat Celebrant hasn't been exerted this turn, you may exert it as it attacks. When you do, untap all other creatures you control and after this phase, there is an additional combat phase.
|
||||
BecomesExertSourceTriggeredAbility ability = new BecomesExertSourceTriggeredAbility(new UntapAllControllerEffect(filter));
|
||||
BecomesExertSourceTriggeredAbility ability = new BecomesExertSourceTriggeredAbility(new UntapAllControllerEffect(new FilterControlledCreaturePermanent(), null, false));
|
||||
ability.addEffect(new AdditionalCombatPhaseEffect("and after this phase, there is an additional combat phase"));
|
||||
this.addAbility(new ExertAbility(ability, true));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -39,6 +39,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterSpellOrPermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
|
|
@ -62,7 +63,7 @@ public class CommitMemory extends SplitCard {
|
|||
}
|
||||
|
||||
public CommitMemory(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{3}{U}", "{4}{U}{U}", false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{3}{U}", "{4}{U}{U}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Commit
|
||||
// Put target spell or nonland permanent into its owner's library second from the top.
|
||||
|
|
@ -72,7 +73,7 @@ public class CommitMemory extends SplitCard {
|
|||
// Memory
|
||||
// Aftermath
|
||||
// Each player shuffles his or her hand and graveyard into his or her library, then draws seven cards.
|
||||
((CardImpl)(getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
getRightHalfCard().getSpellAbility().addEffect(new MemoryEffect());
|
||||
Effect effect = new DrawCardAllEffect(7);
|
||||
effect.setText(", then draws seven cards");
|
||||
|
|
|
|||
|
|
@ -1,87 +1,90 @@
|
|||
/*
|
||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are
|
||||
* permitted provided that the following conditions are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
* conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
||||
* provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* The views and conclusions contained in the software and documentation are those of the
|
||||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.costs.common.SacrificeSourceCost;
|
||||
import mage.abilities.costs.mana.GenericManaCost;
|
||||
import mage.abilities.effects.common.AttachEffect;
|
||||
import mage.abilities.effects.common.GainLifeEffect;
|
||||
import mage.abilities.effects.common.combat.CantAttackBlockAttachedEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect;
|
||||
import mage.constants.Outcome;
|
||||
import mage.target.TargetPermanent;
|
||||
import mage.abilities.keyword.EnchantAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.AttachmentType;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Zone;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author Styxo
|
||||
*/
|
||||
public class CompulsoryRest extends CardImpl {
|
||||
|
||||
public CompulsoryRest(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}");
|
||||
|
||||
this.subtype.add("Aura");
|
||||
|
||||
// Enchant creature
|
||||
TargetPermanent auraTarget = new TargetCreaturePermanent();
|
||||
this.getSpellAbility().addTarget(auraTarget);
|
||||
this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature));
|
||||
Ability ability = new EnchantAbility(auraTarget.getTargetName());
|
||||
this.addAbility(ability);
|
||||
|
||||
// Enchanted creature can't attack or block.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackBlockAttachedEffect(AttachmentType.AURA)));
|
||||
|
||||
// Enchanted creature has "{2}, Sacrifice this creature: You gain 2 life."
|
||||
Ability grantedAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(2), new GenericManaCost(2));
|
||||
grantedAbility.addCost(new SacrificeSourceCost());
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(grantedAbility, AttachmentType.AURA, Duration.WhileOnBattlefield)));
|
||||
|
||||
}
|
||||
|
||||
public CompulsoryRest(final CompulsoryRest card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public CompulsoryRest copy() {
|
||||
return new CompulsoryRest(this);
|
||||
}
|
||||
}
|
||||
/*
|
||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are
|
||||
* permitted provided that the following conditions are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
* conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
||||
* provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* The views and conclusions contained in the software and documentation are those of the
|
||||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.costs.Cost;
|
||||
import mage.abilities.costs.common.SacrificeSourceCost;
|
||||
import mage.abilities.costs.mana.GenericManaCost;
|
||||
import mage.abilities.effects.common.AttachEffect;
|
||||
import mage.abilities.effects.common.GainLifeEffect;
|
||||
import mage.abilities.effects.common.combat.CantAttackBlockAttachedEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect;
|
||||
import mage.constants.Outcome;
|
||||
import mage.target.TargetPermanent;
|
||||
import mage.abilities.keyword.EnchantAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.AttachmentType;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Zone;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author Styxo
|
||||
*/
|
||||
public class CompulsoryRest extends CardImpl {
|
||||
|
||||
public CompulsoryRest(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}");
|
||||
|
||||
this.subtype.add("Aura");
|
||||
|
||||
// Enchant creature
|
||||
TargetPermanent auraTarget = new TargetCreaturePermanent();
|
||||
this.getSpellAbility().addTarget(auraTarget);
|
||||
this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature));
|
||||
Ability ability = new EnchantAbility(auraTarget.getTargetName());
|
||||
this.addAbility(ability);
|
||||
|
||||
// Enchanted creature can't attack or block.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackBlockAttachedEffect(AttachmentType.AURA)));
|
||||
|
||||
// Enchanted creature has "{2}, Sacrifice this creature: You gain 2 life."
|
||||
Ability grantedAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(2), new GenericManaCost(2));
|
||||
Cost cost = new SacrificeSourceCost();
|
||||
cost.setText("Sacrifice this creature");
|
||||
grantedAbility.addCost(cost);
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(grantedAbility, AttachmentType.AURA, Duration.WhileOnBattlefield)));
|
||||
|
||||
}
|
||||
|
||||
public CompulsoryRest(final CompulsoryRest card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public CompulsoryRest copy() {
|
||||
return new CompulsoryRest(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect;
|
||||
|
|
@ -35,6 +35,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.mageobject.CardTypePredicate;
|
||||
|
|
@ -42,20 +43,17 @@ import mage.game.Game;
|
|||
import mage.game.permanent.Permanent;
|
||||
import mage.target.common.TargetCardInOpponentsGraveyard;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
|
||||
|
||||
public class CrimePunishment extends SplitCard {
|
||||
|
||||
|
||||
private static final FilterCard filter = new FilterCard("creature or enchantment card from an opponent's graveyard");
|
||||
|
||||
static {
|
||||
filter.add(Predicates.or(new CardTypePredicate(CardType.CREATURE),
|
||||
new CardTypePredicate(CardType.ENCHANTMENT)));
|
||||
new CardTypePredicate(CardType.ENCHANTMENT)));
|
||||
}
|
||||
|
||||
public CrimePunishment(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{3}{W}{B}","{X}{B}{G}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{W}{B}", "{X}{B}{G}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Crime
|
||||
// Put target creature or enchantment card from an opponent's graveyard onto the battlefield under your control.
|
||||
|
|
@ -79,29 +77,29 @@ public class CrimePunishment extends SplitCard {
|
|||
}
|
||||
|
||||
class PunishmentEffect extends OneShotEffect {
|
||||
|
||||
|
||||
PunishmentEffect() {
|
||||
super(Outcome.DestroyPermanent);
|
||||
this.staticText = "Destroy each artifact, creature, and enchantment with converted mana cost X";
|
||||
}
|
||||
|
||||
|
||||
PunishmentEffect(final PunishmentEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public PunishmentEffect copy() {
|
||||
return new PunishmentEffect(this);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
for (Permanent permanent : game.getBattlefield().getActivePermanents(source.getControllerId(), game)) {
|
||||
if (permanent != null
|
||||
&& permanent.getConvertedManaCost() == source.getManaCostsToPay().getX()
|
||||
&& (permanent.isArtifact()
|
||||
|| permanent.isCreature()
|
||||
|| permanent.isEnchantment())) {
|
||||
|| permanent.isCreature()
|
||||
|| permanent.isEnchantment())) {
|
||||
permanent.destroy(source.getSourceId(), game, false);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
|
|
@ -44,8 +45,6 @@ import mage.game.permanent.Permanent;
|
|||
import mage.target.common.TargetCreaturePermanent;
|
||||
import mage.util.functions.ApplyToPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author Loki
|
||||
*/
|
||||
|
|
@ -58,7 +57,7 @@ public class Cryptoplasm extends CardImpl {
|
|||
}
|
||||
|
||||
public Cryptoplasm(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{1}{U}{U}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{U}{U}");
|
||||
this.subtype.add("Shapeshifter");
|
||||
|
||||
this.power = new MageInt(2);
|
||||
|
|
@ -103,7 +102,7 @@ class CryptoplasmEffect extends OneShotEffect {
|
|||
if (creatureToCopy != null) {
|
||||
ApplyToPermanent applier = new ApplyToPermanent() {
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
Ability upkeepAbility = new BeginningOfUpkeepTriggeredAbility(new CryptoplasmEffect(), TargetController.YOU, true);
|
||||
upkeepAbility.addTarget(new TargetCreaturePermanent());
|
||||
permanent.addAbility(upkeepAbility, source.getSourceId(), game);
|
||||
|
|
@ -111,7 +110,7 @@ class CryptoplasmEffect extends OneShotEffect {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
Ability upkeepAbility = new BeginningOfUpkeepTriggeredAbility(new CryptoplasmEffect(), TargetController.YOU, true);
|
||||
upkeepAbility.addTarget(new TargetCreaturePermanent());
|
||||
mageObject.getAbilities().add(upkeepAbility);
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.dynamicvalue.common.ManacostVariableValue;
|
||||
import mage.abilities.effects.common.DamageTargetEffect;
|
||||
import mage.abilities.effects.common.LoseLifeOpponentsEffect;
|
||||
|
|
@ -8,17 +9,16 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author Stravant
|
||||
*/
|
||||
public class CutRibbons extends SplitCard {
|
||||
|
||||
public CutRibbons(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{R}", "{X}{B}{B}", false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, new CardType[]{CardType.SORCERY}, "{1}{R}", "{X}{B}{B}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Cut
|
||||
// Cut deals 4 damage to target creature.
|
||||
|
|
@ -26,7 +26,6 @@ public class CutRibbons extends SplitCard {
|
|||
getLeftHalfCard().getSpellAbility().addEffect(new DamageTargetEffect(4));
|
||||
|
||||
// to
|
||||
|
||||
// Ribbons
|
||||
// Each opponent loses X life.
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
|
|
|
|||
|
|
@ -27,8 +27,10 @@
|
|||
*/
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.EntersBattlefieldAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CopyPermanentEffect;
|
||||
|
|
@ -42,8 +44,6 @@ import mage.game.Game;
|
|||
import mage.game.permanent.Permanent;
|
||||
import mage.util.functions.ApplyToPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
|
|
@ -51,7 +51,7 @@ import java.util.UUID;
|
|||
public class DacksDuplicate extends CardImpl {
|
||||
|
||||
public DacksDuplicate(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{2}{U}{R}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{U}{R}");
|
||||
this.subtype.add("Shapeshifter");
|
||||
|
||||
this.power = new MageInt(0);
|
||||
|
|
@ -76,7 +76,7 @@ public class DacksDuplicate extends CardImpl {
|
|||
class DacksDuplicateApplyToPermanent extends ApplyToPermanent {
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
/**
|
||||
* 29/05/2014 The ability of Dack’s Duplicate doesn’t target the
|
||||
* creature.
|
||||
|
|
@ -87,7 +87,7 @@ class DacksDuplicateApplyToPermanent extends ApplyToPermanent {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
mageObject.getAbilities().add(new DethroneAbility());
|
||||
mageObject.getAbilities().add(HasteAbility.getInstance());
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -1,30 +1,31 @@
|
|||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.common.DamageTargetEffect;
|
||||
import mage.abilities.effects.common.ReturnToHandTargetEffect;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.TargetController;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.permanent.ControllerPredicate;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author dustinconrad
|
||||
*/
|
||||
public class DeadGone extends SplitCard {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature you don't control");
|
||||
|
||||
static {
|
||||
filter.add(new ControllerPredicate(TargetController.NOT_YOU));
|
||||
}
|
||||
|
||||
public DeadGone(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{R}","{2}{R}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{R}", "{2}{R}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Dead
|
||||
// Dead deals 2 damage to target creature.
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ public class Decompose extends CardImpl {
|
|||
|
||||
// Exile up to three target cards from a single graveyard.
|
||||
this.getSpellAbility().addEffect(new ExileTargetEffect());
|
||||
this.getSpellAbility().addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("cards")));
|
||||
this.getSpellAbility().addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("cards from a single graveyard")));
|
||||
}
|
||||
|
||||
public Decompose(final Decompose card) {
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.combat.MustBeBlockedByAllTargetEffect;
|
||||
import mage.abilities.effects.common.continuous.BoostTargetEffect;
|
||||
|
|
@ -39,20 +39,13 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author stravant
|
||||
*/
|
||||
|
||||
|
||||
public class DestinedLead extends SplitCard {
|
||||
|
||||
public DestinedLead(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY},"{1}{B}","{3}{G}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{1}{B}", "{3}{G}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Destined
|
||||
// Target creature gets +1/+0 and gains indestructible until end of turn.
|
||||
|
|
@ -66,10 +59,9 @@ public class DestinedLead extends SplitCard {
|
|||
getLeftHalfCard().getSpellAbility().addEffect(effect);
|
||||
|
||||
// to
|
||||
|
||||
// Lead
|
||||
// All creatures able to block target creature this turn must do so.
|
||||
((CardImpl)(getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
getRightHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
getRightHalfCard().getSpellAbility().addEffect(new MustBeBlockedByAllTargetEffect(Duration.EndOfTurn));
|
||||
}
|
||||
|
|
@ -83,4 +75,3 @@ public class DestinedLead extends SplitCard {
|
|||
return new DestinedLead(this);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,78 +1,81 @@
|
|||
/*
|
||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are
|
||||
* permitted provided that the following conditions are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
* conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
||||
* provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* The views and conclusions contained in the software and documentation are those of the
|
||||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.common.BecomesExertSourceTriggeredAbility;
|
||||
import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect;
|
||||
import mage.abilities.keyword.ExertAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.ComparisonType;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.filter.predicate.mageobject.ConvertedManaCostPredicate;
|
||||
import mage.target.common.TargetCardInYourGraveyard;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author Styxo
|
||||
*/
|
||||
public class DevotedCropMate extends CardImpl {
|
||||
|
||||
private static final FilterCreatureCard filter = new FilterCreatureCard("creature card with converted mana cost 2 or less from your graveyard");
|
||||
|
||||
static {
|
||||
filter.add(new ConvertedManaCostPredicate(ComparisonType.FEWER_THAN, 3));
|
||||
}
|
||||
|
||||
public DevotedCropMate(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}");
|
||||
|
||||
this.subtype.add("Human");
|
||||
this.subtype.add("Warrior");
|
||||
this.power = new MageInt(3);
|
||||
this.toughness = new MageInt(2);
|
||||
|
||||
// You may exert Devoted Crop-Mate as it attacks. When you do, return target creature card with converted mana cost 2 or less from your graveyard to the battlefield.
|
||||
BecomesExertSourceTriggeredAbility ability = new BecomesExertSourceTriggeredAbility(new ReturnFromGraveyardToBattlefieldTargetEffect());
|
||||
ability.addTarget(new TargetCardInYourGraveyard(filter));
|
||||
addAbility(new ExertAbility(ability));
|
||||
|
||||
}
|
||||
|
||||
public DevotedCropMate(final DevotedCropMate card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DevotedCropMate copy() {
|
||||
return new DevotedCropMate(this);
|
||||
}
|
||||
}
|
||||
/*
|
||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are
|
||||
* permitted provided that the following conditions are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
* conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
||||
* provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* The views and conclusions contained in the software and documentation are those of the
|
||||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.common.BecomesExertSourceTriggeredAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect;
|
||||
import mage.abilities.keyword.ExertAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.ComparisonType;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.filter.predicate.mageobject.ConvertedManaCostPredicate;
|
||||
import mage.target.common.TargetCardInYourGraveyard;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author Styxo
|
||||
*/
|
||||
public class DevotedCropMate extends CardImpl {
|
||||
|
||||
private static final FilterCreatureCard filter = new FilterCreatureCard("creature card with converted mana cost 2 or less from your graveyard");
|
||||
|
||||
static {
|
||||
filter.add(new ConvertedManaCostPredicate(ComparisonType.FEWER_THAN, 3));
|
||||
}
|
||||
|
||||
public DevotedCropMate(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}");
|
||||
|
||||
this.subtype.add("Human");
|
||||
this.subtype.add("Warrior");
|
||||
this.power = new MageInt(3);
|
||||
this.toughness = new MageInt(2);
|
||||
|
||||
// You may exert Devoted Crop-Mate as it attacks. When you do, return target creature card with converted mana cost 2 or less from your graveyard to the battlefield.
|
||||
Effect effect = new ReturnFromGraveyardToBattlefieldTargetEffect();
|
||||
effect.setText("return target creature card with converted mana cost 2 or less from your graveyard to the battlefield");
|
||||
BecomesExertSourceTriggeredAbility ability = new BecomesExertSourceTriggeredAbility(effect);
|
||||
ability.addTarget(new TargetCardInYourGraveyard(filter));
|
||||
addAbility(new ExertAbility(ability));
|
||||
|
||||
}
|
||||
|
||||
public DevotedCropMate(final DevotedCropMate card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DevotedCropMate copy() {
|
||||
return new DevotedCropMate(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
|
|
@ -47,8 +48,6 @@ import mage.players.Player;
|
|||
import mage.target.common.TargetCardInGraveyard;
|
||||
import mage.util.functions.ApplyToPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author jeffwadsworth
|
||||
|
|
@ -110,7 +109,7 @@ class DimirDoppelgangerEffect extends OneShotEffect {
|
|||
newBluePrint = new PermanentCard((Card) copyFromCard, source.getControllerId(), game);
|
||||
newBluePrint.assignNewId();
|
||||
ApplyToPermanent applier = new DimirDoppelgangerApplier();
|
||||
applier.apply(game, newBluePrint);
|
||||
applier.apply(game, newBluePrint, source, dimirDoppelganger.getId());
|
||||
CopyEffect copyEffect = new CopyEffect(Duration.Custom, newBluePrint, dimirDoppelganger.getId());
|
||||
copyEffect.newId();
|
||||
copyEffect.setApplier(applier);
|
||||
|
|
@ -127,7 +126,7 @@ class DimirDoppelgangerEffect extends OneShotEffect {
|
|||
class DimirDoppelgangerApplier extends ApplyToPermanent {
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DimirDoppelgangerEffect(), new ManaCostsImpl("{1}{U}{B}"));
|
||||
ability.addTarget(new TargetCardInGraveyard(new FilterCreatureCard("creature card in a graveyard")));
|
||||
permanent.getAbilities().add(ability);
|
||||
|
|
@ -135,7 +134,7 @@ class DimirDoppelgangerApplier extends ApplyToPermanent {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DimirDoppelgangerEffect(), new ManaCostsImpl("{1}{U}{B}"));
|
||||
ability.addTarget(new TargetCardInGraveyard(new FilterCreatureCard("creature card in a graveyard")));
|
||||
mageObject.getAbilities().add(ability);
|
||||
|
|
|
|||
|
|
@ -25,29 +25,22 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.common.ReturnFromGraveyardToHandTargetEffect;
|
||||
import mage.abilities.effects.common.discard.DiscardTargetEffect;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.TargetPlayer;
|
||||
import mage.target.common.TargetCardInYourGraveyard;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class DownDirty extends SplitCard {
|
||||
|
||||
public DownDirty(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{3}{B}","{2}{G}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{B}", "{2}{G}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Down
|
||||
// Target player discards two cards.
|
||||
|
|
|
|||
|
|
@ -25,11 +25,11 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.Set;
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.constants.ComparisonType;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.DestroyAllEffect;
|
||||
|
|
@ -39,7 +39,9 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.ComparisonType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
|
|
@ -48,23 +50,16 @@ import mage.filter.predicate.mageobject.PowerPredicate;
|
|||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
|
||||
import java.util.Set;
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author stravant
|
||||
*/
|
||||
|
||||
|
||||
public class DuskDawn extends SplitCard {
|
||||
|
||||
private static final FilterCreaturePermanent filterCreatures3orGreater = new FilterCreaturePermanent("creatures with power greater than or equal to 3");
|
||||
|
||||
static {
|
||||
filterCreatures3orGreater.add(new PowerPredicate(ComparisonType.MORE_THAN, 2));
|
||||
}
|
||||
|
||||
public DuskDawn(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{2}{W}{W}","{3}{W}{W}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, new CardType[]{CardType.SORCERY}, "{2}{W}{W}", "{3}{W}{W}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Dusk
|
||||
// Destroy all creatures with power 3 or greater.
|
||||
|
|
@ -74,7 +69,7 @@ public class DuskDawn extends SplitCard {
|
|||
|
||||
// Dawn
|
||||
// Return all creature cards with power less than or equal to 2 from your graveyard to your hand.
|
||||
((CardImpl)(getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
getRightHalfCard().getSpellAbility().addEffect(new DawnEffect());
|
||||
|
||||
}
|
||||
|
|
@ -92,6 +87,7 @@ public class DuskDawn extends SplitCard {
|
|||
class DawnEffect extends OneShotEffect {
|
||||
|
||||
private static final FilterCard filter2orLess = new FilterCreatureCard("creatures with power less than or equal to 2");
|
||||
|
||||
static {
|
||||
filter2orLess.add(new PowerPredicate(ComparisonType.FEWER_THAN, 3));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@ import mage.abilities.common.SimpleStaticAbility;
|
|||
import mage.abilities.dynamicvalue.common.CardsInControllerGraveyardCount;
|
||||
import mage.abilities.effects.common.continuous.SetPowerSourceEffect;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.abilities.keyword.TrampleAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
|
|
@ -59,7 +58,7 @@ public class EnigmaDrake extends CardImpl {
|
|||
|
||||
// Enigma Drakes's power is equal to the number of instant and sorcery cards in your graveyard.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.ALL, new SetPowerSourceEffect(
|
||||
new CardsInControllerGraveyardCount(new FilterInstantOrSorceryCard("instant and sorcery cards in your graveyard")), Duration.EndOfGame)));
|
||||
new CardsInControllerGraveyardCount(new FilterInstantOrSorceryCard("instant and sorcery cards")), Duration.EndOfGame)));
|
||||
}
|
||||
|
||||
public EnigmaDrake(final EnigmaDrake card) {
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.e;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
|
|
@ -49,8 +50,6 @@ import mage.game.permanent.Permanent;
|
|||
import mage.target.common.TargetCreaturePermanent;
|
||||
import mage.util.functions.ApplyToPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author BetaSteward
|
||||
|
|
@ -58,7 +57,7 @@ import java.util.UUID;
|
|||
public class EvilTwin extends CardImpl {
|
||||
|
||||
public EvilTwin(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{2}{U}{B}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{U}{B}");
|
||||
this.subtype.add("Shapeshifter");
|
||||
|
||||
this.power = new MageInt(0);
|
||||
|
|
@ -90,7 +89,7 @@ class EvilTwinApplyToPermanent extends ApplyToPermanent {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new ManaCostsImpl("{U}{B}"));
|
||||
ability.addCost(new TapSourceCost());
|
||||
ability.addTarget(new TargetCreaturePermanent(filter));
|
||||
|
|
@ -99,7 +98,7 @@ class EvilTwinApplyToPermanent extends ApplyToPermanent {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new ManaCostsImpl("{U}{B}"));
|
||||
ability.addCost(new TapSourceCost());
|
||||
ability.addTarget(new TargetCreaturePermanent(filter));
|
||||
|
|
|
|||
|
|
@ -29,22 +29,18 @@ package mage.cards.f;
|
|||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.Mode;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.costs.common.DiscardSourceCost;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.game.Game;
|
||||
import mage.target.common.TargetCardInGraveyard;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.common.ExileTargetEffect;
|
||||
|
||||
/**
|
||||
*
|
||||
|
|
@ -53,7 +49,7 @@ import java.util.UUID;
|
|||
public class FaerieMacabre extends CardImpl {
|
||||
|
||||
public FaerieMacabre(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{1}{B}{B}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{B}{B}");
|
||||
this.subtype.add("Faerie");
|
||||
this.subtype.add("Rogue");
|
||||
|
||||
|
|
@ -63,7 +59,7 @@ public class FaerieMacabre extends CardImpl {
|
|||
// Flying
|
||||
this.addAbility(FlyingAbility.getInstance());
|
||||
// Discard Faerie Macabre: Exile up to two target cards from graveyards.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.HAND, new FaerieMacabreExileTargetEffect(), new DiscardSourceCost());
|
||||
Ability ability = new SimpleActivatedAbility(Zone.HAND, new ExileTargetEffect(), new DiscardSourceCost());
|
||||
ability.addTarget(new TargetCardInGraveyard(0, 2, new FilterCard("cards from graveyards")));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
@ -77,35 +73,3 @@ public class FaerieMacabre extends CardImpl {
|
|||
return new FaerieMacabre(this);
|
||||
}
|
||||
}
|
||||
|
||||
class FaerieMacabreExileTargetEffect extends OneShotEffect {
|
||||
|
||||
public FaerieMacabreExileTargetEffect() {
|
||||
super(Outcome.Exile);
|
||||
}
|
||||
|
||||
public FaerieMacabreExileTargetEffect(final FaerieMacabreExileTargetEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public FaerieMacabreExileTargetEffect copy() {
|
||||
return new FaerieMacabreExileTargetEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
for(UUID uuid : source.getTargets().get(0).getTargets()){
|
||||
Card card = game.getCard(uuid);
|
||||
if (card != null) {
|
||||
card.moveToExile(null, "Faerie Macabre", source.getSourceId(), game);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getText(Mode mode) {
|
||||
return "Exile up to two target cards from graveyards";
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,7 +27,13 @@
|
|||
*/
|
||||
package mage.cards.f;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.ContinuousRuleModifyingEffectImpl;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.NameACardEffect;
|
||||
import mage.abilities.effects.common.ReturnToHandTargetEffect;
|
||||
import mage.abilities.keyword.AftermathAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
|
|
@ -35,16 +41,11 @@ import mage.cards.SplitCard;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
import mage.target.TargetSpell;
|
||||
import mage.abilities.effects.common.ReturnToHandTargetEffect;
|
||||
import mage.abilities.effects.ContinuousRuleModifyingEffectImpl;
|
||||
import mage.MageObject;
|
||||
import mage.game.events.GameEvent.EventType;
|
||||
import mage.abilities.effects.common.NameACardEffect;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.target.TargetSpell;
|
||||
|
||||
/**
|
||||
* @author spjspj
|
||||
|
|
@ -52,7 +53,7 @@ import java.util.UUID;
|
|||
public class FailureComply extends SplitCard {
|
||||
|
||||
public FailureComply(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{1}{U}", "{W}", false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{1}{U}", "{W}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Failure
|
||||
// Return target spell to it's owner's hand
|
||||
|
|
@ -63,7 +64,9 @@ public class FailureComply extends SplitCard {
|
|||
// Comply
|
||||
// Choose a card name. Until your next turn, your opponents can't cast spells with the chosen name
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
getRightHalfCard().getSpellAbility().addEffect(new NameACardEffect(NameACardEffect.TypeOfName.ALL));
|
||||
Effect effect = new NameACardEffect(NameACardEffect.TypeOfName.ALL);
|
||||
effect.setText("Choose a card name");
|
||||
getRightHalfCard().getSpellAbility().addEffect(effect);
|
||||
getRightHalfCard().getSpellAbility().addEffect(new ComplyCantCastEffect());
|
||||
}
|
||||
|
||||
|
|
@ -81,7 +84,7 @@ class ComplyCantCastEffect extends ContinuousRuleModifyingEffectImpl {
|
|||
|
||||
public ComplyCantCastEffect() {
|
||||
super(Duration.UntilYourNextTurn, Outcome.Benefit);
|
||||
staticText = "Your opponents can't cast spells with the chosen name";
|
||||
staticText = "Until your next turn, your opponents can't cast spells with the chosen name";
|
||||
}
|
||||
|
||||
public ComplyCantCastEffect(final ComplyCantCastEffect effect) {
|
||||
|
|
|
|||
|
|
@ -56,9 +56,9 @@ public class FamishedGhoul extends CardImpl {
|
|||
this.toughness = new MageInt(2);
|
||||
|
||||
// {1}{B}, Sacrifice Famished Ghoul: Exile up to two target cards from a single graveyard.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect("Exile up to two target cards from a single graveyard"), new ManaCostsImpl("{1}{B}"));
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(), new ManaCostsImpl("{1}{B}"));
|
||||
ability.addCost(new SacrificeSourceCost());
|
||||
ability.addTarget(new TargetCardInASingleGraveyard(0, 2, new FilterCard()));
|
||||
ability.addTarget(new TargetCardInASingleGraveyard(0, 2, new FilterCard("cards from a single graveyard")));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -25,30 +25,23 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.f;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.common.ReturnToHandTargetEffect;
|
||||
import mage.abilities.effects.common.SacrificeEffect;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.target.TargetPlayer;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class FarAway extends SplitCard {
|
||||
|
||||
public FarAway(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{U}","{2}{B}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{U}", "{2}{B}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Far
|
||||
// Return target creature to its owner's hand.
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.f;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||
|
|
@ -35,21 +35,14 @@ import mage.abilities.effects.common.TapTargetEffect;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.TargetPermanent;
|
||||
import mage.target.common.TargetCreatureOrPlayerAmount;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class FireIce extends SplitCard {
|
||||
|
||||
public FireIce(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{R}","{1}{U}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{R}", "{1}{U}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Fire
|
||||
// Fire deals 2 damage divided as you choose among one or two target creatures and/or players.
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.f;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.cards.Card;
|
||||
|
|
@ -35,6 +35,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.Zone;
|
||||
import mage.counters.CounterType;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
|
|
@ -47,18 +48,10 @@ import mage.target.common.TargetControlledCreaturePermanent;
|
|||
import mage.target.common.TargetCreatureOrPlayer;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class FleshBlood extends SplitCard {
|
||||
|
||||
public FleshBlood(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{3}{B}{G}","{R}{G}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{B}{G}", "{R}{G}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Flesh
|
||||
// Exile target creature card from a graveyard. Put X +1/+1 counters on target creature, where X is the power of the card you exiled.
|
||||
|
|
@ -90,7 +83,7 @@ class FleshEffect extends OneShotEffect {
|
|||
public FleshEffect() {
|
||||
super(Outcome.BoostCreature);
|
||||
staticText = "Exile target creature card from a graveyard. Put X +1/+1 counters on target creature, where X is the power of the card you exiled";
|
||||
}
|
||||
}
|
||||
|
||||
public FleshEffect(final FleshEffect effect) {
|
||||
super(effect);
|
||||
|
|
@ -125,7 +118,7 @@ class BloodEffect extends OneShotEffect {
|
|||
public BloodEffect() {
|
||||
super(Outcome.Damage);
|
||||
staticText = "Target creature you control deals damage equal to its power to target creature or player";
|
||||
}
|
||||
}
|
||||
|
||||
public BloodEffect(final BloodEffect effect) {
|
||||
super(effect);
|
||||
|
|
|
|||
160
Mage.Sets/src/mage/cards/g/GateToTheAfterlife.java
Normal file
160
Mage.Sets/src/mage/cards/g/GateToTheAfterlife.java
Normal file
|
|
@ -0,0 +1,160 @@
|
|||
/*
|
||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are
|
||||
* permitted provided that the following conditions are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
* conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
||||
* provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* The views and conclusions contained in the software and documentation are those of the
|
||||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
package mage.cards.g;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.EntersBattlefieldControlledTriggeredAbility;
|
||||
import mage.abilities.condition.common.CardsInControllerGraveCondition;
|
||||
import mage.abilities.costs.common.SacrificeSourceCost;
|
||||
import mage.abilities.costs.common.TapSourceCost;
|
||||
import mage.abilities.costs.mana.GenericManaCost;
|
||||
import mage.abilities.decorator.ConditionalActivatedAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.DrawDiscardControllerEffect;
|
||||
import mage.abilities.effects.common.GainLifeEffect;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.TargetController;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.mageobject.NamePredicate;
|
||||
import mage.filter.predicate.permanent.ControllerPredicate;
|
||||
import mage.filter.predicate.permanent.TokenPredicate;
|
||||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
import mage.target.common.TargetCardInHand;
|
||||
import mage.target.common.TargetCardInLibrary;
|
||||
import mage.target.common.TargetCardInYourGraveyard;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
public class GateToTheAfterlife extends CardImpl {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("a nontoken creature you control");
|
||||
|
||||
static {
|
||||
filter.add(new ControllerPredicate(TargetController.YOU));
|
||||
filter.add(Predicates.not(new TokenPredicate()));
|
||||
}
|
||||
|
||||
public GateToTheAfterlife(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{3}");
|
||||
|
||||
// Whenever a nontoken creature you control dies, you gain 1 life. Then you may draw a card. If you do, discard a card.
|
||||
Ability ability = new EntersBattlefieldControlledTriggeredAbility(Zone.BATTLEFIELD, new GainLifeEffect(1), filter, false);
|
||||
Effect effect = new DrawDiscardControllerEffect(1, 1, true);
|
||||
effect.setText("Then you may draw a card. If you do, discard a card");
|
||||
ability.addEffect(effect);
|
||||
this.addAbility(ability);
|
||||
|
||||
// {2}, {T}, Sacrifice Gate to the Afterlife: Search your graveyard, hand, and/or library for a card named God-Pharaoh's Gift and put it onto the battlefield. If you seearch your library this way, shuffle it. Activate this ability only if there are six or more creature cards in your graveyard.
|
||||
ability = new ConditionalActivatedAbility(Zone.BATTLEFIELD,
|
||||
new GateToTheAfterlifeEffect(), new GenericManaCost(2), new CardsInControllerGraveCondition(6, new FilterCreatureCard()));
|
||||
ability.addCost(new TapSourceCost());
|
||||
ability.addCost(new SacrificeSourceCost());
|
||||
ability.addEffect(effect);
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
public GateToTheAfterlife(final GateToTheAfterlife card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public GateToTheAfterlife copy() {
|
||||
return new GateToTheAfterlife(this);
|
||||
}
|
||||
}
|
||||
|
||||
class GateToTheAfterlifeEffect extends OneShotEffect {
|
||||
|
||||
static private String cardName = "God-Pharaoh's Gift";
|
||||
|
||||
public GateToTheAfterlifeEffect() {
|
||||
super(Outcome.Benefit);
|
||||
this.staticText = "Search your graveyard, hand, and/or library for a card named "
|
||||
+ cardName
|
||||
+ " and put it onto the battlefield. If you search your library this way, shuffle it";
|
||||
}
|
||||
|
||||
public GateToTheAfterlifeEffect(final GateToTheAfterlifeEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public GateToTheAfterlifeEffect copy() {
|
||||
return new GateToTheAfterlifeEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
if (controller == null) {
|
||||
return false;
|
||||
}
|
||||
FilterCard filter = new FilterCard("card named " + cardName);
|
||||
filter.add(new NamePredicate(cardName));
|
||||
Card card = null;
|
||||
// Graveyard check
|
||||
if (controller.chooseUse(Outcome.Benefit, "Do you want to search your graveyard for " + cardName + "?", source, game)) {
|
||||
TargetCardInYourGraveyard target = new TargetCardInYourGraveyard(filter);
|
||||
if (controller.choose(Outcome.PutCardInPlay, controller.getGraveyard(), target, game)) {
|
||||
card = game.getCard(target.getFirstTarget());
|
||||
}
|
||||
}
|
||||
// Hand check
|
||||
if (card == null && controller.chooseUse(Outcome.Benefit, "Do you want to search your hand for " + cardName + "?", source, game)) {
|
||||
TargetCardInHand target = new TargetCardInHand(filter);
|
||||
if (controller.choose(Outcome.PutCardInPlay, controller.getHand(), target, game)) {
|
||||
card = game.getCard(target.getFirstTarget());
|
||||
}
|
||||
}
|
||||
// Library check
|
||||
if (card == null && controller.chooseUse(Outcome.Benefit, "Do you want to search your library for " + cardName + "?", source, game)) {
|
||||
TargetCardInLibrary target = new TargetCardInLibrary(filter);
|
||||
if (controller.searchLibrary(target, game)) {
|
||||
card = game.getCard(target.getFirstTarget());
|
||||
}
|
||||
controller.shuffleLibrary(source, game);
|
||||
}
|
||||
if (card != null) {
|
||||
controller.moveCards(card, Zone.BATTLEFIELD, source, game);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
@ -34,8 +34,6 @@ import mage.abilities.Ability;
|
|||
import mage.abilities.LoyaltyAbility;
|
||||
import mage.abilities.common.PlanswalkerEntersWithLoyalityCountersAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.dynamicvalue.common.StaticValue;
|
||||
import mage.abilities.effects.ContinuousEffect;
|
||||
import mage.abilities.effects.ContinuousRuleModifyingEffectImpl;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.GetEmblemEffect;
|
||||
|
|
@ -48,7 +46,6 @@ import mage.cards.CardSetInfo;
|
|||
import mage.constants.*;
|
||||
import mage.filter.common.FilterPlaneswalkerPermanent;
|
||||
import mage.filter.predicate.mageobject.SubtypePredicate;
|
||||
import mage.filter.predicate.permanent.ControllerPredicate;
|
||||
import mage.game.Game;
|
||||
import mage.game.command.Emblem;
|
||||
import mage.game.events.GameEvent;
|
||||
|
|
@ -63,20 +60,22 @@ public class GideonOfTheTrials extends CardImpl {
|
|||
|
||||
public GideonOfTheTrials(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.PLANESWALKER}, "{1}{W}{W}");
|
||||
|
||||
|
||||
this.subtype.add("Gideon");
|
||||
|
||||
//Starting Loyalty: 3
|
||||
this.addAbility(new PlanswalkerEntersWithLoyalityCountersAbility(3));
|
||||
|
||||
// +1: Until your next turn, prevent all damage target permanent would deal.
|
||||
LoyaltyAbility ability = new LoyaltyAbility(new PreventDamageByTargetEffect(Duration.UntilYourNextTurn), 1);
|
||||
Effect effect = new PreventDamageByTargetEffect(Duration.UntilYourNextTurn);
|
||||
effect.setText("Until your next turn, prevent all damage target permanent would deal");
|
||||
LoyaltyAbility ability = new LoyaltyAbility(effect, 1);
|
||||
ability.addTarget(new TargetPermanent());
|
||||
this.addAbility(ability);
|
||||
|
||||
// 0: Until end of turn, Gideon of the Trials becomes a 4/4 Human Soldier creature with indestructible that's still a planeswalker. Prevent all damage that would be dealt to him this turn.
|
||||
ability = new LoyaltyAbility(new BecomesCreatureSourceEffect(new GideonOfTheTrialsToken(), "planeswalker", Duration.EndOfTurn), 0);
|
||||
Effect effect = new PreventAllDamageToSourceEffect(Duration.EndOfTurn);
|
||||
effect = new PreventAllDamageToSourceEffect(Duration.EndOfTurn);
|
||||
effect.setText("Prevent all damage that would be dealt to him this turn");
|
||||
ability.addEffect(effect);
|
||||
this.addAbility(ability);
|
||||
|
|
@ -106,7 +105,7 @@ class GideonOfTheTrialsCantLoseEffect extends ContinuousRuleModifyingEffectImpl
|
|||
|
||||
public GideonOfTheTrialsCantLoseEffect() {
|
||||
super(Duration.EndOfGame, Outcome.Benefit);
|
||||
staticText = "As long as you control a Gideon planeswalker, you can't lose the game and your opponent can't win the game";
|
||||
staticText = "As long as you control a Gideon planeswalker, you can't lose the game and your opponents can't win the game";
|
||||
}
|
||||
|
||||
public GideonOfTheTrialsCantLoseEffect(final GideonOfTheTrialsCantLoseEffect effect) {
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ import mage.abilities.Ability;
|
|||
import mage.abilities.common.AsEntersBattlefieldAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.effects.ContinuousRuleModifyingEffectImpl;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.PreventionEffectImpl;
|
||||
import mage.abilities.effects.common.NameACardEffect;
|
||||
import mage.cards.CardImpl;
|
||||
|
|
@ -56,7 +57,9 @@ public class GideonsIntervention extends CardImpl {
|
|||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}{W}");
|
||||
|
||||
// As Gideon's Intervention enters the battlefield, choose a card name.
|
||||
this.addAbility(new AsEntersBattlefieldAbility(new NameACardEffect(NameACardEffect.TypeOfName.ALL)));
|
||||
Effect effect = new NameACardEffect(NameACardEffect.TypeOfName.ALL);
|
||||
effect.setText("choose a card name");
|
||||
this.addAbility(new AsEntersBattlefieldAbility(effect));
|
||||
|
||||
// Your opponents can't cast spells with the chosen name.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GideonsInterventionCantCastEffect()));
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.g;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
|
|
@ -49,8 +50,6 @@ import mage.game.Game;
|
|||
import mage.game.permanent.Permanent;
|
||||
import mage.util.functions.ApplyToPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author fireshoes
|
||||
|
|
@ -58,7 +57,7 @@ import java.util.UUID;
|
|||
public class Gigantoplasm extends CardImpl {
|
||||
|
||||
public Gigantoplasm(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{U}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{U}");
|
||||
this.subtype.add("Shapeshifter");
|
||||
this.power = new MageInt(0);
|
||||
this.toughness = new MageInt(0);
|
||||
|
|
@ -82,7 +81,7 @@ public class Gigantoplasm extends CardImpl {
|
|||
class GigantoplasmApplyToPermanent extends ApplyToPermanent {
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
DynamicValue variableMana = new ManacostVariableValue();
|
||||
Effect effect = new SetPowerToughnessSourceEffect(variableMana, Duration.WhileOnBattlefield, SubLayer.SetPT_7b);
|
||||
effect.setText("This creature has base power and toughness X/X");
|
||||
|
|
@ -92,7 +91,7 @@ class GigantoplasmApplyToPermanent extends ApplyToPermanent {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
DynamicValue variableMana = new ManacostVariableValue();
|
||||
Effect effect = new SetPowerToughnessSourceEffect(variableMana, Duration.WhileOnBattlefield, SubLayer.SetPT_7b);
|
||||
effect.setText("This creature has base power and toughness X/X");
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
*/
|
||||
package mage.cards.g;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.counter.AddCountersTargetEffect;
|
||||
|
|
@ -34,6 +35,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.counters.CounterType;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
|
|
@ -41,8 +43,6 @@ import mage.players.Player;
|
|||
import mage.target.common.TargetControlledCreaturePermanent;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
|
|
@ -50,7 +50,7 @@ import java.util.UUID;
|
|||
public class GiveTake extends SplitCard {
|
||||
|
||||
public GiveTake(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{2}{G}","{2}{U}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{2}{G}", "{2}{U}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Give
|
||||
// Put three +1/+1 counters on target creature.
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@ import mage.target.targetpointer.FixedTarget;
|
|||
public class HarshMentor extends CardImpl {
|
||||
|
||||
public HarshMentor(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "1{R}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{R}");
|
||||
|
||||
this.subtype.add("Human");
|
||||
this.subtype.add("Cleric");
|
||||
|
|
|
|||
|
|
@ -30,18 +30,27 @@ package mage.cards.h;
|
|||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.costs.common.SacrificeTargetCost;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.dynamicvalue.common.SacrificeCostCreaturesPower;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.DamageTargetEffect;
|
||||
import mage.abilities.effects.common.DoIfCostPaid;
|
||||
import mage.abilities.effects.common.InfoEffect;
|
||||
import mage.abilities.effects.common.SendOptionUsedEventEffect;
|
||||
import mage.abilities.keyword.EmbalmAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterControlledCreaturePermanent;
|
||||
import mage.filter.predicate.permanent.AnotherPredicate;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
import mage.game.events.GameEvent.EventType;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.players.Player;
|
||||
import mage.target.Target;
|
||||
import mage.target.common.TargetControlledCreaturePermanent;
|
||||
import mage.target.common.TargetCreatureOrPlayer;
|
||||
|
||||
|
|
@ -51,12 +60,6 @@ import mage.target.common.TargetCreatureOrPlayer;
|
|||
*/
|
||||
public class HeartPiercerManticore extends CardImpl {
|
||||
|
||||
private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("another creature");
|
||||
|
||||
static {
|
||||
filter.add(new AnotherPredicate());
|
||||
}
|
||||
|
||||
public HeartPiercerManticore(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{R}{R}");
|
||||
|
||||
|
|
@ -65,12 +68,12 @@ public class HeartPiercerManticore extends CardImpl {
|
|||
this.toughness = new MageInt(3);
|
||||
|
||||
// When Heart-Piercer Manticore enters the battlefield, you may sacrifice another creature.
|
||||
Ability firstAbility = new EntersBattlefieldTriggeredAbility(new HeartPiercerManticoreSacrificeEffect(), true);
|
||||
this.addAbility(firstAbility);
|
||||
// When you do, Heart-Piercer Manticore deals damage equal to that creature's power to target creature or player.
|
||||
Ability ability = new EntersBattlefieldTriggeredAbility(new DoIfCostPaid(new DamageTargetEffect(new SacrificeCostCreaturesPower()),
|
||||
new SacrificeTargetCost(new TargetControlledCreaturePermanent(filter))), true);
|
||||
ability.addTarget(new TargetCreatureOrPlayer());
|
||||
this.addAbility(ability);
|
||||
|
||||
Ability secondAbility = new HeartPiercerManticoreSacrificeTriggeredAbility(firstAbility.getOriginalId());
|
||||
secondAbility.addTarget(new TargetCreatureOrPlayer());
|
||||
this.addAbility(secondAbility);
|
||||
// Embalm {5}{R}
|
||||
this.addAbility(new EmbalmAbility(new ManaCostsImpl("{5}{R}"), this));
|
||||
|
||||
|
|
@ -85,3 +88,85 @@ public class HeartPiercerManticore extends CardImpl {
|
|||
return new HeartPiercerManticore(this);
|
||||
}
|
||||
}
|
||||
|
||||
class HeartPiercerManticoreSacrificeEffect extends OneShotEffect {
|
||||
|
||||
private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("another creature");
|
||||
|
||||
static {
|
||||
filter.add(new AnotherPredicate());
|
||||
}
|
||||
|
||||
public HeartPiercerManticoreSacrificeEffect() {
|
||||
super(Outcome.Damage);
|
||||
this.staticText = "you may sacrifice another creature";
|
||||
}
|
||||
|
||||
public HeartPiercerManticoreSacrificeEffect(final HeartPiercerManticoreSacrificeEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public HeartPiercerManticoreSacrificeEffect copy() {
|
||||
return new HeartPiercerManticoreSacrificeEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
if (controller != null) {
|
||||
Target target = new TargetControlledCreaturePermanent(1, 1, filter, true);
|
||||
if (controller.choose(outcome, target, source.getSourceId(), game)) {
|
||||
Permanent toSacrifice = game.getPermanent(target.getFirstTarget());
|
||||
if (toSacrifice != null) {
|
||||
toSacrifice.sacrifice(source.getSourceId(), game);
|
||||
return new SendOptionUsedEventEffect(toSacrifice.getPower().getValue()).apply(game, source);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
class HeartPiercerManticoreSacrificeTriggeredAbility extends TriggeredAbilityImpl {
|
||||
|
||||
private final UUID relatedTriggerdAbilityOriginalId;
|
||||
|
||||
public HeartPiercerManticoreSacrificeTriggeredAbility(UUID relatedTriggerdAbilityOriginalId) {
|
||||
super(Zone.BATTLEFIELD, new InfoEffect("{this} deals damage equal to that creature's power to target creature or player"));
|
||||
this.relatedTriggerdAbilityOriginalId = relatedTriggerdAbilityOriginalId;
|
||||
}
|
||||
|
||||
public HeartPiercerManticoreSacrificeTriggeredAbility(final HeartPiercerManticoreSacrificeTriggeredAbility ability) {
|
||||
super(ability);
|
||||
this.relatedTriggerdAbilityOriginalId = ability.relatedTriggerdAbilityOriginalId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HeartPiercerManticoreSacrificeTriggeredAbility copy() {
|
||||
return new HeartPiercerManticoreSacrificeTriggeredAbility(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checkEventType(GameEvent event, Game game) {
|
||||
return event.getType() == EventType.OPTION_USED;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
if (event.getPlayerId().equals(this.getControllerId())
|
||||
&& event.getTargetId().equals(relatedTriggerdAbilityOriginalId)
|
||||
&& event.getSourceId().equals(getSourceId())) {
|
||||
getEffects().clear();
|
||||
getEffects().add(new DamageTargetEffect(event.getAmount()));
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getRule() {
|
||||
return "When you do, {this} deals damage equal to that creature's power to target creature or player.";
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.mageobject.AbilityPredicate;
|
||||
|
|
@ -28,7 +29,7 @@ public class HeavenEarth extends SplitCard {
|
|||
}
|
||||
|
||||
public HeavenEarth(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{X}{G}", "{X}{R}{R}", false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{X}{G}", "{X}{R}{R}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Falling
|
||||
// Falling deals X damage to each creature with flying.
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.h;
|
||||
|
||||
import java.util.UUID;
|
||||
|
|
@ -37,6 +36,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterArtifactOrEnchantmentPermanent;
|
||||
import mage.game.Game;
|
||||
|
|
@ -52,7 +52,7 @@ import mage.target.common.TargetOpponent;
|
|||
public class HideSeek extends SplitCard {
|
||||
|
||||
public HideSeek(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{R}{W}","{W}{B}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{R}{W}", "{W}{B}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Hide
|
||||
// Put target artifact or enchantment on the bottom of its owner's library.
|
||||
|
|
|
|||
|
|
@ -37,6 +37,7 @@ import mage.cards.SplitCard;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterAttackingCreature;
|
||||
import mage.filter.common.FilterControlledPermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
|
|
@ -55,7 +56,7 @@ import mage.target.targetpointer.FixedTarget;
|
|||
public class HitRun extends SplitCard {
|
||||
|
||||
public HitRun(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{B}{R}","{3}{R}{G}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{B}{R}", "{3}{R}{G}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Hit
|
||||
// Target player sacrifices an artifact or creature. Hit deals damage to that player equal to that permanent's converted mana cost.
|
||||
|
|
|
|||
|
|
@ -52,8 +52,7 @@ public class HoodedBrawler extends CardImpl {
|
|||
this.toughness = new MageInt(2);
|
||||
|
||||
// You may exert Hooded Brawler as it attacks. When you do, it gets +2/+2 until end of turn.
|
||||
BecomesExertSourceTriggeredAbility ability = new BecomesExertSourceTriggeredAbility(new BoostSourceEffect(2, 2, Duration.EndOfTurn));
|
||||
this.addAbility(new ExertAbility(ability));
|
||||
this.addAbility(new ExertAbility(new BecomesExertSourceTriggeredAbility(new BoostSourceEffect(2, 2, Duration.EndOfTurn))));
|
||||
}
|
||||
|
||||
public HoodedBrawler(final HoodedBrawler card) {
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.Target;
|
||||
import mage.target.common.TargetArtifactPermanent;
|
||||
import mage.target.common.TargetSpellOrPermanent;
|
||||
|
|
@ -42,11 +43,10 @@ import mage.target.common.TargetSpellOrPermanent;
|
|||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
public class IllusionReality extends SplitCard {
|
||||
|
||||
public IllusionReality(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{U}","{2}{G}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{U}", "{2}{G}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Illusion
|
||||
// Target spell or permanent becomes the color of your choice until end of turn.
|
||||
|
|
|
|||
|
|
@ -1,10 +1,9 @@
|
|||
package mage.cards.i;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.dynamicvalue.common.ManacostVariableValue;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.ReplacementEffectImpl;
|
||||
import mage.abilities.effects.common.LoseLifeOpponentsEffect;
|
||||
import mage.abilities.effects.common.continuous.DamageCantBePreventedEffect;
|
||||
import mage.abilities.keyword.AftermathAbility;
|
||||
import mage.cards.CardImpl;
|
||||
|
|
@ -13,9 +12,7 @@ import mage.cards.SplitCard;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.filter.Filter;
|
||||
import mage.filter.common.FilterControlledCreaturePermanent;
|
||||
import mage.filter.predicate.mageobject.PowerPredicate;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
import mage.game.permanent.Permanent;
|
||||
|
|
@ -23,14 +20,13 @@ import mage.players.Player;
|
|||
import mage.target.TargetPlayer;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author Stravant
|
||||
*/
|
||||
public class InsultInjury extends SplitCard {
|
||||
|
||||
public InsultInjury(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{2}{R}","{2}{R}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, new CardType[]{CardType.SORCERY}, "{2}{R}", "{2}{R}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Insult
|
||||
// Damage can't be prevented this turn. If a source you control would deal damage this turn it deals
|
||||
|
|
@ -39,7 +35,6 @@ public class InsultInjury extends SplitCard {
|
|||
getLeftHalfCard().getSpellAbility().addEffect(new InsultDoubleDamageEffect());
|
||||
|
||||
// to
|
||||
|
||||
// Injury
|
||||
// Injury deals 2 damage to target creature and 2 damage to target player.
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
|
|
@ -59,6 +54,7 @@ public class InsultInjury extends SplitCard {
|
|||
}
|
||||
|
||||
class InsultDoubleDamageEffect extends ReplacementEffectImpl {
|
||||
|
||||
public InsultDoubleDamageEffect() {
|
||||
super(Duration.EndOfTurn, Outcome.Damage);
|
||||
staticText = "If a source you control would deal damage this turn, it deals double that damage to that creature or player instead.";
|
||||
|
|
@ -98,6 +94,7 @@ class InsultDoubleDamageEffect extends ReplacementEffectImpl {
|
|||
}
|
||||
|
||||
class InjuryEffect extends OneShotEffect {
|
||||
|
||||
InjuryEffect() {
|
||||
super(Outcome.Damage);
|
||||
this.staticText = "{this} deals 2 damage to target creature and 2 damage to target player";
|
||||
|
|
@ -127,4 +124,4 @@ class InjuryEffect extends OneShotEffect {
|
|||
public InjuryEffect copy() {
|
||||
return new InjuryEffect(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -109,7 +109,7 @@ class LazavDimirMastermindEffect extends OneShotEffect {
|
|||
newBluePrint = new PermanentCard((Card) copyFromCard, source.getControllerId(), game);
|
||||
newBluePrint.assignNewId();
|
||||
ApplyToPermanent applier = new LazavDimirMastermindApplier();
|
||||
applier.apply(game, newBluePrint);
|
||||
applier.apply(game, newBluePrint, source, lazavDimirMastermind.getId());
|
||||
CopyEffect copyEffect = new CopyEffect(Duration.Custom, newBluePrint, lazavDimirMastermind.getId());
|
||||
copyEffect.newId();
|
||||
copyEffect.setApplier(applier);
|
||||
|
|
@ -126,7 +126,7 @@ class LazavDimirMastermindEffect extends OneShotEffect {
|
|||
class LazavDimirMastermindApplier extends ApplyToPermanent {
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
Ability ability = new PutCardIntoGraveFromAnywhereAllTriggeredAbility(
|
||||
new LazavDimirMastermindEffect(), true,
|
||||
new FilterCreatureCard("a creature card"),
|
||||
|
|
@ -139,7 +139,7 @@ class LazavDimirMastermindApplier extends ApplyToPermanent {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
Ability ability = new PutCardIntoGraveFromAnywhereAllTriggeredAbility(
|
||||
new LazavDimirMastermindEffect(), true,
|
||||
new FilterCreatureCard("a creature card"),
|
||||
|
|
|
|||
|
|
@ -38,6 +38,7 @@ import mage.cards.SplitCard;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterControlledLandPermanent;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
|
|
@ -54,7 +55,7 @@ import mage.target.common.TargetCardInYourGraveyard;
|
|||
public class LifeDeath extends SplitCard {
|
||||
|
||||
public LifeDeath(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{G}","{1}{B}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{G}", "{1}{B}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Life
|
||||
// All lands you control become 1/1 creatures until end of turn. They're still lands.
|
||||
|
|
|
|||
|
|
@ -53,20 +53,27 @@ public class ManticoreOfTheGauntlet extends CardImpl {
|
|||
|
||||
public ManticoreOfTheGauntlet(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{4}{R}");
|
||||
|
||||
|
||||
this.subtype.add("Manticore");
|
||||
this.power = new MageInt(5);
|
||||
this.toughness = new MageInt(4);
|
||||
|
||||
// When Manticore of the Gauntlet enters the battlefield, put a -1/-1 counter on target creature you control. Manticore of the Gauntlet deals 3 damage to target opponent.
|
||||
Effect counters = new AddCountersTargetEffect(CounterType.M1M1.createInstance(), new StaticValue(1));
|
||||
Effect counters = new AddCountersTargetEffect(CounterType.M1M1.createInstance());
|
||||
counters.setText("put a -1/-1 counter on target creature you control");
|
||||
counters.setTargetPointer(new FirstTargetPointer());
|
||||
Ability ability = new EntersBattlefieldTriggeredAbility(counters);
|
||||
|
||||
Effect damage = new DamageTargetEffect(new StaticValue(3), true, "", true);
|
||||
damage.setText("{this} deals 3 damage to target opponent.");
|
||||
damage.setTargetPointer(new SecondTargetPointer());
|
||||
|
||||
Ability ability = new EntersBattlefieldTriggeredAbility(counters);
|
||||
ability.addEffect(damage);
|
||||
|
||||
ability.addTarget(new TargetControlledCreaturePermanent());
|
||||
ability.addTarget(new TargetOpponent());
|
||||
addAbility(ability);
|
||||
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
public ManticoreOfTheGauntlet(final ManticoreOfTheGauntlet card) {
|
||||
|
|
@ -77,4 +84,4 @@ public class ManticoreOfTheGauntlet extends CardImpl {
|
|||
public ManticoreOfTheGauntlet copy() {
|
||||
return new ManticoreOfTheGauntlet(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -69,7 +69,9 @@ public class MercilessJavelineer extends CardImpl {
|
|||
new StaticValue(1),
|
||||
Outcome.Removal),
|
||||
new ManaCostsImpl("{2}"));
|
||||
ability.addEffect(new CantBlockTargetEffect(Duration.EndOfTurn));
|
||||
ability.addEffect(
|
||||
new CantBlockTargetEffect(Duration.EndOfTurn)
|
||||
.setText("That creature can't block this turn."));
|
||||
ability.addCost(new DiscardCardCost());
|
||||
ability.addTarget(new TargetCreaturePermanent());
|
||||
addAbility(ability);
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
package mage.cards.m;
|
||||
|
||||
import mage.constants.ComparisonType;
|
||||
import java.util.UUID;
|
||||
import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
|
|
@ -10,35 +10,36 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.ComparisonType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterControlledCreaturePermanent;
|
||||
import mage.filter.predicate.mageobject.PowerPredicate;
|
||||
import mage.game.permanent.token.HippoToken2;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author Stravant
|
||||
*/
|
||||
public class MouthFeed extends SplitCard {
|
||||
|
||||
private static final FilterControlledCreaturePermanent filterCreaturesYouControlPower3orGreater
|
||||
= new FilterControlledCreaturePermanent("creature you control with power 3 or greater.");
|
||||
|
||||
static {
|
||||
filterCreaturesYouControlPower3orGreater.add(new PowerPredicate(ComparisonType.MORE_THAN, 2));
|
||||
}
|
||||
|
||||
public MouthFeed(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{2}{G}","{3}{G}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, new CardType[]{CardType.SORCERY}, "{2}{G}", "{3}{G}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Mouth
|
||||
// Create a 3/3 green Hippo creature token
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new CreateTokenEffect(new HippoToken2()));
|
||||
|
||||
// to
|
||||
|
||||
// Feed
|
||||
// Draw a card for each creature you control with power 3 or greater
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
Effect draw = new DrawCardSourceControllerEffect(new PermanentsOnBattlefieldCount(filterCreaturesYouControlPower3orGreater));
|
||||
Effect draw = new DrawCardSourceControllerEffect(new PermanentsOnBattlefieldCount(filterCreaturesYouControlPower3orGreater));
|
||||
getRightHalfCard().getSpellAbility().addEffect(draw);
|
||||
|
||||
}
|
||||
|
|
@ -51,4 +52,4 @@ public class MouthFeed extends SplitCard {
|
|||
public MouthFeed copy() {
|
||||
return new MouthFeed(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,8 +29,9 @@ package mage.cards.n;
|
|||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.common.EntersBattlefieldAbility;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.dynamicvalue.common.StaticValue;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.LookLibraryAndPickControllerEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
|
|
@ -46,15 +47,15 @@ public class NagaOracle extends CardImpl {
|
|||
|
||||
public NagaOracle(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{U}");
|
||||
|
||||
|
||||
this.subtype.add("Naga");
|
||||
this.subtype.add("Cleric");
|
||||
this.power = new MageInt(2);
|
||||
this.toughness = new MageInt(4);
|
||||
|
||||
// When Naga Oracle enters the battlefield, look at the top three cards of your library. Put any number of them into your graveyard and the rest back on top of your library in any order.
|
||||
addAbility(new EntersBattlefieldAbility(
|
||||
new LookLibraryAndPickControllerEffect(
|
||||
// When Naga Oracle enters the battlefield, look at the top three cards of your library. Put any number of them into your graveyard
|
||||
// and the rest back on top of your library in any order.
|
||||
Effect effect = new LookLibraryAndPickControllerEffect(
|
||||
/* oh god, Microsoft looks conservative with their function parameters in comparison */
|
||||
new StaticValue(3),
|
||||
false,
|
||||
|
|
@ -65,7 +66,10 @@ public class NagaOracle extends CardImpl {
|
|||
false,
|
||||
true,
|
||||
Zone.GRAVEYARD,
|
||||
false)));
|
||||
false);
|
||||
effect.setText("look at the top three cards of your library. Put any number of them into your graveyard "
|
||||
+ "and the rest back on top of your library in any order");
|
||||
addAbility(new EntersBattlefieldTriggeredAbility(effect));
|
||||
}
|
||||
|
||||
public NagaOracle(final NagaOracle card) {
|
||||
|
|
|
|||
|
|
@ -29,10 +29,14 @@ package mage.cards.n;
|
|||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.common.BecomesExertSourceTriggeredAbility;
|
||||
import mage.abilities.effects.common.continuous.BoostSourceEffect;
|
||||
import mage.abilities.keyword.ExertAbility;
|
||||
import mage.abilities.keyword.TrampleAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
|
||||
/**
|
||||
*
|
||||
|
|
@ -42,7 +46,7 @@ public class NefCropEntangler extends CardImpl {
|
|||
|
||||
public NefCropEntangler(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{R}");
|
||||
|
||||
|
||||
this.subtype.add("Human");
|
||||
this.subtype.add("Warrior");
|
||||
this.power = new MageInt(2);
|
||||
|
|
@ -52,6 +56,7 @@ public class NefCropEntangler extends CardImpl {
|
|||
this.addAbility(TrampleAbility.getInstance());
|
||||
|
||||
// You may exert Nef-Crop Entangler as it attacks. When you do, it gets +1/+2 until end of turn.
|
||||
this.addAbility(new ExertAbility(new BecomesExertSourceTriggeredAbility(new BoostSourceEffect(1, 2, Duration.EndOfTurn))));
|
||||
}
|
||||
|
||||
public NefCropEntangler(final NefCropEntangler card) {
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ public class NehebTheWorthy extends CardImpl {
|
|||
// As long as you have one or fewer cards in hand, Minotaurs you control get +2/+0.
|
||||
Condition condition = new CardsInHandCondition(ComparisonType.FEWER_THAN, 2);
|
||||
Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect(
|
||||
new BoostControlledEffect(2, 0, Duration.WhileOnBattlefield, filter), condition, "As long as you have one or fewer cards in hand, Minotaurs you control gets +2/+0"));
|
||||
new BoostControlledEffect(2, 0, Duration.WhileOnBattlefield, filter), condition, "As long as you have one or fewer cards in hand, Minotaurs you control get +2/+0"));
|
||||
this.addAbility(ability);
|
||||
|
||||
// Whenever Neheb, the Worthy deals combat damage to a player, each player discards a card.
|
||||
|
|
|
|||
|
|
@ -36,6 +36,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.game.permanent.token.ZombieToken;
|
||||
import mage.target.common.TargetCardInGraveyard;
|
||||
import mage.target.common.TargetCreatureOrPlaneswalker;
|
||||
|
|
@ -47,7 +48,7 @@ import mage.target.common.TargetCreatureOrPlaneswalker;
|
|||
public class NeverReturn extends SplitCard {
|
||||
|
||||
public NeverReturn(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{B}{B}", "{3}{B}", false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, new CardType[]{CardType.SORCERY}, "{1}{B}{B}", "{3}{B}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Never
|
||||
// Destroy target creature or planeswalker.
|
||||
|
|
@ -56,7 +57,7 @@ public class NeverReturn extends SplitCard {
|
|||
|
||||
// Return
|
||||
// Exile target card from a graveyard. Create a 2/2 black Zombie creature token.
|
||||
((CardImpl)(getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
getRightHalfCard().getSpellAbility().addEffect(new ExileTargetEffect());
|
||||
getRightHalfCard().getSpellAbility().addTarget(new TargetCardInGraveyard());
|
||||
getRightHalfCard().getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken()));
|
||||
|
|
|
|||
127
Mage.Sets/src/mage/cards/n/NewPerspectives.java
Normal file
127
Mage.Sets/src/mage/cards/n/NewPerspectives.java
Normal file
|
|
@ -0,0 +1,127 @@
|
|||
/*
|
||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are
|
||||
* permitted provided that the following conditions are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
* conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
||||
* provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* The views and conclusions contained in the software and documentation are those of the
|
||||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
package mage.cards.n;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.condition.Condition;
|
||||
import mage.abilities.condition.common.CardsInHandCondition;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.decorator.ConditionalReplacementEffect;
|
||||
import mage.abilities.effects.ReplacementEffectImpl;
|
||||
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.ComparisonType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.Zone;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.CostEvent;
|
||||
import mage.game.events.GameEvent;
|
||||
import mage.game.events.GameEvent.EventType;
|
||||
import mage.players.Player;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
public class NewPerspectives extends CardImpl {
|
||||
|
||||
public NewPerspectives(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{5}{U}");
|
||||
|
||||
// When New Perspectives enters the battlefield, draw three cards.
|
||||
this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(3), false));
|
||||
|
||||
// As long as you have seven or more cards in hand, you may pay {0} rather than pay cycling costs.
|
||||
Condition condition = new CardsInHandCondition(ComparisonType.MORE_THAN, 6);
|
||||
Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD,
|
||||
new ConditionalReplacementEffect(
|
||||
new PerspectivesReplaceCylcingCosts(), condition));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
public NewPerspectives(final NewPerspectives card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NewPerspectives copy() {
|
||||
return new NewPerspectives(this);
|
||||
}
|
||||
}
|
||||
|
||||
class PerspectivesReplaceCylcingCosts extends ReplacementEffectImpl {
|
||||
|
||||
public PerspectivesReplaceCylcingCosts() {
|
||||
super(Duration.WhileOnBattlefield, Outcome.Benefit);
|
||||
staticText = "As long as you have seven or more cards in hand, you may pay {0} rather than pay cycling costs";
|
||||
}
|
||||
|
||||
public PerspectivesReplaceCylcingCosts(final PerspectivesReplaceCylcingCosts effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PerspectivesReplaceCylcingCosts copy() {
|
||||
return new PerspectivesReplaceCylcingCosts(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean replaceEvent(GameEvent event, Ability source, Game game) {
|
||||
if (event.getType() == EventType.CAN_PAY_CYCLE_COST) {
|
||||
((CostEvent) event).setCost(new ManaCostsImpl<>("{0}"));
|
||||
return false;
|
||||
}
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
if (controller != null && controller.chooseUse(outcome, "Pay {0} rather than normal cycling costs?", source, game)) {
|
||||
((CostEvent) event).setCost(new ManaCostsImpl<>("{0}"));
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checksEventType(GameEvent event, Game game) {
|
||||
return event.getType() == EventType.PAY_CYCLE_COST || event.getType() == EventType.CAN_PAY_CYCLE_COST;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean applies(GameEvent event, Ability source, Game game) {
|
||||
return event.getPlayerId().equals(source.getControllerId());
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -25,7 +25,6 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.n;
|
||||
|
||||
import java.util.Iterator;
|
||||
|
|
@ -35,12 +34,13 @@ import mage.MageObjectReference;
|
|||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.ContinuousEffectImpl;
|
||||
import mage.abilities.effects.common.continuous.BoostTargetEffect;
|
||||
import mage.constants.CardType;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Layer;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.SubLayer;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.game.Game;
|
||||
|
|
@ -52,15 +52,14 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
public class NightDay extends SplitCard {
|
||||
|
||||
public NightDay(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{B}","{2}{W}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{B}", "{2}{W}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Night
|
||||
// Target creature gets -1/-1 until end of turn.
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(-1,-1,Duration.EndOfTurn));
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(-1, -1, Duration.EndOfTurn));
|
||||
getLeftHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
|
||||
// Day
|
||||
|
|
|
|||
|
|
@ -53,6 +53,7 @@ import mage.players.Player;
|
|||
import mage.target.TargetPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
|
||||
/**
|
||||
*
|
||||
|
|
@ -65,7 +66,9 @@ public class NissaStewardOfElements extends CardImpl {
|
|||
|
||||
this.subtype.add("Nissa");
|
||||
|
||||
this.addAbility(new EntersBattlefieldAbility(new EntersBattlefieldWithXCountersEffect(CounterType.LOYALTY.createInstance())));
|
||||
Ability abilityETB = new EntersBattlefieldAbility(new EntersBattlefieldWithXCountersEffect(CounterType.LOYALTY.createInstance()));
|
||||
abilityETB.setRuleVisible(false);
|
||||
this.addAbility(abilityETB);
|
||||
|
||||
// +2: Scry 2.
|
||||
this.addAbility(new LoyaltyAbility(new ScryEffect(2), 2));
|
||||
|
|
@ -75,8 +78,12 @@ public class NissaStewardOfElements extends CardImpl {
|
|||
this.addAbility(new LoyaltyAbility(new NissaStewardOfElementsEffect(), 0));
|
||||
|
||||
// -6: Untap up to two target lands you control. They become 5/5 Elemental creatures with flying and haste until end of turn. They're still lands.
|
||||
LoyaltyAbility ability = new LoyaltyAbility(new UntapTargetEffect(), 6);
|
||||
ability.addEffect(new BecomesCreatureTargetEffect(new NissaStewardOfElementsToken(), false, true, Duration.EndOfTurn));
|
||||
Effect effect = new UntapTargetEffect();
|
||||
effect.setText("Untap up to two target lands you control");
|
||||
LoyaltyAbility ability = new LoyaltyAbility(effect, 6);
|
||||
effect = new BecomesCreatureTargetEffect(new NissaStewardOfElementsToken(), false, true, Duration.EndOfTurn);
|
||||
effect.setText("They become 5/5 Elemental creatures with flying and haste until end of turn. They're still lands");
|
||||
ability.addEffect(effect);
|
||||
ability.addTarget(new TargetPermanent(0, 2, new FilterControlledLandPermanent(), false));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
@ -95,7 +102,7 @@ class NissaStewardOfElementsEffect extends OneShotEffect {
|
|||
|
||||
public NissaStewardOfElementsEffect() {
|
||||
super(Outcome.PutCardInPlay);
|
||||
this.staticText = "look at the top card of your library. If it's a land card or a creature card with converted mana cost less than or equal"
|
||||
this.staticText = "look at the top card of your library. If it's a land card or a creature card with converted mana cost less than or equal "
|
||||
+ "to the number of loyalty counters on {this}, you may put that card onto the battlefield";
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -25,18 +25,18 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.o;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.CopyTargetSpellEffect;
|
||||
import mage.abilities.effects.common.SacrificeEffect;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.FilterSpell;
|
||||
import mage.filter.common.FilterAttackingCreature;
|
||||
import mage.filter.predicate.Predicates;
|
||||
|
|
@ -46,15 +46,10 @@ import mage.players.Player;
|
|||
import mage.target.TargetPlayer;
|
||||
import mage.target.TargetSpell;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class OddsEnds extends SplitCard {
|
||||
|
||||
private static final FilterSpell filter = new FilterSpell("instant or sorcery spell");
|
||||
|
||||
static {
|
||||
filter.add(Predicates.or(
|
||||
new CardTypePredicate(CardType.INSTANT),
|
||||
|
|
@ -62,7 +57,7 @@ public class OddsEnds extends SplitCard {
|
|||
}
|
||||
|
||||
public OddsEnds(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{U}{R}","{3}{R}{W}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{U}{R}", "{3}{R}{W}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Odds
|
||||
// Flip a coin. If it comes up heads, counter target instant or sorcery spell. If it comes up tails, copy that spell and you may choose new targets for the copy.
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.o;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.dynamicvalue.common.StaticValue;
|
||||
import mage.abilities.dynamicvalue.common.TargetPermanentPowerCount;
|
||||
import mage.abilities.effects.Effect;
|
||||
|
|
@ -40,20 +40,13 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author stravant
|
||||
*/
|
||||
|
||||
|
||||
public class OnwardVictory extends SplitCard {
|
||||
|
||||
public OnwardVictory(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY},"{2}{R}","{2}{W}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{2}{R}", "{2}{W}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Onward
|
||||
// Target creature gets +X/+0 until end of turn where X is its power.
|
||||
|
|
@ -61,10 +54,9 @@ public class OnwardVictory extends SplitCard {
|
|||
getLeftHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(new TargetPermanentPowerCount(), new StaticValue(0), Duration.EndOfTurn, true));
|
||||
|
||||
// to
|
||||
|
||||
// Victory
|
||||
// Target creature gains double strike until end of turn.
|
||||
((CardImpl)(getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
Effect effect = new GainAbilityTargetEffect(DoubleStrikeAbility.getInstance(), Duration.EndOfTurn);
|
||||
getRightHalfCard().getSpellAbility().addEffect(effect);
|
||||
getRightHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
|
|
@ -79,4 +71,3 @@ public class OnwardVictory extends SplitCard {
|
|||
return new OnwardVictory(this);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -25,30 +25,24 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.o;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.constants.CardType;
|
||||
import mage.abilities.effects.common.ExileTargetEffect;
|
||||
import mage.abilities.effects.common.combat.CantBlockAllEffect;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.target.Target;
|
||||
import mage.target.common.TargetAttackingCreature;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class OrderChaos extends SplitCard {
|
||||
|
||||
public OrderChaos(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{3}{W}","{2}{R}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{3}{W}", "{2}{R}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Order
|
||||
// Exile target attacking creature.
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ import mage.abilities.effects.common.discard.DiscardTargetEffect;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.TargetPlayer;
|
||||
import mage.target.common.TargetLandPermanent;
|
||||
|
||||
|
|
@ -43,13 +44,13 @@ import mage.target.common.TargetLandPermanent;
|
|||
public class PainSuffering extends SplitCard {
|
||||
|
||||
public PainSuffering(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{B}","{3}{R}",false);
|
||||
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{B}", "{3}{R}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Pain
|
||||
// Target player discards a card.
|
||||
this.getLeftHalfCard().getSpellAbility().addEffect(new DiscardTargetEffect(1));
|
||||
this.getLeftHalfCard().getSpellAbility().addTarget(new TargetPlayer());
|
||||
|
||||
|
||||
// Suffering
|
||||
// Destroy target land.
|
||||
this.getRightHalfCard().getSpellAbility().addEffect(new DestroyTargetEffect());
|
||||
|
|
|
|||
|
|
@ -48,14 +48,16 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
* @author stravant
|
||||
*/
|
||||
public class PathmakerInitiate extends CardImpl {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with power 2 or less");
|
||||
|
||||
static {
|
||||
filter.add(new PowerPredicate(ComparisonType.FEWER_THAN, 3));
|
||||
}
|
||||
|
||||
public PathmakerInitiate(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{R}");
|
||||
|
||||
|
||||
this.subtype.add("Human");
|
||||
this.subtype.add("Wizard");
|
||||
this.power = new MageInt(2);
|
||||
|
|
@ -64,6 +66,7 @@ public class PathmakerInitiate extends CardImpl {
|
|||
// {T}: Target creature with power 2 or less can't be blocked this turn.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CantBeBlockedTargetEffect(Duration.EndOfTurn), new TapSourceCost());
|
||||
ability.addTarget(new TargetCreaturePermanent(filter));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
public PathmakerInitiate(final PathmakerInitiate card) {
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ package mage.cards.p;
|
|||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.BecomesTargetTriggeredAbility;
|
||||
import mage.abilities.common.EntersBattlefieldAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
|
|
@ -53,7 +54,7 @@ public class PhantasmalImage extends CardImpl {
|
|||
|
||||
ApplyToPermanent phantasmalImageApplier = new ApplyToPermanent() {
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
if (!permanent.getSubtype(game).contains("Illusion")) {
|
||||
permanent.getSubtype(game).add("Illusion");
|
||||
}
|
||||
|
|
@ -64,7 +65,7 @@ public class PhantasmalImage extends CardImpl {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
if (!mageObject.getSubtype(game).contains("Illusion")) {
|
||||
mageObject.getSubtype(game).add("Illusion");
|
||||
}
|
||||
|
|
@ -76,7 +77,7 @@ public class PhantasmalImage extends CardImpl {
|
|||
};
|
||||
|
||||
public PhantasmalImage(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{1}{U}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{U}");
|
||||
this.subtype.add("Illusion");
|
||||
|
||||
this.color.setBlue(true);
|
||||
|
|
|
|||
|
|
@ -69,12 +69,12 @@ public class PhyrexianMetamorph extends CardImpl {
|
|||
|
||||
ApplyToPermanent phyrexianMetamorphApplier = new ApplyToPermanent() {
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
return apply(game, (MageObject) permanent);
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
return apply(game, (MageObject) permanent, source, copyToObjectId);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
if (!mageObject.isArtifact()) {
|
||||
mageObject.addCardType(CardType.ARTIFACT);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -25,56 +25,41 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.p;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.condition.common.OpponentControlsPermanentCondition;
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.*;
|
||||
import mage.abilities.effects.common.combat.MustBeBlockedByAllTargetEffect;
|
||||
import mage.abilities.effects.common.continuous.BoostTargetEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityTargetEffect;
|
||||
import mage.abilities.keyword.AftermathAbility;
|
||||
import mage.abilities.keyword.IndestructibleAbility;
|
||||
import mage.abilities.keyword.LifelinkAbility;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.*;
|
||||
import mage.filter.Filter;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.mageobject.PowerPredicate;
|
||||
import mage.filter.predicate.permanent.ControllerPredicate;
|
||||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
import mage.target.Target;
|
||||
import mage.target.common.TargetControlledCreaturePermanent;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.Set;
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author stravant
|
||||
*/
|
||||
public class PrepareFight extends SplitCard {
|
||||
|
||||
|
||||
public class PreparedFight extends SplitCard {
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature you don't control");
|
||||
|
||||
static {
|
||||
filter.add(new ControllerPredicate(TargetController.NOT_YOU));
|
||||
}
|
||||
|
||||
public PreparedFight(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY},"{1}{W}","{3}{G}",false);
|
||||
public PrepareFight(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{1}{W}", "{3}{G}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Prepared
|
||||
// Prepare
|
||||
// Untap target creature. It gets +2/+2 and gains lifelink until end of turn.
|
||||
getLeftHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
Effect effect = new UntapTargetEffect();
|
||||
|
|
@ -88,22 +73,21 @@ public class PreparedFight extends SplitCard {
|
|||
getLeftHalfCard().getSpellAbility().addEffect(effect);
|
||||
|
||||
// to
|
||||
|
||||
// Fight
|
||||
// Target creature you control fights target creature you don't control.
|
||||
((CardImpl)(getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
getRightHalfCard().getSpellAbility().addEffect(new FightTargetsEffect());
|
||||
getRightHalfCard().getSpellAbility().addTarget(new TargetControlledCreaturePermanent());
|
||||
Target target = new TargetCreaturePermanent(filter);
|
||||
getRightHalfCard().getSpellAbility().addTarget(target);
|
||||
}
|
||||
|
||||
public PreparedFight(final PreparedFight card) {
|
||||
public PrepareFight(final PrepareFight card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PreparedFight copy() {
|
||||
return new PreparedFight(this);
|
||||
public PrepareFight copy() {
|
||||
return new PrepareFight(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -25,40 +25,34 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.p;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.abilities.effects.common.continuous.BoostAllEffect;
|
||||
import mage.abilities.effects.common.continuous.BoostControlledEffect;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.TargetController;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.permanent.ControllerPredicate;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class ProfitLoss extends SplitCard {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Creatures your opponents control");
|
||||
|
||||
static {
|
||||
filter.add(new ControllerPredicate(TargetController.OPPONENT));
|
||||
}
|
||||
|
||||
public ProfitLoss(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{W}","{2}{B}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{W}", "{2}{B}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Profit
|
||||
// Creatures you control get +1/+1 until end of turn.
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new BoostControlledEffect(1,1, Duration.EndOfTurn, new FilterCreaturePermanent()));
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new BoostControlledEffect(1, 1, Duration.EndOfTurn, new FilterCreaturePermanent()));
|
||||
|
||||
// Loss
|
||||
// Creatures your opponents control get -1/-1 until end of turn.
|
||||
|
|
|
|||
|
|
@ -25,36 +25,30 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.p;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.abilities.effects.common.continuous.BoostTargetEffect;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
|
||||
public class ProtectServe extends SplitCard {
|
||||
|
||||
public ProtectServe(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{2}{W}","{1}{U}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{2}{W}", "{1}{U}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Protect
|
||||
// Target creature gets +2/+4 until end of turn.
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(2,4, Duration.EndOfTurn));
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(2, 4, Duration.EndOfTurn));
|
||||
getLeftHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
|
||||
// Serve
|
||||
// Target creature gets -6/-0 until end of turn.
|
||||
getRightHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(-6,0, Duration.EndOfTurn));
|
||||
getRightHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(-6, 0, Duration.EndOfTurn));
|
||||
getRightHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ import mage.abilities.effects.common.DestroyTargetEffect;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.FilterPermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.mageobject.MulticoloredPredicate;
|
||||
|
|
@ -54,7 +55,7 @@ public class PureSimple extends SplitCard {
|
|||
}
|
||||
|
||||
public PureSimple(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{1}{R}{G}","{1}{G}{W}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{R}{G}", "{1}{G}{W}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Pure
|
||||
// Destroy target multicolored permanent.
|
||||
|
|
|
|||
|
|
@ -35,22 +35,19 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.filter.common.FilterAttackingCreature;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author stravant
|
||||
*/
|
||||
public class PursueGlory extends CardImpl {
|
||||
private static final FilterAttackingCreature filter = new FilterAttackingCreature("Attacking creatures");
|
||||
|
||||
public PursueGlory(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{3}{R}");
|
||||
|
||||
// Attacking creatures get +2/+0 until end of turn.
|
||||
getSpellAbility().addEffect(new BoostAllEffect(2, 0, Duration.EndOfTurn, filter, false));
|
||||
getSpellAbility().addEffect(new BoostAllEffect(2, 0, Duration.EndOfTurn, new FilterAttackingCreature("Attacking creatures"), false));
|
||||
|
||||
// Cycling {2}
|
||||
this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}")));
|
||||
|
|
|
|||
75
Mage.Sets/src/mage/cards/p/PyramidOfThePantheon.java
Normal file
75
Mage.Sets/src/mage/cards/p/PyramidOfThePantheon.java
Normal file
|
|
@ -0,0 +1,75 @@
|
|||
/*
|
||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without modification, are
|
||||
* permitted provided that the following conditions are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
||||
* conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
||||
* provided with the distribution.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* The views and conclusions contained in the software and documentation are those of the
|
||||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
package mage.cards.p;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.condition.common.SourceHasCounterCondition;
|
||||
import mage.abilities.costs.common.TapSourceCost;
|
||||
import mage.abilities.costs.mana.GenericManaCost;
|
||||
import mage.abilities.effects.common.AddManaOfAnyColorEffect;
|
||||
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
|
||||
import mage.abilities.mana.ActivateIfConditionManaAbility;
|
||||
import mage.abilities.mana.AnyColorManaAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.counters.CounterType;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author spjspj
|
||||
*/
|
||||
public class PyramidOfThePantheon extends CardImpl {
|
||||
|
||||
public PyramidOfThePantheon(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{1}");
|
||||
|
||||
// {2}, {T}: Add one mana of any color to your mana pool. Put a brick counter on Pyramid of the Pantheon.
|
||||
Ability ability = new AnyColorManaAbility(new GenericManaCost(2));
|
||||
ability.addCost(new TapSourceCost());
|
||||
ability.addEffect(new AddCountersSourceEffect(CounterType.BRICK.createInstance()));
|
||||
this.addAbility(ability);
|
||||
|
||||
// {T}: Add three mana of any one color to your mana pool. Activate this ability only of there are three or more brick counters on Pyramid of the Pantheon.
|
||||
this.addAbility(new ActivateIfConditionManaAbility(Zone.BATTLEFIELD,
|
||||
new AddManaOfAnyColorEffect(3),
|
||||
new TapSourceCost(),
|
||||
new SourceHasCounterCondition(CounterType.BRICK, 3)));
|
||||
}
|
||||
|
||||
public PyramidOfThePantheon(final PyramidOfThePantheon card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PyramidOfThePantheon copy() {
|
||||
return new PyramidOfThePantheon(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -46,7 +46,7 @@ import mage.util.functions.ApplyToPermanent;
|
|||
public class QuicksilverGargantuan extends CardImpl {
|
||||
|
||||
public QuicksilverGargantuan(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{5}{U}{U}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{5}{U}{U}");
|
||||
this.subtype.add("Shapeshifter");
|
||||
|
||||
this.power = new MageInt(7);
|
||||
|
|
@ -70,14 +70,14 @@ public class QuicksilverGargantuan extends CardImpl {
|
|||
class QuicksilverGargantuanApplyToPermanent extends ApplyToPermanent {
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
permanent.getPower().modifyBaseValue(7);
|
||||
permanent.getToughness().modifyBaseValue(7);
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
mageObject.getPower().modifyBaseValue(7);
|
||||
mageObject.getToughness().modifyBaseValue(7);
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -25,25 +25,21 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.r;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.Zone;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.costs.common.TapSourceCost;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.cards.Card;
|
||||
import mage.abilities.effects.common.ExileTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.game.Game;
|
||||
import mage.target.common.TargetCardInASingleGraveyard;
|
||||
|
||||
/**
|
||||
|
|
@ -52,23 +48,22 @@ import mage.target.common.TargetCardInASingleGraveyard;
|
|||
*/
|
||||
public class RagDealer extends CardImpl {
|
||||
|
||||
public RagDealer (UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{B}");
|
||||
public RagDealer(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{B}");
|
||||
this.subtype.add("Human");
|
||||
this.subtype.add("Rogue");
|
||||
|
||||
|
||||
this.power = new MageInt(1);
|
||||
this.toughness = new MageInt(1);
|
||||
|
||||
// {2}{B}, {T}: Exile up to three target cards from a single graveyard.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new RagDealerExileEffect(), new ManaCostsImpl("{2}{B}"));
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(), new ManaCostsImpl("{2}{B}"));
|
||||
ability.addCost(new TapSourceCost());
|
||||
ability.addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("up to three target cards from a single graveyard")));
|
||||
ability.addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("cards from a single graveyard")));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
public RagDealer (final RagDealer card) {
|
||||
public RagDealer(final RagDealer card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
|
|
@ -78,31 +73,3 @@ public class RagDealer extends CardImpl {
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
class RagDealerExileEffect extends OneShotEffect {
|
||||
|
||||
public RagDealerExileEffect() {
|
||||
super(Outcome.Exile);
|
||||
this.staticText = "Exile up to three target cards from a single graveyard";
|
||||
}
|
||||
|
||||
public RagDealerExileEffect(final RagDealerExileEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public RagDealerExileEffect copy() {
|
||||
return new RagDealerExileEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
for (UUID targetID : source.getTargets().get(0).getTargets()) {
|
||||
Card card = game.getCard(targetID);
|
||||
if (card != null) {
|
||||
card.moveToExile(null, "", source.getSourceId(), game);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package mage.cards.r;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
|
|
@ -10,28 +11,25 @@ import mage.cards.*;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
import mage.target.common.TargetControlledCreaturePermanent;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
import mage.target.targetpointer.FixedTarget;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author Stravant
|
||||
*/
|
||||
public class RagsRiches extends SplitCard {
|
||||
|
||||
public RagsRiches(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{2}{B}{B}","{5}{U}{U}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, new CardType[]{CardType.SORCERY}, "{2}{B}{B}", "{5}{U}{U}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Rags
|
||||
// All creatures get -2/-2 until end of turn.
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new BoostAllEffect(-2, -2, Duration.EndOfTurn));
|
||||
|
||||
// to
|
||||
|
||||
// Riches
|
||||
// Each opponent chooses a creature he or she controls. You gain control of each of those creatures.
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
|
|
@ -86,7 +84,7 @@ class RichesEffect extends OneShotEffect {
|
|||
|
||||
// Has to be done as a separate loop in case there's a situation where one creature's
|
||||
// controller depends on another creatures controller.
|
||||
for (UUID target: creaturesToSteal) {
|
||||
for (UUID target : creaturesToSteal) {
|
||||
GainControlTargetEffect eff = new GainControlTargetEffect(Duration.EndOfGame, true);
|
||||
eff.setTargetPointer(new FixedTarget(target));
|
||||
game.addEffect(eff, source);
|
||||
|
|
@ -96,4 +94,4 @@ class RichesEffect extends OneShotEffect {
|
|||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -49,12 +49,6 @@ import mage.filter.predicate.permanent.ControllerPredicate;
|
|||
|
||||
public class RakdosDrake extends CardImpl {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Other creatures you control");
|
||||
static {
|
||||
filter.add(new AnotherPredicate());
|
||||
filter.add(new ControllerPredicate(TargetController.YOU));
|
||||
}
|
||||
|
||||
public RakdosDrake (UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{2}{B}");
|
||||
this.subtype.add("Drake");
|
||||
|
|
|
|||
|
|
@ -28,17 +28,13 @@
|
|||
package mage.cards.r;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.ExileTargetEffect;
|
||||
import mage.abilities.keyword.CyclingAbility;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.game.Game;
|
||||
import mage.target.common.TargetCardInASingleGraveyard;
|
||||
|
||||
/**
|
||||
|
|
@ -48,12 +44,12 @@ import mage.target.common.TargetCardInASingleGraveyard;
|
|||
public class RapidDecay extends CardImpl {
|
||||
|
||||
public RapidDecay(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{B}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{B}");
|
||||
|
||||
// Exile up to three target cards from a single graveyard.
|
||||
this.getSpellAbility().addEffect(new RapidDecayExileEffect());
|
||||
this.getSpellAbility().addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("up to three target cards from a single graveyard")));
|
||||
|
||||
this.getSpellAbility().addEffect(new ExileTargetEffect());
|
||||
this.getSpellAbility().addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("cards from a single graveyard")));
|
||||
|
||||
// Cycling {2}
|
||||
this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}")));
|
||||
}
|
||||
|
|
@ -67,31 +63,3 @@ public class RapidDecay extends CardImpl {
|
|||
return new RapidDecay(this);
|
||||
}
|
||||
}
|
||||
|
||||
class RapidDecayExileEffect extends OneShotEffect {
|
||||
|
||||
public RapidDecayExileEffect() {
|
||||
super(Outcome.Exile);
|
||||
this.staticText = "Exile up to three target cards from a single graveyard";
|
||||
}
|
||||
|
||||
public RapidDecayExileEffect(final RapidDecayExileEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public RapidDecayExileEffect copy() {
|
||||
return new RapidDecayExileEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
for (UUID targetID : source.getTargets().get(0).getTargets()) {
|
||||
Card card = game.getCard(targetID);
|
||||
if (card != null) {
|
||||
card.moveToExile(null, "", source.getSourceId(), game);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,9 +28,6 @@
|
|||
package mage.cards.r;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.UntapAllControllerEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityAllEffect;
|
||||
|
|
@ -40,6 +37,9 @@ import mage.abilities.keyword.IndestructibleAbility;
|
|||
import mage.abilities.keyword.LifelinkAbility;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterControlledCreaturePermanent;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
|
||||
|
|
@ -50,18 +50,18 @@ import mage.filter.common.FilterCreaturePermanent;
|
|||
public class ReadyWilling extends SplitCard {
|
||||
|
||||
public ReadyWilling(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{G}{W}","{1}{W}{B}",true);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{G}{W}", "{1}{W}{B}", SpellAbilityType.SPLIT_FUSED);
|
||||
|
||||
// Ready
|
||||
// Creatures you control are indestructible this turn. Untap each creature you control.
|
||||
Effect effect = new GainAbilityAllEffect(IndestructibleAbility.getInstance(), Duration.EndOfTurn, new FilterControlledCreaturePermanent("Creatures you controll"), false);
|
||||
effect.setText("Creatures you control are indestructible this turn");
|
||||
getLeftHalfCard().getSpellAbility().addEffect(effect);
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new UntapAllControllerEffect(new FilterControlledCreaturePermanent(),"Untap each creature you control"));
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new UntapAllControllerEffect(new FilterControlledCreaturePermanent(), "Untap each creature you control"));
|
||||
|
||||
// Willing
|
||||
// Creatures you control gain deathtouch and lifelink until end of turn.
|
||||
getRightHalfCard().getSpellAbility().addEffect(new GainAbilityControlledEffect(DeathtouchAbility.getInstance(), Duration.EndOfTurn, new FilterCreaturePermanent("Creatures")) );
|
||||
getRightHalfCard().getSpellAbility().addEffect(new GainAbilityControlledEffect(DeathtouchAbility.getInstance(), Duration.EndOfTurn, new FilterCreaturePermanent("Creatures")));
|
||||
effect = new GainAbilityControlledEffect(LifelinkAbility.getInstance(), Duration.EndOfTurn, new FilterCreaturePermanent("Creatures"));
|
||||
effect.setText("Creatures you control gain lifelink until end of turn");
|
||||
getRightHalfCard().getSpellAbility().addEffect(effect);
|
||||
|
|
|
|||
|
|
@ -37,6 +37,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterLandPermanent;
|
||||
import mage.target.TargetPermanent;
|
||||
import mage.target.TargetSpell;
|
||||
|
|
@ -48,7 +49,7 @@ import mage.target.TargetSpell;
|
|||
public class ReduceRubble extends SplitCard {
|
||||
|
||||
public ReduceRubble(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{2}{U}", "{2}{R}", false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, new CardType[]{CardType.SORCERY}, "{2}{U}", "{2}{R}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Reduce
|
||||
// Counter target spell unless its controller pays {3}.
|
||||
|
|
@ -57,7 +58,7 @@ public class ReduceRubble extends SplitCard {
|
|||
|
||||
// Rubble
|
||||
// Up to three target lands don't untap during their controller's next untap step.
|
||||
((CardImpl)(getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
Effect effect = new DontUntapInControllersNextUntapStepTargetEffect();
|
||||
effect.setText("Up to three target lands don't untap during their controller's next untap step");
|
||||
getRightHalfCard().getSpellAbility().addEffect(effect);
|
||||
|
|
|
|||
|
|
@ -32,6 +32,7 @@ import mage.MageInt;
|
|||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
import mage.abilities.effects.common.continuous.BoostControlledEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityControlledEffect;
|
||||
|
|
@ -75,7 +76,9 @@ public class RegalCaracal extends CardImpl {
|
|||
this.addAbility(ability);
|
||||
|
||||
// When Regal Caracal enters the battlefield, create two 1/1 white Cat creature tokens with lifelink.
|
||||
this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new CatToken2(), 2)));
|
||||
Effect effect2 = new CreateTokenEffect(new CatToken2(), 2);
|
||||
effect2.setText("create two 1/1 white Cat creature tokens with lifelink");
|
||||
this.addAbility(new EntersBattlefieldTriggeredAbility(effect2));
|
||||
}
|
||||
|
||||
public RegalCaracal(final RegalCaracal card) {
|
||||
|
|
|
|||
|
|
@ -33,12 +33,13 @@ import mage.abilities.Ability;
|
|||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.Cards;
|
||||
import mage.cards.CardsImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.game.Game;
|
||||
|
|
@ -53,7 +54,7 @@ import mage.target.TargetCard;
|
|||
public class ResearchDevelopment extends SplitCard {
|
||||
|
||||
public ResearchDevelopment(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{G}{U}","{3}{U}{R}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{G}{U}", "{3}{U}{R}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Choose up to four cards you own from outside the game and shuffle them into your library.
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new ResearchEffect());
|
||||
|
|
@ -78,7 +79,6 @@ class ResearchEffect extends OneShotEffect {
|
|||
|
||||
private static final FilterCard filter = new FilterCard("card");
|
||||
|
||||
|
||||
public ResearchEffect() {
|
||||
super(Outcome.Benefit);
|
||||
this.staticText = "Choose up to four cards you own from outside the game and shuffle them into your library";
|
||||
|
|
@ -102,7 +102,7 @@ class ResearchEffect extends OneShotEffect {
|
|||
int count = 0;
|
||||
while (player.chooseUse(Outcome.Benefit, textToAsk.toString(), source, game)) {
|
||||
Cards cards = player.getSideboard();
|
||||
if(cards.isEmpty()) {
|
||||
if (cards.isEmpty()) {
|
||||
game.informPlayer(player, "You have no cards outside the game.");
|
||||
break;
|
||||
}
|
||||
|
|
@ -170,7 +170,7 @@ class DevelopmentEffect extends OneShotEffect {
|
|||
for (UUID opponentUuid : opponents) {
|
||||
Player opponent = game.getPlayer(opponentUuid);
|
||||
if (opponent != null && opponent.chooseUse(Outcome.Detriment,
|
||||
"Allow " + player.getLogName() + " to draw a card instead? (" + Integer.toString(i+1) + ')', source, game)) {
|
||||
"Allow " + player.getLogName() + " to draw a card instead? (" + Integer.toString(i + 1) + ')', source, game)) {
|
||||
game.informPlayers(opponent.getLogName() + " had chosen to let " + player.getLogName() + " draw a card.");
|
||||
player.drawCards(1, game);
|
||||
putToken = false;
|
||||
|
|
@ -192,4 +192,4 @@ class DevelopmentEffect extends OneShotEffect {
|
|||
return new DevelopmentEffect(this);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ package mage.cards.r;
|
|||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.common.BecomesExertSourceTriggeredAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.continuous.BoostSourceEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilitySourceEffect;
|
||||
import mage.abilities.keyword.ExertAbility;
|
||||
|
|
@ -47,17 +48,19 @@ public class RhetCropSpearmaster extends CardImpl {
|
|||
|
||||
public RhetCropSpearmaster(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}");
|
||||
|
||||
|
||||
this.subtype.add("Human");
|
||||
this.subtype.add("Warrior");
|
||||
this.power = new MageInt(3);
|
||||
this.toughness = new MageInt(1);
|
||||
|
||||
// You may exert Rhet-Crop Spearmaster as it attacks. When you do, it gets +1/+0 and gains first strike until end of turn.
|
||||
BecomesExertSourceTriggeredAbility ability =
|
||||
new BecomesExertSourceTriggeredAbility(
|
||||
new BoostSourceEffect(1, 0, Duration.EndOfTurn));
|
||||
ability.addEffect(new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn));
|
||||
Effect effect = new BoostSourceEffect(1, 0, Duration.EndOfTurn);
|
||||
effect.setText("it gets +1/+0");
|
||||
BecomesExertSourceTriggeredAbility ability = new BecomesExertSourceTriggeredAbility(effect);
|
||||
effect = new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn);
|
||||
effect.setText(" and gains first strike until end of turn");
|
||||
ability.addEffect(effect);
|
||||
this.addAbility(new ExertAbility(ability));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -32,12 +32,13 @@ import mage.MageObject;
|
|||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.Cards;
|
||||
import mage.cards.CardsImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.game.Game;
|
||||
|
|
@ -54,7 +55,7 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
public class RiseFall extends SplitCard {
|
||||
|
||||
public RiseFall(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{U}{B}","{B}{R}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{U}{B}", "{B}{R}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Rise
|
||||
// Return target creature card from a graveyard and target creature on the battlefield to their owners' hands.
|
||||
|
|
|
|||
|
|
@ -98,6 +98,10 @@ class RiverSerpentEffect extends RestrictionEffect {
|
|||
|
||||
@Override
|
||||
public boolean applies(Permanent permanent, Ability source, Game game) {
|
||||
return new CardsInControllerGraveyardCount().calculate(game, source, this) < 5;
|
||||
if (permanent.getId().equals(source.getSourceId())) {
|
||||
return new CardsInControllerGraveyardCount().calculate(game, source, this) < 5;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -34,6 +34,7 @@ import mage.abilities.keyword.FlyingAbility;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.mageobject.AbilityPredicate;
|
||||
|
|
@ -46,13 +47,14 @@ public class RoughTumble extends SplitCard {
|
|||
|
||||
private static final FilterCreaturePermanent filterFlying = new FilterCreaturePermanent("creature with flying");
|
||||
private static final FilterCreaturePermanent filterWithoutFlying = new FilterCreaturePermanent("creature without flying");
|
||||
|
||||
static {
|
||||
filterFlying.add(new AbilityPredicate(FlyingAbility.class));
|
||||
filterWithoutFlying.add(Predicates.not(new AbilityPredicate(FlyingAbility.class)));
|
||||
}
|
||||
|
||||
public RoughTumble(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{1}{R}","{5}{R}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{R}", "{5}{R}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Rough
|
||||
// Rough deals 2 damage to each creature without flying.
|
||||
|
|
|
|||
|
|
@ -29,17 +29,13 @@ package mage.cards.s;
|
|||
|
||||
import java.util.UUID;
|
||||
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.common.ReturnFromGraveyardToHandTargetEffect;
|
||||
import mage.abilities.keyword.CyclingAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.filter.predicate.Predicate;
|
||||
import mage.filter.predicate.mageobject.AbilityPredicate;
|
||||
import mage.game.Game;
|
||||
import mage.target.common.TargetCardInYourGraveyard;
|
||||
|
||||
/**
|
||||
|
|
@ -47,9 +43,11 @@ import mage.target.common.TargetCardInYourGraveyard;
|
|||
* @author stravant
|
||||
*/
|
||||
public class SacredExcavation extends CardImpl {
|
||||
private static final FilterCard cardsWithCycling = new FilterCard();
|
||||
|
||||
private static final FilterCard cardsWithCycling = new FilterCard("cards with cycling from your graveyard");
|
||||
|
||||
static {
|
||||
cardsWithCycling.add(new CyclingPredicate());
|
||||
cardsWithCycling.add(new AbilityPredicate(CyclingAbility.class));
|
||||
}
|
||||
|
||||
public SacredExcavation(UUID ownerId, CardSetInfo setInfo) {
|
||||
|
|
@ -69,15 +67,3 @@ public class SacredExcavation extends CardImpl {
|
|||
return new SacredExcavation(this);
|
||||
}
|
||||
}
|
||||
|
||||
class CyclingPredicate implements Predicate<MageObject> {
|
||||
@Override
|
||||
public boolean apply(MageObject input, Game game) {
|
||||
for (Ability ability : input.getAbilities()) {
|
||||
if (ability instanceof CyclingAbility) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
@ -28,9 +28,9 @@
|
|||
package mage.cards.s;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.EntersBattlefieldAbility;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility;
|
||||
|
|
@ -81,7 +81,7 @@ public class SakashimaTheImpostor extends CardImpl {
|
|||
class SakashimaTheImpostorApplier extends ApplyToPermanent {
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Permanent permanent) {
|
||||
public boolean apply(Game game, Permanent permanent, Ability source, UUID copyToObjectId) {
|
||||
permanent.addSuperType(SuperType.LEGENDARY);
|
||||
|
||||
permanent.setName("Sakashima the Impostor");
|
||||
|
|
@ -94,8 +94,8 @@ class SakashimaTheImpostorApplier extends ApplyToPermanent {
|
|||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, MageObject mageObject) {
|
||||
mageObject.addSuperType(SuperType.LEGENDARY);
|
||||
public boolean apply(Game game, MageObject mageObject, Ability source, UUID copyToObjectId) {
|
||||
mageObject.addSuperType(SuperType.LEGENDARY);
|
||||
mageObject.setName("Sakashima the Impostor");
|
||||
// {2}{U}{U}: Return Sakashima the Impostor to its owner's hand at the beginning of the next end step
|
||||
mageObject.getAbilities().add(new SimpleActivatedAbility(Zone.BATTLEFIELD,
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ public class ScarabFeast extends CardImpl {
|
|||
|
||||
// Exile up to three target cards from a single graveyard.
|
||||
getSpellAbility().addEffect(new ExileTargetEffect());
|
||||
getSpellAbility().addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("cards")));
|
||||
getSpellAbility().addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("cards from a single graveyard")));
|
||||
|
||||
// Cycling {B}
|
||||
addAbility(new CyclingAbility(new ManaCostsImpl("{B}")));
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ import mage.abilities.common.SimpleActivatedAbility;
|
|||
import mage.abilities.costs.common.SacrificeSourceCost;
|
||||
import mage.abilities.costs.common.TapSourceCost;
|
||||
import mage.abilities.costs.mana.GenericManaCost;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.ReturnToHandTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
|
|
@ -67,7 +68,9 @@ public class ScribeOfTheMindful extends CardImpl {
|
|||
this.toughness = new MageInt(2);
|
||||
|
||||
// {1}, {T}, Sacrifice Scribe of the Mindful: Return target instant or sorcery card from your graveyard to your hand.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(), new GenericManaCost(1));
|
||||
Effect effect = new ReturnToHandTargetEffect();
|
||||
effect.setText("Return target instant or sorcery card from your graveyard to your hand");
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new GenericManaCost(1));
|
||||
ability.addCost(new TapSourceCost());
|
||||
ability.addCost(new SacrificeSourceCost());
|
||||
ability.addTarget(new TargetCardInYourGraveyard(filter));
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ public class SeekerOfInsight extends CardImpl {
|
|||
|
||||
public SeekerOfInsight(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{U}");
|
||||
|
||||
|
||||
this.subtype.add("Human");
|
||||
this.subtype.add("Wizard");
|
||||
this.power = new MageInt(1);
|
||||
|
|
@ -93,4 +93,9 @@ class CastNonCreatureSpellCondition implements Condition {
|
|||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "you've cast a noncreature spell this turn";
|
||||
}
|
||||
}
|
||||
|
|
@ -52,6 +52,7 @@ import mage.game.permanent.Permanent;
|
|||
import mage.players.Player;
|
||||
import mage.target.Target;
|
||||
import mage.target.common.TargetCardInHand;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
import mage.target.targetpointer.FixedTarget;
|
||||
|
||||
/**
|
||||
|
|
@ -66,6 +67,7 @@ public class ShedWeakness extends CardImpl {
|
|||
// Target creature gets +2/+2 until end of turn. You may remove a -1/-1 counter from it.
|
||||
getSpellAbility().addEffect(new BoostTargetEffect(2, 2, Duration.EndOfTurn));
|
||||
getSpellAbility().addEffect(new MayRemoveM1M1CouterTargetEffect());
|
||||
getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
}
|
||||
|
||||
public ShedWeakness(final ShedWeakness card) {
|
||||
|
|
|
|||
|
|
@ -59,9 +59,7 @@ public class Soulstinger extends CardImpl {
|
|||
this.toughness = new MageInt(5);
|
||||
|
||||
// When Soulstinger enters the battlefield, put two -1/-1 counter on target creature you control.
|
||||
Ability ability =
|
||||
new EntersBattlefieldTriggeredAbility(
|
||||
new AddCountersTargetEffect(CounterType.M1M1.createInstance(), new StaticValue(2), Outcome.Detriment));
|
||||
Ability ability = new EntersBattlefieldTriggeredAbility( new AddCountersTargetEffect(CounterType.M1M1.createInstance(2)));
|
||||
ability.addTarget(new TargetControlledCreaturePermanent());
|
||||
this.addAbility(ability);
|
||||
|
||||
|
|
@ -72,7 +70,7 @@ public class Soulstinger extends CardImpl {
|
|||
new CountersSourceCount(CounterType.M1M1),
|
||||
Outcome.Detriment);
|
||||
effect.setText("you may put a -1/-1 counter on target creature for each -1/-1 counter on {this}");
|
||||
ability = new DiesTriggeredAbility(effect);
|
||||
ability = new DiesTriggeredAbility(effect, true);
|
||||
ability.addTarget(new TargetCreaturePermanent());
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,6 +38,7 @@ import mage.constants.Duration;
|
|||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
|
||||
/**
|
||||
* @author nantuko
|
||||
|
|
@ -45,13 +46,19 @@ import java.util.UUID;
|
|||
public class SpideryGrasp extends CardImpl {
|
||||
|
||||
public SpideryGrasp(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{2}{G}");
|
||||
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{2}{G}");
|
||||
|
||||
// Untap target creature. It gets +2/+4 and gains reach until end of turn.
|
||||
this.getSpellAbility().addEffect(new UntapTargetEffect());
|
||||
this.getSpellAbility().addEffect(new GainAbilityTargetEffect(ReachAbility.getInstance(), Duration.EndOfTurn));
|
||||
this.getSpellAbility().addEffect(new BoostTargetEffect(2, 4, Duration.EndOfTurn));
|
||||
|
||||
Effect effect = new BoostTargetEffect(2, 4, Duration.EndOfTurn);
|
||||
effect.setText("It gets +2/+4");
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
|
||||
effect = new GainAbilityTargetEffect(ReachAbility.getInstance(), Duration.EndOfTurn);
|
||||
effect.setText("and gains reach until end of turn");
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ import mage.abilities.effects.common.DestroyTargetEffect;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.FilterSpell;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
|
|
@ -47,25 +48,27 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
* @author FenrisulfrX
|
||||
*/
|
||||
public class SpiteMalice extends SplitCard {
|
||||
|
||||
private static final FilterSpell filterNonCreatureSpell = new FilterSpell("noncreature spell");
|
||||
|
||||
private static final FilterSpell filterNonCreatureSpell = new FilterSpell("noncreature spell");
|
||||
|
||||
static {
|
||||
filterNonCreatureSpell.add(Predicates.not(new CardTypePredicate(CardType.CREATURE)));
|
||||
}
|
||||
|
||||
|
||||
private static final FilterCreaturePermanent filterNonBlackCreature = new FilterCreaturePermanent("nonblack creature");
|
||||
|
||||
static {
|
||||
filterNonBlackCreature.add(Predicates.not(new ColorPredicate(ObjectColor.BLACK)));
|
||||
}
|
||||
|
||||
public SpiteMalice(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{3}{U}","{3}{B}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{3}{U}", "{3}{B}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Spite
|
||||
// Counter target noncreature spell.
|
||||
this.getLeftHalfCard().getSpellAbility().addEffect(new CounterTargetEffect());
|
||||
this.getLeftHalfCard().getSpellAbility().addTarget(new TargetSpell(filterNonCreatureSpell));
|
||||
|
||||
this.getLeftHalfCard().getSpellAbility().addTarget(new TargetSpell(filterNonCreatureSpell));
|
||||
|
||||
// Malice
|
||||
// Destroy target nonblack creature. It can't be regenerated.
|
||||
this.getRightHalfCard().getSpellAbility().addEffect(new DestroyTargetEffect(true));
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.filter.common.FilterBasicLandCard;
|
||||
import mage.target.common.TargetCardInLibrary;
|
||||
|
||||
|
|
@ -45,7 +46,7 @@ import mage.target.common.TargetCardInLibrary;
|
|||
public class SpringMind extends SplitCard {
|
||||
|
||||
public SpringMind(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, new CardType[]{CardType.INSTANT}, "{2}{G}", "{4}{U}{U}", false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, new CardType[]{CardType.INSTANT}, "{2}{G}", "{4}{U}{U}", SpellAbilityType.SPLIT_AFTERMATH);
|
||||
|
||||
// Spring
|
||||
// Search your library for a basic land card, put it onto the battlefield tapped, then shuffle your library.
|
||||
|
|
@ -54,7 +55,7 @@ public class SpringMind extends SplitCard {
|
|||
// Mind
|
||||
// Aftermath
|
||||
// Draw two cards.
|
||||
((CardImpl)(getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
((CardImpl) (getRightHalfCard())).addAbility(new AftermathAbility());
|
||||
getRightHalfCard().getSpellAbility().addEffect(new DrawCardSourceControllerEffect(2));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.cards.SplitCard;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SpellAbilityType;
|
||||
import mage.target.TargetPermanent;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
|
|
@ -44,7 +45,7 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
public class StandDeliver extends SplitCard {
|
||||
|
||||
public StandDeliver(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{W}","{2}{U}",false);
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{W}", "{2}{U}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Stand
|
||||
// Prevent the next 2 damage that would be dealt to target creature this turn.
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue