diff --git a/StandAlone/paths.lua b/StandAlone/paths.lua index c61f8950..7c93f867 100644 --- a/StandAlone/paths.lua +++ b/StandAlone/paths.lua @@ -50,7 +50,7 @@ local function remove_key(surface,pos) end local function clean_global() - if not global.paths then return end + if not global.paths or not game then return end for key,tile in pairs(global.paths) do if tile[3] < game.tick-clean_time then global.paths[key] = nil end end