From cc03718d3c492a401bbc4b071d0ae1f0c808de95 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Thu, 17 Nov 2011 11:22:24 +0200 Subject: Node place/dig Lua callbacks --- src/scriptapi.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/scriptapi.h') diff --git a/src/scriptapi.h b/src/scriptapi.h index ecd3d7b81..e7ff84039 100644 --- a/src/scriptapi.h +++ b/src/scriptapi.h @@ -22,6 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "irrlichttypes.h" #include +#include "mapnode.h" class Server; class ServerEnvironment; @@ -37,7 +38,12 @@ void scriptapi_add_object_reference(lua_State *L, ServerActiveObject *cobj); void scriptapi_rm_object_reference(lua_State *L, ServerActiveObject *cobj); /* environment */ +// On environment step void scriptapi_environment_step(lua_State *L, float dtime); +// After adding node +void scriptapi_environment_on_placenode(lua_State *L, v3s16 p, MapNode newnode); +// After removing node +void scriptapi_environment_on_dignode(lua_State *L, v3s16 p, MapNode oldnode); /* luaentity */ // Returns true if succesfully added into Lua; false otherwise. -- cgit v1.2.3