mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2026-11-13 08:04:53 +09:00
Switch to sp/mp init events (#404)
This commit is contained in:
1 parent
82c2c7f23c
commit
8bcb65101b
7 files changed
+15
-23
No files matched your search
@@ -408,13 +408,10 @@ end
|
||||
local e = defines.events
|
||||
local events = {
|
||||
[e.on_tick] = on_tick,
|
||||
[e.on_singleplayer_init] = Async.on_init,
|
||||
[e.on_multiplayer_init] = Async.on_init,
|
||||
}
|
||||
|
||||
local Clustorio = ExpUtil.optional_require("modules/clusterio/api")
|
||||
if Clustorio then
|
||||
events[Clustorio.events.on_server_startup] = Async.on_init
|
||||
end
|
||||
|
||||
Async._function_metatable.__call = Async._function_prototype.start_soon
|
||||
Async.events = events --- @package
|
||||
return Async
|
||||
Reference in new issue
Block a user