X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2Fscript%2Fcpp_api%2Fs_env.h;h=bc4c4cd4d40db3f081a2dfd389839e43b36fd5f9;hb=5c248c2d7de3db54e85f7c388743a2eb8e36fee4;hp=090858f17238c4b06fef729a010846a283ff0b65;hpb=52128ae11e8b1a7ce66a87c53f1b15f3aabe69f4;p=minetest.git diff --git a/src/script/cpp_api/s_env.h b/src/script/cpp_api/s_env.h index 090858f17..bc4c4cd4d 100644 --- a/src/script/cpp_api/s_env.h +++ b/src/script/cpp_api/s_env.h @@ -22,6 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "cpp_api/s_base.h" #include "irr_v3d.h" #include "mapnode.h" +#include #include class ServerEnvironment; @@ -43,8 +44,16 @@ class ScriptApiEnv : virtual public ScriptApiBase void on_emerge_area_completion(v3s16 blockpos, int action, ScriptCallbackState *state); + void check_for_falling(v3s16 p); + // Called after liquid transform changes void on_liquid_transformed(const std::vector> &list); + // Called after mapblock changes + void on_mapblocks_changed(const std::unordered_set &set); + + // Determines whether there are any on_mapblocks_changed callbacks + bool has_on_mapblocks_changed(); + void initializeEnvironment(ServerEnvironment *env); };