diff --git a/www/assets/js/player.js b/www/assets/js/player.js index 9574155..18edd62 100644 --- a/www/assets/js/player.js +++ b/www/assets/js/player.js @@ -59,7 +59,7 @@ const playerLoadStats = () => { player.exp.expPercent = Number((player.exp.expCurrLvl / player.exp.expMaxLvl) * 100).toFixed(2).replace(rx, "$1"); // Generate battle info for player if in combat - if (player.inCombat || playerDead) { + if (player.inCombat || (typeof playerDead !== 'undefined' && playerDead)) { const playerCombatHpElement = document.querySelector('#player-hp-battle'); const playerHpDamageElement = document.querySelector('#player-hp-dmg'); const playerExpElement = document.querySelector('#player-exp-bar'); diff --git a/www/index.html b/www/index.html index 478ace4..35a56fa 100644 --- a/www/index.html +++ b/www/index.html @@ -128,7 +128,7 @@