added startup and shutdown events. fixes #586
This commit is contained in:
1 parent
e8a6b8936f
commit
522d971688
4 files changed
+35
-3
No files matched your search
@@ -127,7 +127,7 @@ public class CarpetScriptServer
|
||||
addScriptHost(server.getCommandSource(), moduleName, null, true, true, false);
|
||||
}
|
||||
}
|
||||
|
||||
CarpetEventServer.Event.START.onTick();
|
||||
}
|
||||
|
||||
public Module getModule(String name, boolean allowLibraries)
|
||||
@@ -489,6 +489,7 @@ public class CarpetScriptServer
|
||||
|
||||
public void onClose()
|
||||
{
|
||||
CarpetEventServer.Event.SHUTDOWN.onTick();
|
||||
for (ScriptHost host : modules.values())
|
||||
{
|
||||
host.onClose();
|
||||
|
||||
Reference in new issue
Block a user