mirror of
https://github.com/magefree/mage.git
synced 2025-12-27 22:12:03 -08:00
* Verdant Sun's Avatar - Fixed possible null pointer exception.
This commit is contained in:
parent
c3157bbcde
commit
f65cf063ea
1 changed files with 2 additions and 2 deletions
|
|
@ -36,8 +36,8 @@ import mage.abilities.effects.OneShotEffect;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Zone;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
|
|
@ -91,7 +91,7 @@ class VerdantSunsAvatarTriggeredAbility extends TriggeredAbilityImpl {
|
|||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
Permanent permanent = game.getPermanent(event.getTargetId());
|
||||
if (permanent.isCreature()
|
||||
if (permanent != null && permanent.isCreature()
|
||||
&& permanent.getControllerId().equals(this.controllerId)) {
|
||||
Effect effect = this.getEffects().get(0);
|
||||
// Life is determined during resolution so it has to be retrieved there (e.g. Giant Growth before resolution)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue