mirror of
https://github.com/correl/mage.git
synced 2024-12-26 11:09:27 +00:00
Implement Kyscu Drake
This commit is contained in:
parent
034ea931ce
commit
32bbcc6b53
1 changed files with 67 additions and 0 deletions
67
Mage.Sets/src/mage/cards/k/KyscuDrake.java
Normal file
67
Mage.Sets/src/mage/cards/k/KyscuDrake.java
Normal file
|
@ -0,0 +1,67 @@
|
||||||
|
package mage.cards.k;
|
||||||
|
|
||||||
|
import mage.MageInt;
|
||||||
|
import mage.abilities.Ability;
|
||||||
|
import mage.abilities.common.LimitedTimesPerTurnActivatedAbility;
|
||||||
|
import mage.abilities.common.SimpleActivatedAbility;
|
||||||
|
import mage.abilities.costs.common.SacrificeSourceCost;
|
||||||
|
import mage.abilities.costs.common.SacrificeTargetCost;
|
||||||
|
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||||
|
import mage.abilities.effects.common.continuous.BoostSourceEffect;
|
||||||
|
import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect;
|
||||||
|
import mage.abilities.keyword.FlyingAbility;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.*;
|
||||||
|
import mage.filter.FilterCard;
|
||||||
|
import mage.filter.common.FilterControlledCreaturePermanent;
|
||||||
|
import mage.filter.predicate.mageobject.NamePredicate;
|
||||||
|
import mage.target.common.TargetCardInLibrary;
|
||||||
|
import mage.target.common.TargetControlledCreaturePermanent;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @author jmharmon
|
||||||
|
*/
|
||||||
|
|
||||||
|
public final class KyscuDrake extends CardImpl {
|
||||||
|
|
||||||
|
private static final FilterCard filter = new FilterCard("card named Viashivan Dragon");
|
||||||
|
private static final FilterControlledCreaturePermanent filterSpitting = new FilterControlledCreaturePermanent("creature named Spitting Drake");
|
||||||
|
static {
|
||||||
|
filter.add(new NamePredicate("Viashivan Dragon"));
|
||||||
|
filterSpitting.add(new NamePredicate("Spitting Drake"));
|
||||||
|
}
|
||||||
|
|
||||||
|
public KyscuDrake(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{G}");
|
||||||
|
this.subtype.add(SubType.DRAKE);
|
||||||
|
|
||||||
|
this.power = new MageInt(2);
|
||||||
|
this.toughness = new MageInt(2);
|
||||||
|
|
||||||
|
// Flying
|
||||||
|
this.addAbility(FlyingAbility.getInstance());
|
||||||
|
|
||||||
|
// {G}: Kyscu Drake gets +0/+1 until end of turn. Activate this ability only once each turn.
|
||||||
|
this.addAbility(new LimitedTimesPerTurnActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(0, 1, Duration.EndOfTurn), new ManaCostsImpl("{G}")));
|
||||||
|
|
||||||
|
// Sacrifice Kyscu Drake and a creature named Spitting Drake: Search your library for a card named Viashivan Dragon and put that card onto the battlefield. Then shuffle your library.
|
||||||
|
TargetCardInLibrary target = new TargetCardInLibrary(1, 1, new FilterCard(filter));
|
||||||
|
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new SearchLibraryPutInPlayEffect(target,true,true, Outcome.PutCardInPlay), new SacrificeSourceCost());
|
||||||
|
ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(1, 1, filterSpitting, false)));
|
||||||
|
this.addAbility(ability);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public KyscuDrake(final KyscuDrake card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public KyscuDrake copy() {
|
||||||
|
return new KyscuDrake(this);
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue