various fixes from recent implementations

This commit is contained in:
xenohedron 2024-09-06 22:15:35 -04:00
parent 0cd6ec39b2
commit cd99594c38
10 changed files with 16 additions and 11 deletions

View file

@ -30,7 +30,7 @@ public final class AttackInTheBox extends CardImpl {
// Whenever Attack-in-the-Box attacks, you may have it get +4/+0 until end of turn. If you do, sacrifice it at the beginning of the next end step.
Ability ability = new AttacksTriggeredAbility(new BoostSourceEffect(
4, 0, Duration.EndOfTurn
).setText("have it get +4/+0 until end of turn"));
).setText("have it get +4/+0 until end of turn"), true);
ability.addEffect(new CreateDelayedTriggeredAbilityEffect(
new AtTheBeginOfNextEndStepDelayedTriggeredAbility(new SacrificeSourceEffect())
).setText("If you do, sacrifice it at the beginning of the next end step"));

View file

@ -29,7 +29,7 @@ public final class DashingBloodsucker extends CardImpl {
// Eerie -- Whenever an enchantment you control enters and whenever you fully unlock a Room, Dashing Bloodsucker gets +2/+0 and gains lifelink until end of turn.
Ability ability = new EerieAbility(new BoostSourceEffect(2, 0, Duration.EndOfTurn).setText("{this} gets +2/+0"));
ability.addEffect(new GainAbilitySourceEffect(LifelinkAbility.getInstance()).setText("and gains lifelink until end of turn"));
ability.addEffect(new GainAbilitySourceEffect(LifelinkAbility.getInstance(), Duration.EndOfTurn).setText("and gains lifelink until end of turn"));
this.addAbility(ability);
}

View file

@ -2,6 +2,8 @@ package mage.cards.f;
import java.util.UUID;
import mage.MageInt;
import mage.abilities.common.AttacksTriggeredAbility;
import mage.abilities.effects.keyword.SurveilEffect;
import mage.constants.SubType;
import mage.abilities.keyword.VigilanceAbility;
import mage.cards.CardImpl;
@ -25,6 +27,7 @@ public final class FearOfSurveillance extends CardImpl {
this.addAbility(VigilanceAbility.getInstance());
// Whenever Fear of Surveillance attacks, surveil 1.
this.addAbility(new AttacksTriggeredAbility(new SurveilEffect(1)));
}
private FearOfSurveillance(final FearOfSurveillance card) {

View file

@ -36,7 +36,7 @@ public final class HandThatFeeds extends CardImpl {
DeliriumCondition.instance, "Whenever {this} attacks while there are four or more " +
"card types among cards in your graveyard, it gets +2/+0 and gains menace until end of turn."
);
ability.addEffect(new GainAbilitySourceEffect(new MenaceAbility(false)));
ability.addEffect(new GainAbilitySourceEffect(new MenaceAbility(false), Duration.EndOfTurn));
this.addAbility(ability.setAbilityWord(AbilityWord.DELIRIUM).addHint(CardTypesInGraveyardHint.YOU));
}

View file

@ -31,12 +31,9 @@ import mage.target.TargetPermanent;
public final class MjolnirStormHammer extends CardImpl {
private static final FilterPermanent filter = new FilterCreaturePermanent("creature defending player controls");
private static final FilterPermanent filter2 = new FilterCreaturePermanent("tapped creatures that opponent controls");
static {
filter.add(DefendingPlayerControlsAttachedAttackingPredicate.instance);
filter2.add(DefendingPlayerControlsAttachedAttackingPredicate.instance);
filter2.add(TappedPredicate.TAPPED);
}
public MjolnirStormHammer(UUID ownerId, CardSetInfo setInfo) {

View file

@ -20,6 +20,7 @@ import mage.filter.StaticFilters;
import mage.filter.common.FilterControlledPermanent;
import mage.filter.predicate.Predicates;
import mage.filter.predicate.mageobject.AnotherPredicate;
import mage.target.common.TargetOpponent;
import java.util.UUID;
@ -59,6 +60,7 @@ public final class PopularEgotist extends CardImpl {
ability = new SacrificePermanentTriggeredAbility(
new LoseLifeTargetEffect(1), StaticFilters.FILTER_PERMANENT
);
ability.addTarget(new TargetOpponent());
ability.addEffect(new GainLifeEffect(1).concatBy("and"));
this.addAbility(ability);
}

View file

@ -74,6 +74,7 @@ class StarfallInvocationEffect extends OneShotEffect {
}
if (controller != null && GiftWasPromisedCondition.TRUE.apply(game, source)) {
game.processAction();
TargetCard target = new TargetCardInYourGraveyard();
controller.choose(Outcome.PutCreatureInPlay, yourCreatureCards, target, source, game);
Card targetCard = game.getCard(target.getFirstTarget());
@ -83,4 +84,4 @@ class StarfallInvocationEffect extends OneShotEffect {
}
return true;
}
}
}

View file

@ -9,7 +9,7 @@ import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.filter.FilterPermanent;
import mage.filter.StaticFilters;
import mage.filter.common.FilterCreaturePermanent;
import mage.filter.common.FilterControlledPermanent;
import mage.filter.predicate.card.FaceDownPredicate;
import mage.target.common.TargetCardInLibrary;
@ -20,7 +20,7 @@ import java.util.UUID;
*/
public final class ThreatsAroundEveryCorner extends CardImpl {
private static final FilterPermanent filter = new FilterCreaturePermanent("a face-down permanent you control");
private static final FilterPermanent filter = new FilterControlledPermanent("a face-down permanent you control");
static {
filter.add(FaceDownPredicate.instance);

View file

@ -8,6 +8,7 @@ import mage.abilities.keyword.WardAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.TargetController;
import mage.filter.FilterPermanent;
import mage.filter.predicate.Predicates;
import mage.target.TargetPermanent;
@ -22,6 +23,7 @@ public final class TrappedInTheScreen extends CardImpl {
private static final FilterPermanent filter = new FilterPermanent("artifact, creature, or enchantment an opponent controls");
static {
filter.add(TargetController.OPPONENT.getControllerPredicate());
filter.add(Predicates.or(
CardType.ARTIFACT.getPredicate(),
CardType.CREATURE.getPredicate(),

View file

@ -19,8 +19,8 @@ import java.util.UUID;
*/
public class SearchLibraryPutInHandEffect extends SearchEffect {
private boolean reveal;
private boolean textThatCard;
private final boolean reveal;
private final boolean textThatCard;
public SearchLibraryPutInHandEffect(TargetCardInLibrary target, boolean reveal) {
this(target, reveal, false);