[AKH] Another fixes

This commit is contained in:
Styxo 2017-04-16 15:28:31 +02:00
parent fc794f74aa
commit c8e7c7fb15
4 changed files with 21 additions and 32 deletions

View file

@ -53,20 +53,25 @@ 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.setTargetPointer(new FirstTargetPointer());
Ability ability = new EntersBattlefieldTriggeredAbility(counters);
Effect damage = new DamageTargetEffect(new StaticValue(3), true, "", true);
damage.setTargetPointer(new SecondTargetPointer());
Ability ability = new EntersBattlefieldTriggeredAbility(counters);
ability.addTarget(new TargetControlledCreaturePermanent());
ability.addEffect(damage);
ability.addTarget(new TargetOpponent());
addAbility(ability);
this.addAbility(ability);
}
public ManticoreOfTheGauntlet(final ManticoreOfTheGauntlet card) {
@ -77,4 +82,4 @@ public class ManticoreOfTheGauntlet extends CardImpl {
public ManticoreOfTheGauntlet copy() {
return new ManticoreOfTheGauntlet(this);
}
}
}

View file

@ -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) {

View file

@ -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}")));

View file

@ -29,17 +29,13 @@ package mage.cards.s;
import java.util.UUID;
import mage.MageObject;
import mage.abilities.Ability;
import mage.abilities.effects.Effect;
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.game.Game;
import mage.filter.predicate.mageobject.AbilityPredicate;
import mage.target.common.TargetCardInYourGraveyard;
/**
@ -47,18 +43,18 @@ 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) {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{U}");
// Return up to two target cards with cycling from your graveyard to your hand.
Effect effect = new ReturnFromGraveyardToHandTargetEffect();
effect.setText("Return up to two target cards with cycling from your graveyard to your hand");
getSpellAbility().addEffect(effect);
getSpellAbility().addEffect(new ReturnFromGraveyardToHandTargetEffect());
getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, 2, cardsWithCycling));
}
@ -71,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;
}
}