mirror of
https://github.com/correl/mage.git
synced 2025-01-12 19:25:44 +00:00
* Zurgo Helmsmasher - Fixed that it got wrongly a +1/+1 counter also if a planeswalker was put into graveyard.
This commit is contained in:
parent
f2e59502ca
commit
217eaa55d7
1 changed files with 4 additions and 2 deletions
|
@ -3,6 +3,7 @@ package mage.abilities.common;
|
|||
import mage.MageObject;
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
|
@ -32,8 +33,9 @@ public class DiesAndDealtDamageThisTurnTriggeredAbility extends TriggeredAbility
|
|||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
if (event.getType() == GameEvent.EventType.ZONE_CHANGE && ((ZoneChangeEvent)event).isDiesEvent()) {
|
||||
MageObject object = game.getLastKnownInformation(event.getTargetId(), Zone.BATTLEFIELD);
|
||||
if (object instanceof Permanent && ((Permanent)object).getDealtDamageByThisTurn().contains(this.sourceId)) {
|
||||
ZoneChangeEvent zEvent = (ZoneChangeEvent) event;
|
||||
if (zEvent.getTarget().getCardType().contains(CardType.CREATURE) &&
|
||||
zEvent.getTarget().getDealtDamageByThisTurn().contains(this.sourceId)) {
|
||||
for (Effect effect : getEffects()) {
|
||||
effect.setTargetPointer(new FixedTarget(event.getTargetId()));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue