mirror of
https://github.com/correl/mage.git
synced 2024-12-24 11:50:45 +00:00
Card fixes DeclarationInStone, Odric, WolfOfDevil (SOI)
This commit is contained in:
parent
a15f206233
commit
582bd1b4bb
3 changed files with 15 additions and 3 deletions
|
@ -36,6 +36,9 @@ import mage.constants.CardType;
|
|||
import mage.constants.Outcome;
|
||||
import mage.constants.Rarity;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.permanent.TokenPredicate;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.game.permanent.token.ClueArtifactToken;
|
||||
|
@ -70,6 +73,11 @@ public class DeclarationInStone extends CardImpl {
|
|||
}
|
||||
|
||||
class DeclarationInStoneEffect extends OneShotEffect {
|
||||
|
||||
private static final FilterCreaturePermanent nonTokenFilter = new FilterCreaturePermanent("nontoken creature");
|
||||
static{
|
||||
nonTokenFilter.add(Predicates.not(new TokenPredicate()));
|
||||
}
|
||||
|
||||
public DeclarationInStoneEffect() {
|
||||
super(Outcome.Exile);
|
||||
|
@ -99,7 +107,11 @@ class DeclarationInStoneEffect extends OneShotEffect {
|
|||
for (Permanent permanent : game.getBattlefield().getAllActivePermanents(controllerPermanentId)) {
|
||||
if (permanent != null && permanent.getName().equals(name)) {
|
||||
you.moveCardToExileWithInfo(permanent, exileId, sourceObject.getIdName(), source.getSourceId(), game, Zone.BATTLEFIELD, true);
|
||||
exiledCount++;
|
||||
|
||||
// exiled count only matters for non-tokens
|
||||
if (nonTokenFilter.match(permanent, game)) {
|
||||
exiledCount++;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -72,7 +72,7 @@ public class OdricLunarchMarshal extends CardImpl {
|
|||
this.toughness = new MageInt(3);
|
||||
|
||||
// At the beginning of each combat, creatures you control gain first strike until end of turn if a creature you control has first strike. The same is true for flying, deathtouch, double strike, haste, hexproof, indestructible, lifelink, menace, reach, skulk, trample, and vigilance.
|
||||
this.addAbility(new BeginningOfCombatTriggeredAbility(new OdricLunarchMarshalEffect(), TargetController.YOU, false));
|
||||
this.addAbility(new BeginningOfCombatTriggeredAbility(new OdricLunarchMarshalEffect(), TargetController.ANY, false));
|
||||
}
|
||||
|
||||
public OdricLunarchMarshal(final OdricLunarchMarshal card) {
|
||||
|
|
|
@ -57,7 +57,7 @@ public class WolfOfDevilsBreach extends CardImpl {
|
|||
|
||||
// Whenever Wolf of Devil's Breach attacks, you may pay {1}{R} and discard a card. If you do, Wolf of Devil's Breach deals
|
||||
// damage to target creature or planeswalker equal to the discarded card's converted mana cost.
|
||||
Ability ability = new AttacksTriggeredAbility(new DoIfCostPaid(new DamageTargetEffect(new DiscardCostCardConvertedMana()), new ManaCostsImpl("{1}{R}")), false,
|
||||
Ability ability = new AttacksTriggeredAbility(new DoIfCostPaid(new DamageTargetEffect(new DiscardCostCardConvertedMana()), new ManaCostsImpl("{1}{R}")), true,
|
||||
"Whenever {this} attacks you may pay {1}{R} and discard a card. If you do, {this} deals damage to target creature or planeswalker "
|
||||
+ "equal to the discarded card's converted mana cost.");
|
||||
ability.addCost(new DiscardCardCost());
|
||||
|
|
Loading…
Reference in a new issue