From c8cff4ce06121bddc9edf882783b88bf3a4d4d06 Mon Sep 17 00:00:00 2001 From: DarkGod <darkgod@net-core.org> Date: Tue, 17 Mar 2020 17:54:41 +0100 Subject: [PATCH] sanity check --- game/modules/tome/class/Player.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/game/modules/tome/class/Player.lua b/game/modules/tome/class/Player.lua index a5134d0680..9eeea68397 100644 --- a/game/modules/tome/class/Player.lua +++ b/game/modules/tome/class/Player.lua @@ -540,6 +540,9 @@ for i = 0, 10 * 10 do end function _M:playerFOV() + -- Safety + if not self.x or not game.level then return end + -- Clean FOV before computing it game.level.map:cleanFOV() -- GitLab