mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2026-11-18 23:03:13 +09:00
Covnerted Event and Global
This commit is contained in:
1 parent
fc279c42f8
commit
1cb2a3c3a0
35 files changed
+97
-78
No files matched your search
@@ -85,6 +85,6 @@ function toolbar.on_init()
|
||||
if loaded_modules['ExpGamingCore.Role'] then Role = require('ExpGamingCore.Role') end
|
||||
end
|
||||
|
||||
script.on_event({defines.events.on_role_change,defines.events.on_player_joined_game},toolbar.draw)
|
||||
Event.add({defines.events.on_role_change,defines.events.on_player_joined_game},toolbar.draw)
|
||||
-- calling with only a player will draw the toolbar for that player, more params will attempt to add a button
|
||||
return setmetatable(toolbar,{__call=function(self,player,extra,...) if extra then return self.add(player,extra,...) else self.draw(player) end end})
|
||||
Reference in new issue
Block a user