mirror of
https://github.com/correl/mage.git
synced 2024-12-25 11:11:16 +00:00
Fix card text
This commit is contained in:
parent
01e9e4b066
commit
b69093dfdd
7 changed files with 25 additions and 45 deletions
|
@ -39,7 +39,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterControlledLandPermanent;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.common.TargetControlledPermanent;
|
||||
import mage.target.common.TargetLandPermanent;
|
||||
|
||||
|
@ -59,7 +59,7 @@ public class ArmyAnts extends CardImpl {
|
|||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,
|
||||
new DestroyTargetEffect(),
|
||||
new TapSourceCost());
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent())));
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(StaticFilters.FILTER_CONTROLLED_LAND_SHORT_TEXT)));
|
||||
ability.addTarget(new TargetLandPermanent());
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
|
@ -35,7 +35,6 @@ import mage.abilities.costs.CostImpl;
|
|||
import mage.abilities.costs.common.TapSourceCost;
|
||||
import mage.abilities.costs.mana.GenericManaCost;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.RestrictionEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect;
|
||||
import mage.abilities.keyword.EquipAbility;
|
||||
import mage.cards.CardImpl;
|
||||
|
@ -48,6 +47,10 @@ import mage.target.common.TargetCreatureOrPlayer;
|
|||
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesAttachedEffect;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.mageobject.SubtypePredicate;
|
||||
|
||||
/**
|
||||
*
|
||||
|
@ -55,17 +58,27 @@ import java.util.UUID;
|
|||
*/
|
||||
public class BlazingTorch extends CardImpl {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Vampires or Zombies");
|
||||
static {
|
||||
filter.add(Predicates.or(new SubtypePredicate(SubType.VAMPIRE),
|
||||
new SubtypePredicate(SubType.ZOMBIE)));
|
||||
}
|
||||
|
||||
public BlazingTorch(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{1}");
|
||||
this.subtype.add(SubType.EQUIPMENT);
|
||||
|
||||
// Equipped creature can't be blocked by Vampires or Zombies. (!this is a static ability of the equipment)
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BlazingTorchEvasionEffect()));
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD,
|
||||
new CantBeBlockedByCreaturesAttachedEffect(Duration.WhileOnBattlefield, filter, AttachmentType.EQUIPMENT)));
|
||||
|
||||
|
||||
// Equipped creature has "{tap}, Sacrifice Blazing Torch: Blazing Torch deals 2 damage to target creature or player.")
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BlazingTorchDamageEffect(), new TapSourceCost());
|
||||
ability.addCost(new BlazingTorchCost());
|
||||
ability.addTarget(new TargetCreatureOrPlayer());
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(ability, AttachmentType.EQUIPMENT)));
|
||||
|
||||
// Equip {1}
|
||||
this.addAbility(new EquipAbility(Outcome.BoostCreature, new GenericManaCost(1)));
|
||||
}
|
||||
|
@ -80,40 +93,6 @@ public class BlazingTorch extends CardImpl {
|
|||
}
|
||||
}
|
||||
|
||||
class BlazingTorchEvasionEffect extends RestrictionEffect {
|
||||
|
||||
public BlazingTorchEvasionEffect() {
|
||||
super(Duration.WhileOnBattlefield);
|
||||
staticText = "Equipped creature can't be blocked by Vampires or Zombies";
|
||||
}
|
||||
|
||||
public BlazingTorchEvasionEffect(final BlazingTorchEvasionEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean applies(Permanent permanent, Ability source, Game game) {
|
||||
Permanent equipment = game.getPermanent(source.getSourceId());
|
||||
if (equipment != null && equipment.getAttachedTo() != null) {
|
||||
Permanent equipped = game.getPermanent(equipment.getAttachedTo());
|
||||
if (equipped != null && permanent.getId().equals(equipped.getId())) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canBeBlocked(Permanent attacker, Permanent blocker, Ability source, Game game) {
|
||||
return !blocker.hasSubtype(SubType.VAMPIRE, game) && !blocker.hasSubtype(SubType.ZOMBIE, game);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BlazingTorchEvasionEffect copy() {
|
||||
return new BlazingTorchEvasionEffect(this);
|
||||
}
|
||||
}
|
||||
|
||||
class BlazingTorchCost extends CostImpl {
|
||||
|
||||
public BlazingTorchCost() {
|
||||
|
|
|
@ -44,9 +44,9 @@ public class CruelEdict extends CardImpl {
|
|||
public CruelEdict(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{B}");
|
||||
|
||||
this.getSpellAbility().addEffect(new SacrificeEffect(StaticFilters.FILTER_PERMANENT_CREATURE, 1, "Target opponent sacrifices a creature"));
|
||||
this.getSpellAbility().addTarget(new TargetOpponent());
|
||||
// Target opponent sacrifices a creature.
|
||||
this.getSpellAbility().addEffect(new SacrificeEffect(StaticFilters.FILTER_PERMANENT_CREATURE, 1, "Target opponent"));
|
||||
this.getSpellAbility().addTarget(new TargetOpponent());
|
||||
}
|
||||
|
||||
public CruelEdict(final CruelEdict card) {
|
||||
|
|
|
@ -63,7 +63,7 @@ public class HibernationSliver extends CardImpl {
|
|||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new PayLifeCost(2));
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD,
|
||||
new GainAbilityAllEffect(ability, Duration.WhileOnBattlefield,
|
||||
new FilterPermanent(SubType.SLIVER, "All Slivers"), "All Slivers have \"Pay 2 life: Return this permanent to its owner's hand")));
|
||||
new FilterPermanent(SubType.SLIVER, "All Slivers"), "All Slivers have \"Pay 2 life: Return this permanent to its owner's hand.\"")));
|
||||
}
|
||||
|
||||
public HibernationSliver(final HibernationSliver card) {
|
||||
|
|
|
@ -42,6 +42,7 @@ import mage.abilities.keyword.TrampleAbility;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.*;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.filter.common.FilterControlledCreaturePermanent;
|
||||
import mage.target.TargetPermanent;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
@ -65,7 +66,7 @@ public class OniPossession extends CardImpl {
|
|||
|
||||
// At the beginning of your upkeep, sacrifice a creature.
|
||||
Ability ability2 = new BeginningOfUpkeepTriggeredAbility(
|
||||
new SacrificeControllerEffect(new FilterControlledCreaturePermanent(), 1, ""), TargetController.YOU, false);
|
||||
new SacrificeControllerEffect(new FilterControlledCreaturePermanent(StaticFilters.FILTER_CONTROLLED_CREATURE_SHORT_TEXT), 1, ""), TargetController.YOU, false);
|
||||
this.addAbility(ability2);
|
||||
// Enchanted creature gets +3/+3 and has trample.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(3, 3, Duration.WhileOnBattlefield)));
|
||||
|
|
|
@ -30,7 +30,7 @@ package mage.cards.s;
|
|||
import java.util.UUID;
|
||||
import mage.ObjectColor;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.common.AsEntersBattlefieldAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.effects.ContinuousEffectImpl;
|
||||
import mage.abilities.effects.common.ChooseColorEffect;
|
||||
|
@ -59,7 +59,7 @@ public class ShiftingSky extends CardImpl {
|
|||
super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{U}");
|
||||
|
||||
// As Shifting Sky enters the battlefield, choose a color.
|
||||
this.addAbility(new EntersBattlefieldTriggeredAbility(new ChooseColorEffect(Outcome.Detriment)));
|
||||
this.addAbility(new AsEntersBattlefieldAbility(new ChooseColorEffect(Outcome.Detriment)));
|
||||
|
||||
// All nonland permanents are the chosen color.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ShiftingSkyEffect()));
|
||||
|
|
|
@ -56,7 +56,7 @@ public class SoltariChampion extends CardImpl {
|
|||
// Shadow
|
||||
this.addAbility(ShadowAbility.getInstance());
|
||||
// Whenever Soltari Champion attacks, other creatures you control get +1/+1 until end of turn.
|
||||
this.addAbility(new AttacksTriggeredAbility(new BoostControlledEffect(1, 1, Duration.EndOfTurn, StaticFilters.FILTER_PERMANENT_CREATURE, true), false));
|
||||
this.addAbility(new AttacksTriggeredAbility(new BoostControlledEffect(1, 1, Duration.EndOfTurn, StaticFilters.FILTER_PERMANENT_CREATURES, true), false));
|
||||
}
|
||||
|
||||
public SoltariChampion(final SoltariChampion card) {
|
||||
|
|
Loading…
Reference in a new issue