mirror of
https://github.com/magefree/mage.git
synced 2025-12-20 02:30:08 -08:00
[TLA] Implement Leaves from the Vine
This commit is contained in:
parent
8cd27af5a5
commit
3188c157df
2 changed files with 87 additions and 0 deletions
86
Mage.Sets/src/mage/cards/l/LeavesFromTheVine.java
Normal file
86
Mage.Sets/src/mage/cards/l/LeavesFromTheVine.java
Normal file
|
|
@ -0,0 +1,86 @@
|
||||||
|
package mage.cards.l;
|
||||||
|
|
||||||
|
import mage.abilities.common.SagaAbility;
|
||||||
|
import mage.abilities.condition.Condition;
|
||||||
|
import mage.abilities.condition.common.CardsInControllerGraveyardCondition;
|
||||||
|
import mage.abilities.decorator.ConditionalOneShotEffect;
|
||||||
|
import mage.abilities.effects.common.CreateTokenEffect;
|
||||||
|
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||||
|
import mage.abilities.effects.common.MillCardsControllerEffect;
|
||||||
|
import mage.abilities.effects.common.counter.AddCountersTargetEffect;
|
||||||
|
import mage.abilities.hint.ConditionHint;
|
||||||
|
import mage.abilities.hint.Hint;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.CardType;
|
||||||
|
import mage.constants.SagaChapter;
|
||||||
|
import mage.constants.SubType;
|
||||||
|
import mage.counters.CounterType;
|
||||||
|
import mage.filter.FilterCard;
|
||||||
|
import mage.filter.predicate.Predicates;
|
||||||
|
import mage.game.permanent.token.FoodToken;
|
||||||
|
import mage.target.common.TargetControlledCreaturePermanent;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author TheElk801
|
||||||
|
*/
|
||||||
|
public final class LeavesFromTheVine extends CardImpl {
|
||||||
|
|
||||||
|
private static final FilterCard filter = new FilterCard();
|
||||||
|
|
||||||
|
static {
|
||||||
|
filter.add(Predicates.or(
|
||||||
|
CardType.CREATURE.getPredicate(),
|
||||||
|
SubType.LESSON.getPredicate()
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
|
private static final Condition condition = new CardsInControllerGraveyardCondition(1, filter);
|
||||||
|
private static final Hint hint = new ConditionHint(
|
||||||
|
condition, "There's a creature or Lesson card in your graveyard"
|
||||||
|
);
|
||||||
|
|
||||||
|
public LeavesFromTheVine(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}");
|
||||||
|
|
||||||
|
this.subtype.add(SubType.SAGA);
|
||||||
|
|
||||||
|
// (As this Saga enters and after your draw step, add a lore counter. Sacrifice after III.)
|
||||||
|
SagaAbility sagaAbility = new SagaAbility(this);
|
||||||
|
|
||||||
|
// I -- Mill three cards, then create a Food token.
|
||||||
|
sagaAbility.addChapterEffect(
|
||||||
|
this, SagaChapter.CHAPTER_I,
|
||||||
|
new MillCardsControllerEffect(3),
|
||||||
|
new CreateTokenEffect(new FoodToken()).concatBy(", then")
|
||||||
|
);
|
||||||
|
|
||||||
|
// II -- Put a +1/+1 counter on each of up to two target creatures you control.
|
||||||
|
sagaAbility.addChapterEffect(
|
||||||
|
this, SagaChapter.CHAPTER_II,
|
||||||
|
new AddCountersTargetEffect(CounterType.P1P1.createInstance()),
|
||||||
|
new TargetControlledCreaturePermanent(0, 2)
|
||||||
|
);
|
||||||
|
|
||||||
|
// III -- Draw a card if there's a creature or Lesson card in your graveyard.
|
||||||
|
sagaAbility.addChapterEffect(
|
||||||
|
this, SagaChapter.CHAPTER_III,
|
||||||
|
new ConditionalOneShotEffect(
|
||||||
|
new DrawCardSourceControllerEffect(1), condition,
|
||||||
|
"draw a card if there's a creature or Lesson card in your graveyard"
|
||||||
|
)
|
||||||
|
);
|
||||||
|
this.addAbility(sagaAbility);
|
||||||
|
}
|
||||||
|
|
||||||
|
private LeavesFromTheVine(final LeavesFromTheVine card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public LeavesFromTheVine copy() {
|
||||||
|
return new LeavesFromTheVine(this);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -106,6 +106,7 @@ public final class AvatarTheLastAirbender extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Katara, the Fearless", 305, Rarity.RARE, mage.cards.k.KataraTheFearless.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Katara, the Fearless", 305, Rarity.RARE, mage.cards.k.KataraTheFearless.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Katara, the Fearless", 350, Rarity.RARE, mage.cards.k.KataraTheFearless.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Katara, the Fearless", 350, Rarity.RARE, mage.cards.k.KataraTheFearless.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Katara, the Fearless", 361, Rarity.RARE, mage.cards.k.KataraTheFearless.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Katara, the Fearless", 361, Rarity.RARE, mage.cards.k.KataraTheFearless.class, NON_FULL_USE_VARIOUS));
|
||||||
|
cards.add(new SetCardInfo("Leaves from the Vine", 185, Rarity.UNCOMMON, mage.cards.l.LeavesFromTheVine.class));
|
||||||
cards.add(new SetCardInfo("Lightning Strike", 146, Rarity.COMMON, mage.cards.l.LightningStrike.class));
|
cards.add(new SetCardInfo("Lightning Strike", 146, Rarity.COMMON, mage.cards.l.LightningStrike.class));
|
||||||
cards.add(new SetCardInfo("Long Feng, Grand Secretariat", 233, Rarity.UNCOMMON, mage.cards.l.LongFengGrandSecretariat.class));
|
cards.add(new SetCardInfo("Long Feng, Grand Secretariat", 233, Rarity.UNCOMMON, mage.cards.l.LongFengGrandSecretariat.class));
|
||||||
cards.add(new SetCardInfo("Master Pakku", 63, Rarity.UNCOMMON, mage.cards.m.MasterPakku.class));
|
cards.add(new SetCardInfo("Master Pakku", 63, Rarity.UNCOMMON, mage.cards.m.MasterPakku.class));
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue