mirror of
https://github.com/magefree/mage.git
synced 2025-12-20 10:40:06 -08:00
[TLE] Implement Jet, Rebel Leader
This commit is contained in:
parent
97f57fc0e0
commit
ee99f7b094
3 changed files with 78 additions and 0 deletions
50
Mage.Sets/src/mage/cards/j/JetRebelLeader.java
Normal file
50
Mage.Sets/src/mage/cards/j/JetRebelLeader.java
Normal file
|
|
@ -0,0 +1,50 @@
|
||||||
|
package mage.cards.j;
|
||||||
|
|
||||||
|
import mage.MageInt;
|
||||||
|
import mage.abilities.common.AttacksTriggeredAbility;
|
||||||
|
import mage.abilities.effects.common.LookLibraryAndPickControllerEffect;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.*;
|
||||||
|
import mage.filter.FilterCard;
|
||||||
|
import mage.filter.common.FilterCreatureCard;
|
||||||
|
import mage.filter.predicate.mageobject.ManaValuePredicate;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author TheElk801
|
||||||
|
*/
|
||||||
|
public final class JetRebelLeader extends CardImpl {
|
||||||
|
|
||||||
|
private static final FilterCard filter = new FilterCreatureCard("creature card with mana value 3 or less");
|
||||||
|
|
||||||
|
static {
|
||||||
|
filter.add(new ManaValuePredicate(ComparisonType.FEWER_THAN, 4));
|
||||||
|
}
|
||||||
|
|
||||||
|
public JetRebelLeader(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{W}");
|
||||||
|
|
||||||
|
this.supertype.add(SuperType.LEGENDARY);
|
||||||
|
this.subtype.add(SubType.HUMAN);
|
||||||
|
this.subtype.add(SubType.REBEL);
|
||||||
|
this.subtype.add(SubType.ALLY);
|
||||||
|
this.power = new MageInt(3);
|
||||||
|
this.toughness = new MageInt(4);
|
||||||
|
|
||||||
|
// Whenever Jet attacks, look at the top five cards of your library. You may put a creature card with mana value 3 or less from among them onto the battlefield tapped and attacking. Put the rest on the bottom of your library in a random order.
|
||||||
|
this.addAbility(new AttacksTriggeredAbility(new LookLibraryAndPickControllerEffect(
|
||||||
|
5, 1, filter, PutCards.BATTLEFIELD_TAPPED_ATTACKING, PutCards.BOTTOM_RANDOM
|
||||||
|
)));
|
||||||
|
}
|
||||||
|
|
||||||
|
private JetRebelLeader(final JetRebelLeader card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public JetRebelLeader copy() {
|
||||||
|
return new JetRebelLeader(this);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -141,6 +141,8 @@ public final class AvatarTheLastAirbenderEternal extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Iroh, Dragon of the West", 194, Rarity.RARE, mage.cards.i.IrohDragonOfTheWest.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Iroh, Dragon of the West", 194, Rarity.RARE, mage.cards.i.IrohDragonOfTheWest.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Iroh, Firebending Instructor", 240, Rarity.UNCOMMON, mage.cards.i.IrohFirebendingInstructor.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Iroh, Firebending Instructor", 240, Rarity.UNCOMMON, mage.cards.i.IrohFirebendingInstructor.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Iroh, Firebending Instructor", 282, Rarity.UNCOMMON, mage.cards.i.IrohFirebendingInstructor.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Iroh, Firebending Instructor", 282, Rarity.UNCOMMON, mage.cards.i.IrohFirebendingInstructor.class, NON_FULL_USE_VARIOUS));
|
||||||
|
cards.add(new SetCardInfo("Jet, Rebel Leader", 172, Rarity.RARE, mage.cards.j.JetRebelLeader.class, NON_FULL_USE_VARIOUS));
|
||||||
|
cards.add(new SetCardInfo("Jet, Rebel Leader", 78, Rarity.RARE, mage.cards.j.JetRebelLeader.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Join the Dance", 50, Rarity.MYTHIC, mage.cards.j.JoinTheDance.class));
|
cards.add(new SetCardInfo("Join the Dance", 50, Rarity.MYTHIC, mage.cards.j.JoinTheDance.class));
|
||||||
cards.add(new SetCardInfo("Katara, Heroic Healer", 215, Rarity.UNCOMMON, mage.cards.k.KataraHeroicHealer.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Katara, Heroic Healer", 215, Rarity.UNCOMMON, mage.cards.k.KataraHeroicHealer.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Katara, Heroic Healer", 269, Rarity.UNCOMMON, mage.cards.k.KataraHeroicHealer.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Katara, Heroic Healer", 269, Rarity.UNCOMMON, mage.cards.k.KataraHeroicHealer.class, NON_FULL_USE_VARIOUS));
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,11 @@ import mage.cards.Card;
|
||||||
import mage.cards.Cards;
|
import mage.cards.Cards;
|
||||||
import mage.cards.CardsImpl;
|
import mage.cards.CardsImpl;
|
||||||
import mage.game.Game;
|
import mage.game.Game;
|
||||||
|
import mage.game.permanent.Permanent;
|
||||||
import mage.players.Player;
|
import mage.players.Player;
|
||||||
|
import mage.util.CardUtil;
|
||||||
|
|
||||||
|
import java.util.Set;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author awjackson
|
* @author awjackson
|
||||||
|
|
@ -17,6 +21,7 @@ public enum PutCards {
|
||||||
GRAVEYARD(Outcome.Discard, Zone.GRAVEYARD, "into your graveyard"),
|
GRAVEYARD(Outcome.Discard, Zone.GRAVEYARD, "into your graveyard"),
|
||||||
BATTLEFIELD(Outcome.PutCardInPlay, Zone.BATTLEFIELD, "onto the battlefield"),
|
BATTLEFIELD(Outcome.PutCardInPlay, Zone.BATTLEFIELD, "onto the battlefield"),
|
||||||
BATTLEFIELD_TAPPED(Outcome.PutCardInPlay, Zone.BATTLEFIELD, "onto the battlefield tapped"),
|
BATTLEFIELD_TAPPED(Outcome.PutCardInPlay, Zone.BATTLEFIELD, "onto the battlefield tapped"),
|
||||||
|
BATTLEFIELD_TAPPED_ATTACKING(Outcome.PutCardInPlay, Zone.BATTLEFIELD, "onto the battlefield tapped and attacking"),
|
||||||
BATTLEFIELD_TRANSFORMED(Outcome.PutCardInPlay, Zone.BATTLEFIELD, "onto the battlefield transformed"),
|
BATTLEFIELD_TRANSFORMED(Outcome.PutCardInPlay, Zone.BATTLEFIELD, "onto the battlefield transformed"),
|
||||||
EXILED(Outcome.Exile, Zone.EXILED, "into exile"), // may need special case code to generate correct text
|
EXILED(Outcome.Exile, Zone.EXILED, "into exile"), // may need special case code to generate correct text
|
||||||
TOP_OR_BOTTOM(Outcome.Benefit, Zone.LIBRARY, "on the top or bottom of your library"),
|
TOP_OR_BOTTOM(Outcome.Benefit, Zone.LIBRARY, "on the top or bottom of your library"),
|
||||||
|
|
@ -75,6 +80,15 @@ public enum PutCards {
|
||||||
return player.putCardsOnBottomOfLibrary(new CardsImpl(card), game, source, false);
|
return player.putCardsOnBottomOfLibrary(new CardsImpl(card), game, source, false);
|
||||||
case BATTLEFIELD_TAPPED:
|
case BATTLEFIELD_TAPPED:
|
||||||
return player.moveCards(card, Zone.BATTLEFIELD, source, game, true, false, false, null);
|
return player.moveCards(card, Zone.BATTLEFIELD, source, game, true, false, false, null);
|
||||||
|
case BATTLEFIELD_TAPPED_ATTACKING:
|
||||||
|
if (player.moveCards(card, Zone.BATTLEFIELD, source, game, true, false, false, null)) {
|
||||||
|
Permanent permanent = CardUtil.getPermanentFromCardPutToBattlefield(card, game);
|
||||||
|
if (permanent != null) {
|
||||||
|
game.getCombat().addAttackingCreature(permanent.getId(), game);
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
case SHUFFLE:
|
case SHUFFLE:
|
||||||
return player.shuffleCardsToLibrary(card, game, source);
|
return player.shuffleCardsToLibrary(card, game, source);
|
||||||
case BATTLEFIELD_TRANSFORMED:
|
case BATTLEFIELD_TRANSFORMED:
|
||||||
|
|
@ -101,6 +115,18 @@ public enum PutCards {
|
||||||
return player.putCardsOnBottomOfLibrary(cards, game, source, false);
|
return player.putCardsOnBottomOfLibrary(cards, game, source, false);
|
||||||
case BATTLEFIELD_TAPPED:
|
case BATTLEFIELD_TAPPED:
|
||||||
return player.moveCards(cards.getCards(game), Zone.BATTLEFIELD, source, game, true, false, false, null);
|
return player.moveCards(cards.getCards(game), Zone.BATTLEFIELD, source, game, true, false, false, null);
|
||||||
|
case BATTLEFIELD_TAPPED_ATTACKING:
|
||||||
|
Set<Card> cardSet = cards.getCards(game);
|
||||||
|
if (player.moveCards(cardSet, Zone.BATTLEFIELD, source, game, true, false, false, null)) {
|
||||||
|
for (Card card : cardSet) {
|
||||||
|
Permanent permanent = CardUtil.getPermanentFromCardPutToBattlefield(card, game);
|
||||||
|
if (permanent != null) {
|
||||||
|
game.getCombat().addAttackingCreature(permanent.getId(), game);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
case SHUFFLE:
|
case SHUFFLE:
|
||||||
return player.shuffleCardsToLibrary(cards, game, source);
|
return player.shuffleCardsToLibrary(cards, game, source);
|
||||||
case BATTLEFIELD_TRANSFORMED:
|
case BATTLEFIELD_TRANSFORMED:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue