]> git.lizzy.rs Git - dragonfireclient.git/blobdiff - src/script/scripting_mainmenu.h
Adding minetest.clear_craft
[dragonfireclient.git] / src / script / scripting_mainmenu.h
index 7592c8e23de720cfa14f5b96ed581e2836a756de..3a0795df461b9f33f2f0538f40f8589fa8e12b92 100644 (file)
@@ -22,6 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
 
 #include "cpp_api/s_base.h"
 #include "cpp_api/s_mainmenu.h"
+#include "cpp_api/s_async.h"
 
 /*****************************************************************************/
 /* Scripting <-> Main Menu Interface                                         */
@@ -34,11 +35,16 @@ class MainMenuScripting
 public:
        MainMenuScripting(GUIEngine* guiengine);
 
-       // use ScriptApiBase::loadMod() or ScriptApiBase::loadScript()
-       // to load scripts
+       // Global step handler to pass back async events
+       void step();
 
+       // Pass async events from engine to async threads
+       unsigned int queueAsync(std::string serialized_func,
+                       std::string serialized_params);
 private:
-       void InitializeModApi(lua_State *L, int top);
+       void initializeModApi(lua_State *L, int top);
+
+       AsyncEngine asyncEngine;
 };