From 647ca9a22a3bc490172c62c4d1c265f63691a814 Mon Sep 17 00:00:00 2001 From: Daniel Weipert Date: Wed, 20 Sep 2023 18:00:46 +0200 Subject: hotfix null statusEffect on postAction event --- resources/js/game.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/resources/js/game.js b/resources/js/game.js index 61e2211..5ab70bd 100644 --- a/resources/js/game.js +++ b/resources/js/game.js @@ -626,7 +626,9 @@ const Game = { } Game.addBattlePhaseEvent('postAction', monster, () => { - monster.statusEffect.turnsLeft--; + if (monster.statusEffect) { + monster.statusEffect.turnsLeft--; + } }); }, -- cgit v1.2.3