mirror of
https://github.com/luanti-org/luanti.git
synced 2025-11-30 04:35:20 +01:00
Async environment for mods to do concurrent tasks (#11131)
This commit is contained in:
@@ -243,6 +243,7 @@ Server::Server(
|
||||
m_clients(m_con),
|
||||
m_admin_chat(iface),
|
||||
m_on_shutdown_errmsg(on_shutdown_errmsg),
|
||||
m_async_globals_data(""),
|
||||
m_modchannel_mgr(new ModChannelMgr())
|
||||
{
|
||||
if (m_path_world.empty())
|
||||
@@ -480,6 +481,9 @@ void Server::init()
|
||||
// Give environment reference to scripting api
|
||||
m_script->initializeEnvironment(m_env);
|
||||
|
||||
// Do this after regular script init is done
|
||||
m_script->initAsync();
|
||||
|
||||
// Register us to receive map edit events
|
||||
servermap->addEventReceiver(this);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user