Cuberite Forum
Class cWorld; Function ScheduleTask; Only one Function Callback - Printable Version

+- Cuberite Forum (https://forum.cuberite.org)
+-- Forum: Plugins (https://forum.cuberite.org/forum-1.html)
+--- Forum: Plugin Discussion (https://forum.cuberite.org/forum-8.html)
+--- Thread: Class cWorld; Function ScheduleTask; Only one Function Callback (/thread-1691.html)

Pages: 1 2


RE: Class cWorld; Function ScheduleTask; Only one Function Callback - VeryBlackMan - 12-26-2014

(12-24-2014, 03:08 AM)worktycho Wrote: It's a known bug in the server and requires changes to the lua/scheduler interface. The relevant issue is: https://github.com/mc-server/MCServer/issues/1556

Quote:We have three options:
1.Keep the plugin loaded in a partially unloaded state until all scheduled tasks are done.
- Increases reload time

2.Kill all scheduled tasks on unload.
- Can leave plugins in an inconsistent state.

3.Transfer scheduled task to new instance.
- Function may not exist in new instance.
- Doesn't fix unload.
The second Option sounds like good.
Have you an example code for this?
How can i kill my scheduled tasks on a Server reload?[/quote]


RE: Class cWorld; Function ScheduleTask; Only one Function Callback - Seadragon91 - 12-26-2014

This has to be done in mc server code, not possible from a lua plugin.


RE: Class cWorld; Function ScheduleTask; Only one Function Callback - VeryBlackMan - 12-26-2014

(12-26-2014, 08:40 PM)Seadragon91 Wrote: This has to be done in mc server code, not possible from a lua plugin.
You know when this will be implemented?