mirror of
https://github.com/magefree/mage.git
synced 2026-01-26 21:29:17 -08:00
remove DamageDoneWatcher from default watchers
This commit is contained in:
parent
c164d70135
commit
6155f2d403
5 changed files with 11 additions and 6 deletions
|
|
@ -21,6 +21,7 @@ import mage.constants.*;
|
|||
import mage.filter.FilterSpell;
|
||||
import mage.filter.predicate.mageobject.ColorPredicate;
|
||||
import mage.target.common.TargetPlayerOrPlaneswalker;
|
||||
import mage.watchers.common.DamageDoneWatcher;
|
||||
|
||||
/**
|
||||
*
|
||||
|
|
@ -52,7 +53,7 @@ public final class ChandraFireOfKaladesh extends CardImpl {
|
|||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new TapSourceCost());
|
||||
ability.addEffect(new ConditionalOneShotEffect(new ExileAndReturnSourceEffect(PutCards.BATTLEFIELD_TRANSFORMED,Pronoun.SHE), new SourceDealtDamageCondition(3)));
|
||||
ability.addTarget(new TargetPlayerOrPlaneswalker());
|
||||
this.addAbility(ability);
|
||||
this.addAbility(ability, new DamageDoneWatcher());
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -38,6 +38,8 @@ public final class NeedleDrop extends CardImpl {
|
|||
|
||||
// Draw a card.
|
||||
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1).concatBy("<br>"));
|
||||
|
||||
this.getSpellAbility().addWatcher(new DamageDoneWatcher());
|
||||
}
|
||||
|
||||
private NeedleDrop(final NeedleDrop card) {
|
||||
|
|
|
|||
|
|
@ -37,7 +37,8 @@ public class WaveOfRats extends CardImpl {
|
|||
this.addAbility(new ConditionalInterveningIfTriggeredAbility(
|
||||
new DiesSourceTriggeredAbility(new ReturnToBattlefieldUnderOwnerControlSourceEffect()),
|
||||
WaveOfRatsDealtDamageToPlayerCondition.instance,
|
||||
"When Wave of Rats dies, if it dealt combat damage to a player this turn, return it to the battlefield under its owner's control.")
|
||||
"When Wave of Rats dies, if it dealt combat damage to a player this turn, return it to the battlefield under its owner's control."),
|
||||
new DamageDoneWatcher()
|
||||
);
|
||||
|
||||
// Blitz {4}{B} (If you cast this spell for its blitz cost, it gains haste and “When this creature dies, draw a card.” Sacrifice it at the beginning of the next end step.)
|
||||
|
|
@ -69,4 +70,4 @@ enum WaveOfRatsDealtDamageToPlayerCondition implements Condition {
|
|||
}
|
||||
return watcher.damagedAPlayer(waveOfRats.getId(), waveOfRats.getZoneChangeCounter(game), game);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,10 +9,12 @@ import mage.watchers.common.DamageDoneWatcher;
|
|||
*
|
||||
* @author LevelX2
|
||||
*/
|
||||
|
||||
public class SourceDealtDamageCondition implements Condition {
|
||||
private final int value;
|
||||
|
||||
/**
|
||||
* Must add DamageDoneWatcher on card init
|
||||
*/
|
||||
public SourceDealtDamageCondition(int value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
|
@ -29,4 +31,4 @@ public class SourceDealtDamageCondition implements Condition {
|
|||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1339,7 +1339,6 @@ public abstract class GameImpl implements Game {
|
|||
newWatchers.add(new CastSpellLastTurnWatcher());
|
||||
newWatchers.add(new PlayerLostLifeWatcher());
|
||||
newWatchers.add(new BlockedAttackerWatcher());
|
||||
newWatchers.add(new DamageDoneWatcher()); // TODO: no need to be default watcher
|
||||
newWatchers.add(new PlanarRollWatcher()); // TODO: no need to be default watcher
|
||||
newWatchers.add(new AttackedThisTurnWatcher());
|
||||
newWatchers.add(new CardsDrawnThisTurnWatcher());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue