Run code on Server-Startup?
R4mbo last edited by
Does anyone know how to run code on server-startup?
NoBlackThunder last edited by
Howdy! Why do you need to run code at startup? Not sure but i think all mods/ code get init at startup (before loading the world) in theory you could run code from that moment .. but its a bit out of my league. @Metachronism might maybe be able to help you if he knows what you try to archive
R4mbo last edited by R4mbo
Let's take the MOTD-Mod for example.
To activate it I must manually run the "/motd-on" command after server startup.
I would like to have that automated.
Metachronism last edited by
you could hijack an Item and use its constructor - in the future we'll have a more automated way to have plugins that are run at startup.
tbbw82 last edited by
Would be nice to have something to hook into that gets executed once the server is done with the startup thru the api.
For modding having diffrent runlevels to hook into might be very usefull depending on what your mod is intended to do.
ChronosWS last edited by
We should define a set of events which are related to changes in server state for this purpose. Such as: