mirror of
https://github.com/correl/mage.git
synced 2025-03-17 01:06:26 -09:00
- Fixed #8389
This commit is contained in:
parent
1de223f7da
commit
8b36c70507
2 changed files with 16 additions and 13 deletions
|
@ -9,6 +9,7 @@ import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.Duration;
|
import mage.constants.Duration;
|
||||||
|
import mage.constants.Outcome;
|
||||||
import mage.target.common.TargetCreaturePermanent;
|
import mage.target.common.TargetCreaturePermanent;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -25,6 +26,7 @@ public final class SavageSurge extends CardImpl {
|
||||||
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
|
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||||
this.getSpellAbility().addEffect(new BoostTargetEffect(2, 2, Duration.EndOfTurn));
|
this.getSpellAbility().addEffect(new BoostTargetEffect(2, 2, Duration.EndOfTurn));
|
||||||
Effect effect = new UntapTargetEffect();
|
Effect effect = new UntapTargetEffect();
|
||||||
|
effect.setOutcome(Outcome.Benefit);
|
||||||
effect.setText("Untap that creature");
|
effect.setText("Untap that creature");
|
||||||
this.getSpellAbility().addEffect(effect);
|
this.getSpellAbility().addEffect(effect);
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,8 +53,8 @@ class VeyranVoiceOfDualityEffect extends ReplacementEffectImpl {
|
||||||
|
|
||||||
VeyranVoiceOfDualityEffect() {
|
VeyranVoiceOfDualityEffect() {
|
||||||
super(Duration.WhileOnBattlefield, Outcome.Benefit);
|
super(Duration.WhileOnBattlefield, Outcome.Benefit);
|
||||||
staticText = "if you casting or copying an instant or sorcery spell causes a triggered ability " +
|
staticText = "if you casting or copying an instant or sorcery spell causes a triggered ability "
|
||||||
"of a permanent you control to trigger, that ability triggers an additional time";
|
+ "of a permanent you control to trigger, that ability triggers an additional time";
|
||||||
}
|
}
|
||||||
|
|
||||||
private VeyranVoiceOfDualityEffect(final VeyranVoiceOfDualityEffect effect) {
|
private VeyranVoiceOfDualityEffect(final VeyranVoiceOfDualityEffect effect) {
|
||||||
|
@ -73,19 +73,20 @@ class VeyranVoiceOfDualityEffect extends ReplacementEffectImpl {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean applies(GameEvent event, Ability source, Game game) {
|
public boolean applies(GameEvent event, Ability source, Game game) {
|
||||||
GameEvent sourceEvent = ((NumberOfTriggersEvent) event).getSourceEvent();
|
NumberOfTriggersEvent numberOfTriggersEvent = (NumberOfTriggersEvent) event;
|
||||||
if (sourceEvent.getType() != GameEvent.EventType.COPIED_STACKOBJECT
|
GameEvent sourceEvent = numberOfTriggersEvent.getSourceEvent();
|
||||||
&& sourceEvent.getType() != GameEvent.EventType.SPELL_CAST) {
|
if (sourceEvent.getType() == GameEvent.EventType.SPELL_CAST
|
||||||
return false;
|
|| sourceEvent.getType() == GameEvent.EventType.COPIED_STACKOBJECT) {
|
||||||
}
|
|
||||||
Spell spell = game.getSpell(sourceEvent.getTargetId());
|
Spell spell = game.getSpell(sourceEvent.getTargetId());
|
||||||
Permanent permanent = game.getPermanent(sourceEvent.getSourceId());
|
Permanent permanent = game.getPermanent(((NumberOfTriggersEvent) event).getSourceId());
|
||||||
return spell != null
|
return spell != null
|
||||||
&& permanent != null
|
&& permanent != null
|
||||||
&& spell.isInstantOrSorcery(game)
|
&& spell.isInstantOrSorcery(game)
|
||||||
&& spell.isControlledBy(source.getControllerId())
|
&& spell.isControlledBy(source.getControllerId())
|
||||||
&& permanent.isControlledBy(source.getControllerId());
|
&& permanent.isControlledBy(source.getControllerId());
|
||||||
}
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean replaceEvent(GameEvent event, Ability source, Game game) {
|
public boolean replaceEvent(GameEvent event, Ability source, Game game) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue