mirror of
https://github.com/correl/mage.git
synced 2024-12-26 11:09:27 +00:00
[40K] Implemented Vexilus Praetor
This commit is contained in:
parent
3c9fb843c7
commit
c48c4ccf53
7 changed files with 115 additions and 94 deletions
|
@ -1,18 +1,17 @@
|
||||||
package mage.cards.h;
|
package mage.cards.h;
|
||||||
|
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
import mage.MageObject;
|
|
||||||
import mage.abilities.AbilitiesImpl;
|
import mage.abilities.AbilitiesImpl;
|
||||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||||
import mage.abilities.keyword.LevelUpAbility;
|
import mage.abilities.keyword.LevelUpAbility;
|
||||||
import mage.abilities.keyword.LevelerCardBuilder;
|
import mage.abilities.keyword.LevelerCardBuilder;
|
||||||
import mage.abilities.keyword.ProtectionAbility;
|
import mage.abilities.keyword.ProtectionAbility;
|
||||||
|
import mage.abilities.keyword.ProtectionFromEverythingAbility;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.cards.LevelerCard;
|
import mage.cards.LevelerCard;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterCard;
|
import mage.filter.FilterCard;
|
||||||
import mage.game.Game;
|
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
|
@ -45,10 +44,10 @@ public final class Hexdrinker extends LevelerCard {
|
||||||
// Protection from everything
|
// Protection from everything
|
||||||
this.addAbilities(LevelerCardBuilder.construct(
|
this.addAbilities(LevelerCardBuilder.construct(
|
||||||
new LevelerCardBuilder.LevelAbility(
|
new LevelerCardBuilder.LevelAbility(
|
||||||
3, 7, new AbilitiesImpl(new ProtectionAbility(filter)), 4, 4
|
3, 7, new AbilitiesImpl<>(new ProtectionAbility(filter)), 4, 4
|
||||||
),
|
),
|
||||||
new LevelerCardBuilder.LevelAbility(
|
new LevelerCardBuilder.LevelAbility(
|
||||||
8, -1, new AbilitiesImpl(new HexdrinkerProtectionAbility()), 6, 6
|
8, -1, new AbilitiesImpl<>(new ProtectionFromEverythingAbility()), 6, 6
|
||||||
)
|
)
|
||||||
));
|
));
|
||||||
|
|
||||||
|
@ -64,24 +63,3 @@ public final class Hexdrinker extends LevelerCard {
|
||||||
return new Hexdrinker(this);
|
return new Hexdrinker(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class HexdrinkerProtectionAbility extends ProtectionAbility {
|
|
||||||
|
|
||||||
HexdrinkerProtectionAbility() {
|
|
||||||
super(new FilterCard("everything"));
|
|
||||||
}
|
|
||||||
|
|
||||||
private HexdrinkerProtectionAbility(final HexdrinkerProtectionAbility ability) {
|
|
||||||
super(ability);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public HexdrinkerProtectionAbility copy() {
|
|
||||||
return new HexdrinkerProtectionAbility(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean canTarget(MageObject source, Game game) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
|
@ -1,28 +1,24 @@
|
||||||
|
|
||||||
package mage.cards.p;
|
package mage.cards.p;
|
||||||
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
import mage.MageObject;
|
|
||||||
import mage.abilities.common.PutIntoGraveFromAnywhereSourceAbility;
|
import mage.abilities.common.PutIntoGraveFromAnywhereSourceAbility;
|
||||||
import mage.abilities.effects.common.RevealAndShuffleIntoLibrarySourceEffect;
|
import mage.abilities.effects.common.RevealAndShuffleIntoLibrarySourceEffect;
|
||||||
import mage.abilities.keyword.ProtectionAbility;
|
import mage.abilities.keyword.ProtectionFromEverythingAbility;
|
||||||
import mage.cards.CardImpl;
|
import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.constants.SuperType;
|
import mage.constants.SuperType;
|
||||||
import mage.filter.FilterCard;
|
|
||||||
import mage.game.Game;
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author North
|
* @author North
|
||||||
*/
|
*/
|
||||||
public final class Progenitus extends CardImpl {
|
public final class Progenitus extends CardImpl {
|
||||||
|
|
||||||
public Progenitus(UUID ownerId, CardSetInfo setInfo) {
|
public Progenitus(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{W}{W}{U}{U}{B}{B}{R}{R}{G}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{W}{W}{U}{U}{B}{B}{R}{R}{G}{G}");
|
||||||
addSuperType(SuperType.LEGENDARY);
|
addSuperType(SuperType.LEGENDARY);
|
||||||
this.subtype.add(SubType.HYDRA);
|
this.subtype.add(SubType.HYDRA);
|
||||||
this.subtype.add(SubType.AVATAR);
|
this.subtype.add(SubType.AVATAR);
|
||||||
|
@ -30,14 +26,9 @@ public final class Progenitus extends CardImpl {
|
||||||
this.power = new MageInt(10);
|
this.power = new MageInt(10);
|
||||||
this.toughness = new MageInt(10);
|
this.toughness = new MageInt(10);
|
||||||
|
|
||||||
// 2/1/2009: "Protection from everything" means the following: Progenitus can't be blocked,
|
|
||||||
// Progenitus can't be enchanted or equipped, Progenitus can't be the target of
|
|
||||||
// spells or abilities, and all damage that would be dealt to Progenitus is prevented.
|
|
||||||
// 2/1/2009: Progenitus can still be affected by effects that don't target it or deal damage
|
|
||||||
// to it (such as Day of Judgment).
|
|
||||||
|
|
||||||
// Protection from everything
|
// Protection from everything
|
||||||
this.addAbility(new ProgenitusProtectionAbility());
|
this.addAbility(new ProtectionFromEverythingAbility());
|
||||||
|
|
||||||
// If Progenitus would be put into a graveyard from anywhere, reveal Progenitus and shuffle it into its owner's library instead.
|
// If Progenitus would be put into a graveyard from anywhere, reveal Progenitus and shuffle it into its owner's library instead.
|
||||||
this.addAbility(new PutIntoGraveFromAnywhereSourceAbility(new RevealAndShuffleIntoLibrarySourceEffect()));
|
this.addAbility(new PutIntoGraveFromAnywhereSourceAbility(new RevealAndShuffleIntoLibrarySourceEffect()));
|
||||||
}
|
}
|
||||||
|
@ -51,24 +42,3 @@ public final class Progenitus extends CardImpl {
|
||||||
return new Progenitus(this);
|
return new Progenitus(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class ProgenitusProtectionAbility extends ProtectionAbility {
|
|
||||||
|
|
||||||
public ProgenitusProtectionAbility() {
|
|
||||||
super(new FilterCard("everything"));
|
|
||||||
}
|
|
||||||
|
|
||||||
public ProgenitusProtectionAbility(final ProgenitusProtectionAbility ability) {
|
|
||||||
super(ability);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public ProgenitusProtectionAbility copy() {
|
|
||||||
return new ProgenitusProtectionAbility(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean canTarget(MageObject source, Game game) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
|
@ -1,30 +1,27 @@
|
||||||
|
|
||||||
package mage.cards.t;
|
package mage.cards.t;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.MageObject;
|
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.effects.OneShotEffect;
|
import mage.abilities.effects.OneShotEffect;
|
||||||
import mage.abilities.effects.common.ExileSpellEffect;
|
import mage.abilities.effects.common.ExileSpellEffect;
|
||||||
import mage.abilities.effects.common.PhaseOutAllEffect;
|
import mage.abilities.effects.common.PhaseOutAllEffect;
|
||||||
import mage.abilities.effects.common.continuous.GainAbilityControllerEffect;
|
import mage.abilities.effects.common.continuous.GainAbilityControllerEffect;
|
||||||
import mage.abilities.effects.common.continuous.LifeTotalCantChangeControllerEffect;
|
import mage.abilities.effects.common.continuous.LifeTotalCantChangeControllerEffect;
|
||||||
import mage.abilities.keyword.ProtectionAbility;
|
import mage.abilities.keyword.ProtectionFromEverythingAbility;
|
||||||
import mage.cards.CardImpl;
|
import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.Duration;
|
import mage.constants.Duration;
|
||||||
import mage.constants.Outcome;
|
import mage.constants.Outcome;
|
||||||
import mage.filter.FilterCard;
|
|
||||||
import mage.filter.StaticFilters;
|
import mage.filter.StaticFilters;
|
||||||
import mage.game.Game;
|
import mage.game.Game;
|
||||||
import mage.game.permanent.Permanent;
|
import mage.game.permanent.Permanent;
|
||||||
import mage.players.Player;
|
import mage.players.Player;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author spjspj
|
* @author spjspj
|
||||||
*/
|
*/
|
||||||
public final class TeferisProtection extends CardImpl {
|
public final class TeferisProtection extends CardImpl {
|
||||||
|
@ -56,18 +53,18 @@ class TeferisProtectionEffect extends OneShotEffect {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 25.08.2017 The following rulings focus on the “protection from” keyword
|
* 25.08.2017 The following rulings focus on the “protection from” keyword
|
||||||
*
|
* <p>
|
||||||
* 25.08.2017 If a player has protection from everything, it means three
|
* 25.08.2017 If a player has protection from everything, it means three
|
||||||
* things: 1) All damage that would be dealt to that player is prevented. 2)
|
* things: 1) All damage that would be dealt to that player is prevented. 2)
|
||||||
* Auras can't be attached to that player. 3) That player can't be the
|
* Auras can't be attached to that player. 3) That player can't be the
|
||||||
* target of spells or abilities.
|
* target of spells or abilities.
|
||||||
*
|
* <p>
|
||||||
* 25.08.2017 Nothing other than the specified events are prevented or
|
* 25.08.2017 Nothing other than the specified events are prevented or
|
||||||
* illegal. An effect that doesn't target you could still cause you to
|
* illegal. An effect that doesn't target you could still cause you to
|
||||||
* discard cards, for example. Creatures can still attack you while you have
|
* discard cards, for example. Creatures can still attack you while you have
|
||||||
* protection from everything, although combat damage that they would deal
|
* protection from everything, although combat damage that they would deal
|
||||||
* to you will be prevented.
|
* to you will be prevented.
|
||||||
*
|
* <p>
|
||||||
* 25.08.2017 Gaining protection from everything causes a spell or ability
|
* 25.08.2017 Gaining protection from everything causes a spell or ability
|
||||||
* on the stack to have an illegal target if it targets you. As a spell or
|
* on the stack to have an illegal target if it targets you. As a spell or
|
||||||
* ability tries to resolve, if all its targets are illegal, that spell or
|
* ability tries to resolve, if all its targets are illegal, that spell or
|
||||||
|
@ -89,7 +86,7 @@ class TeferisProtectionEffect extends OneShotEffect {
|
||||||
public boolean apply(Game game, Ability source) {
|
public boolean apply(Game game, Ability source) {
|
||||||
Player controller = game.getPlayer(source.getControllerId());
|
Player controller = game.getPlayer(source.getControllerId());
|
||||||
if (controller != null) {
|
if (controller != null) {
|
||||||
game.addEffect(new GainAbilityControllerEffect(new TeferisProtectionAbility(), Duration.UntilYourNextTurn), source);
|
game.addEffect(new GainAbilityControllerEffect(new ProtectionFromEverythingAbility(), Duration.UntilYourNextTurn), source);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
@ -101,27 +98,6 @@ class TeferisProtectionEffect extends OneShotEffect {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class TeferisProtectionAbility extends ProtectionAbility {
|
|
||||||
|
|
||||||
public TeferisProtectionAbility() {
|
|
||||||
super(new FilterCard("everything"));
|
|
||||||
}
|
|
||||||
|
|
||||||
public TeferisProtectionAbility(final TeferisProtectionAbility ability) {
|
|
||||||
super(ability);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TeferisProtectionAbility copy() {
|
|
||||||
return new TeferisProtectionAbility(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean canTarget(MageObject source, Game game) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
class TeferisProtectionPhaseOutEffect extends OneShotEffect {
|
class TeferisProtectionPhaseOutEffect extends OneShotEffect {
|
||||||
|
|
||||||
public TeferisProtectionPhaseOutEffect() {
|
public TeferisProtectionPhaseOutEffect() {
|
||||||
|
|
59
Mage.Sets/src/mage/cards/v/VexilusPraetor.java
Normal file
59
Mage.Sets/src/mage/cards/v/VexilusPraetor.java
Normal file
|
@ -0,0 +1,59 @@
|
||||||
|
package mage.cards.v;
|
||||||
|
|
||||||
|
import mage.MageInt;
|
||||||
|
import mage.abilities.common.SimpleStaticAbility;
|
||||||
|
import mage.abilities.effects.common.continuous.GainAbilityControlledEffect;
|
||||||
|
import mage.abilities.keyword.FlashAbility;
|
||||||
|
import mage.abilities.keyword.ProtectionFromEverythingAbility;
|
||||||
|
import mage.abilities.keyword.VigilanceAbility;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.CardType;
|
||||||
|
import mage.constants.Duration;
|
||||||
|
import mage.constants.SubType;
|
||||||
|
import mage.filter.FilterPermanent;
|
||||||
|
import mage.filter.common.FilterControlledPermanent;
|
||||||
|
import mage.filter.predicate.mageobject.CommanderPredicate;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author TheElk801
|
||||||
|
*/
|
||||||
|
public final class VexilusPraetor extends CardImpl {
|
||||||
|
|
||||||
|
private static final FilterPermanent filter = new FilterControlledPermanent("commanders you control");
|
||||||
|
|
||||||
|
static {
|
||||||
|
filter.add(CommanderPredicate.instance);
|
||||||
|
}
|
||||||
|
|
||||||
|
public VexilusPraetor(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{W}");
|
||||||
|
|
||||||
|
this.subtype.add(SubType.CUSTODES);
|
||||||
|
this.subtype.add(SubType.WARRIOR);
|
||||||
|
this.power = new MageInt(3);
|
||||||
|
this.toughness = new MageInt(4);
|
||||||
|
|
||||||
|
// Flash
|
||||||
|
this.addAbility(FlashAbility.getInstance());
|
||||||
|
|
||||||
|
// Vigilance
|
||||||
|
this.addAbility(VigilanceAbility.getInstance());
|
||||||
|
|
||||||
|
// Aegis of the Emperor -- Commanders you control have protection from everything.
|
||||||
|
this.addAbility(new SimpleStaticAbility(new GainAbilityControlledEffect(
|
||||||
|
new ProtectionFromEverythingAbility(), Duration.WhileOnBattlefield, filter
|
||||||
|
)).withFlavorWord("Aegis of the Emperor"));
|
||||||
|
}
|
||||||
|
|
||||||
|
private VexilusPraetor(final VexilusPraetor card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public VexilusPraetor copy() {
|
||||||
|
return new VexilusPraetor(this);
|
||||||
|
}
|
||||||
|
}
|
|
@ -210,6 +210,7 @@ public final class Warhammer40000 extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Vault of Whispers", 305, Rarity.COMMON, mage.cards.v.VaultOfWhispers.class));
|
cards.add(new SetCardInfo("Vault of Whispers", 305, Rarity.COMMON, mage.cards.v.VaultOfWhispers.class));
|
||||||
cards.add(new SetCardInfo("Venomcrawler", 68, Rarity.RARE, mage.cards.v.Venomcrawler.class));
|
cards.add(new SetCardInfo("Venomcrawler", 68, Rarity.RARE, mage.cards.v.Venomcrawler.class));
|
||||||
cards.add(new SetCardInfo("Venomthrope", 147, Rarity.UNCOMMON, mage.cards.v.Venomthrope.class));
|
cards.add(new SetCardInfo("Venomthrope", 147, Rarity.UNCOMMON, mage.cards.v.Venomthrope.class));
|
||||||
|
cards.add(new SetCardInfo("Vexilus Praetor", 19, Rarity.RARE, mage.cards.v.VexilusPraetor.class));
|
||||||
cards.add(new SetCardInfo("Warstorm Surge", 209, Rarity.RARE, mage.cards.w.WarstormSurge.class));
|
cards.add(new SetCardInfo("Warstorm Surge", 209, Rarity.RARE, mage.cards.w.WarstormSurge.class));
|
||||||
cards.add(new SetCardInfo("Wayfarer's Bauble", 261, Rarity.COMMON, mage.cards.w.WayfarersBauble.class));
|
cards.add(new SetCardInfo("Wayfarer's Bauble", 261, Rarity.COMMON, mage.cards.w.WayfarersBauble.class));
|
||||||
cards.add(new SetCardInfo("Winged Hive Tyrant", 148, Rarity.RARE, mage.cards.w.WingedHiveTyrant.class));
|
cards.add(new SetCardInfo("Winged Hive Tyrant", 148, Rarity.RARE, mage.cards.w.WingedHiveTyrant.class));
|
||||||
|
|
|
@ -0,0 +1,36 @@
|
||||||
|
package mage.abilities.keyword;
|
||||||
|
|
||||||
|
import mage.MageObject;
|
||||||
|
import mage.filter.FilterCard;
|
||||||
|
import mage.game.Game;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author TheElk801
|
||||||
|
*/
|
||||||
|
public class ProtectionFromEverythingAbility extends ProtectionAbility {
|
||||||
|
|
||||||
|
private static final FilterCard filter = new FilterCard("everything");
|
||||||
|
|
||||||
|
public ProtectionFromEverythingAbility() {
|
||||||
|
super(filter);
|
||||||
|
}
|
||||||
|
|
||||||
|
private ProtectionFromEverythingAbility(final ProtectionFromEverythingAbility ability) {
|
||||||
|
super(ability);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ProtectionFromEverythingAbility copy() {
|
||||||
|
return new ProtectionFromEverythingAbility(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 2/1/2009: "Protection from everything" means the following: Progenitus can't be blocked,
|
||||||
|
// Progenitus can't be enchanted or equipped, Progenitus can't be the target of
|
||||||
|
// spells or abilities, and all damage that would be dealt to Progenitus is prevented.
|
||||||
|
// 2/1/2009: Progenitus can still be affected by effects that don't target it or deal damage
|
||||||
|
// to it (such as Day of Judgment).
|
||||||
|
@Override
|
||||||
|
public boolean canTarget(MageObject source, Game game) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
|
@ -114,6 +114,7 @@ public enum SubType {
|
||||||
CRAB("Crab", SubTypeSet.CreatureType),
|
CRAB("Crab", SubTypeSet.CreatureType),
|
||||||
CROCODILE("Crocodile", SubTypeSet.CreatureType),
|
CROCODILE("Crocodile", SubTypeSet.CreatureType),
|
||||||
CROLUTE("Crolute", SubTypeSet.CreatureType, true), // Star Wars
|
CROLUTE("Crolute", SubTypeSet.CreatureType, true), // Star Wars
|
||||||
|
CUSTODES("Custodes", SubTypeSet.CreatureType),
|
||||||
CYBORG("Cyborg", SubTypeSet.CreatureType, true), // Star Wars
|
CYBORG("Cyborg", SubTypeSet.CreatureType, true), // Star Wars
|
||||||
CYCLOPS("Cyclops", SubTypeSet.CreatureType),
|
CYCLOPS("Cyclops", SubTypeSet.CreatureType),
|
||||||
// D
|
// D
|
||||||
|
|
Loading…
Reference in a new issue