You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(Baron Rivendare + Skeleton Knight / Anub'Arak issues) ReturnMinionToHandSpell should check if the minion is still on the battlefield before trying to remove it
#346
Open
doctorpangloss opened this issue
May 7, 2017
· 1 comment
ReturnMinionToHandSpell from deathrattles shouldn't try to getLogic().removeMinion if the minion isn't on the battlefield anymore. Otherwise, if Baron Rivendare is in play, two copies of the minion will appear in the set aside zone and glitch out effects further down the line.
I think this issue can be resolved if the second battlecry action checks that its target is still valid. This might look something like...
finalEntityReferencetarget = battlecryAction.getSpell().hasPredefinedTarget() ? battlecryAction.getSpell().getTarget() : battlecryAction.getTargetKey();
finalbooleantargetable = target == null || target.isTargetGroup() ||
/* The target is still among the valid targets for the action */getValidTargets(playerId, battlecryAction).stream().map(EntityReference::pointTo).anyMatch(er -> er.equals(target));
if (!battlecryAction.canBeExecuted(context, player) || !targetable) {
return;
}
The text was updated successfully, but these errors were encountered:
ReturnMinionToHandSpell
from deathrattles shouldn't try togetLogic().removeMinion
if the minion isn't on the battlefield anymore. Otherwise, if Baron Rivendare is in play, two copies of the minion will appear in the set aside zone and glitch out effects further down the line.I think this issue can be resolved if the second battlecry action checks that its target is still valid. This might look something like...
The text was updated successfully, but these errors were encountered: