Updated Json File To Remove module atibute

This commit is contained in:
Cooldude2606
2018-06-23 10:07:26 +01:00
parent f3d6d20ed5
commit 593d484f37
18 changed files with 22 additions and 33 deletions

View File

@@ -8,8 +8,7 @@
-- @function _comment
local Game = require('FactorioStdLib.Game')
local success, Ranking = pcall(require,'ExpGamingCore.Ranking')
if not success then Ranking = nil end success = nil
local Ranking -- this is optional and is hanndled by it being present, it is loaded on init
local mod_gui = require("mod-gui")
local Gui = Gui -- this is to force gui to remain in the ENV
@@ -49,6 +48,10 @@ function toolbar.draw(player)
end
end
function toolbar:on_init()
if loaded_modules['ExpGamingCore.Ranking'] then Ranking = require('ExpGamingCore.Ranking') end
end
toolbar.on_rank_change = toolbar.draw
toolbar.on_player_joined_game = toolbar.draw
return toolbar