mirror of
https://github.com/magefree/mage.git
synced 2026-01-26 21:29:17 -08:00
Yasharn, Implacable Earth - fixed game error on usage (wrong work with events)
This commit is contained in:
parent
e1e2232e58
commit
5f2edde20c
1 changed files with 6 additions and 5 deletions
|
|
@ -142,14 +142,15 @@ class YasharnImplacableEarthEffect extends ContinuousRuleModifyingEffectImpl {
|
|||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checksEventType(GameEvent event, Game game) {
|
||||
return event.getType() == GameEvent.EventType.ACTIVATE_ABILITY
|
||||
|| event.getType() == GameEvent.EventType.CAST_SPELL;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean applies(GameEvent event, Ability source, Game game) {
|
||||
Permanent permanent = game.getPermanentOrLKIBattlefield(event.getSourceId());
|
||||
if (event.getType() != GameEvent.EventType.ACTIVATE_ABILITY
|
||||
&& event.getType() != GameEvent.EventType.CAST_SPELL) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (event.getType() == GameEvent.EventType.ACTIVATE_ABILITY && permanent == null) {
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue