Fixed a rare divide by zero error game crash affecting some cards (such as the Merry, From O'er the Brandywine errata)
This commit is contained in:
@@ -52,7 +52,7 @@ public class ModifyStrength implements EffectAppenderProducer {
|
|||||||
LotroGame game = actionContext.getGame();
|
LotroGame game = actionContext.getGame();
|
||||||
final int amount = evaluator.evaluateExpression(game, actionContext.getSource());
|
final int amount = evaluator.evaluateExpression(game, actionContext.getSource());
|
||||||
|
|
||||||
if (limit != -1) {
|
if (limit != -1 && amount != 0) {
|
||||||
int absAmount = Math.abs(amount);
|
int absAmount = Math.abs(amount);
|
||||||
int multiplier = absAmount / amount;
|
int multiplier = absAmount / amount;
|
||||||
List<Modifier> modifiers = new LinkedList<>();
|
List<Modifier> modifiers = new LinkedList<>();
|
||||||
|
|||||||
Reference in New Issue
Block a user