CardUtil overflow

This commit is contained in:
Zzooouhh 2017-12-23 23:45:21 +01:00 committed by GitHub
parent 17e5bbbd54
commit 67d495e1ce
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -46,6 +46,7 @@ import mage.game.permanent.Permanent;
import mage.filter.StaticFilters;
import mage.filter.predicate.permanent.ControllerPredicate;
import mage.players.Player;
import mage.util.CardUtil;
/**
*
@ -121,7 +122,7 @@ class ImpulsiveManeuversEffect extends PreventionEffectImpl {
DamageEvent damageEvent = (DamageEvent) event;
if (damageEvent.isCombatDamage()) {
if (wonFlip) {
event.setAmount(game.addWithOverflowCheck(event.getAmount(), event.getAmount()));
event.setAmount(CardUtil.addWithOverflowCheck(event.getAmount(), event.getAmount()));
this.discard();
} else {
preventDamageAction(event, source, game);