forked from External/mage
correction: wrong code usage on Grievous Wound
This commit is contained in:
parent
2c23370bf6
commit
78ed652f82
1 changed files with 2 additions and 5 deletions
|
|
@ -15,7 +15,6 @@ import mage.game.permanent.Permanent;
|
|||
import mage.target.TargetPlayer;
|
||||
import mage.target.targetpointer.FixedTarget;
|
||||
|
||||
import java.util.Optional;
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
|
|
@ -76,10 +75,8 @@ class GrievousWoundTriggeredAbility extends TriggeredAbilityImpl {
|
|||
|
||||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
if (!Optional
|
||||
.ofNullable(getSourcePermanentIfItStillExists(game))
|
||||
.map(Permanent::getAttachedTo)
|
||||
.equals(event.getTargetId())) {
|
||||
Permanent attachment = getSourcePermanentIfItStillExists(game);
|
||||
if (attachment == null || !event.getTargetId().equals(attachment.getAttachedTo())) {
|
||||
return false;
|
||||
}
|
||||
this.getEffects().setTargetPointer(new FixedTarget(event.getTargetId()));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue