Skip to content

Commit

Permalink
If you revealed a Dragon card or controlled a Dragon - fixed game err…
Browse files Browse the repository at this point in the history
…or on usage (miss watcher)
  • Loading branch information
JayDi85 committed Jun 17, 2023
1 parent c61095e commit e365aa7
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 1 deletion.
2 changes: 2 additions & 0 deletions Mage.Sets/src/mage/cards/d/DraconicRoar.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import mage.game.permanent.Permanent;
import mage.players.Player;
import mage.target.common.TargetCreaturePermanent;
import mage.watchers.common.DragonOnTheBattlefieldWhileSpellWasCastWatcher;

import java.util.UUID;

Expand All @@ -29,6 +30,7 @@ public DraconicRoar(UUID ownerId, CardSetInfo setInfo) {
// Draconic Roar deals 3 damage to target creature. If you revealed a Dragon card or controlled a Dragon as you cast Draconic Roar, Draconic Roar deals 3 damage to that creature's controller.
this.getSpellAbility().addEffect(new DraconicRoarEffect());
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
this.getSpellAbility().addWatcher(new DragonOnTheBattlefieldWhileSpellWasCastWatcher());
}

private DraconicRoar(final DraconicRoar card) {
Expand Down
3 changes: 2 additions & 1 deletion Mage.Sets/src/mage/cards/d/DragonlordsPrerogative.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.Zone;
import mage.watchers.common.DragonOnTheBattlefieldWhileSpellWasCastWatcher;

import java.util.UUID;

Expand All @@ -30,7 +31,7 @@ public DragonlordsPrerogative(UUID ownerId, CardSetInfo setInfo) {
new ConditionalContinuousRuleModifyingEffect(
new CantBeCounteredSourceEffect(), RevealedOrControlledDragonCondition.instance
).setText("if you revealed a Dragon card or controlled a Dragon as you cast this spell, this spell can't be countered")
));
), new DragonOnTheBattlefieldWhileSpellWasCastWatcher());

// Draw four cards.
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(4));
Expand Down
2 changes: 2 additions & 0 deletions Mage.Sets/src/mage/cards/f/FoulTongueInvocation.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import mage.constants.CardType;
import mage.filter.StaticFilters;
import mage.target.TargetPlayer;
import mage.watchers.common.DragonOnTheBattlefieldWhileSpellWasCastWatcher;

import java.util.UUID;

Expand All @@ -33,6 +34,7 @@ public FoulTongueInvocation(UUID ownerId, CardSetInfo setInfo) {
"If you revealed a Dragon card or controlled a Dragon as you cast this spell, you gain 4 life."
));
this.getSpellAbility().addTarget(new TargetPlayer());
this.getSpellAbility().addWatcher(new DragonOnTheBattlefieldWhileSpellWasCastWatcher());
}

private FoulTongueInvocation(final FoulTongueInvocation card) {
Expand Down
2 changes: 2 additions & 0 deletions Mage.Sets/src/mage/cards/s/SilumgarsScorn.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.target.TargetSpell;
import mage.watchers.common.DragonOnTheBattlefieldWhileSpellWasCastWatcher;

import java.util.UUID;

Expand All @@ -31,6 +32,7 @@ public SilumgarsScorn(UUID ownerId, CardSetInfo setInfo) {
"If you revealed a Dragon card or controlled a Dragon as you cast this spell, counter that spell instead"
));
this.getSpellAbility().addTarget(new TargetSpell());
this.getSpellAbility().addWatcher(new DragonOnTheBattlefieldWhileSpellWasCastWatcher());
}

private SilumgarsScorn(final SilumgarsScorn card) {
Expand Down

0 comments on commit e365aa7

Please sign in to comment.