mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Add after_destruct and cache the existence of on_construct, on_destruct and after_destruct for quick skipping when a node does not have them
This commit is contained in:
parent
c3658e7c79
commit
3a0562bebc
6 changed files with 74 additions and 12 deletions
|
@ -86,6 +86,8 @@ bool scriptapi_node_on_dig(lua_State *L, v3s16 p, MapNode node,
|
|||
void scriptapi_node_on_construct(lua_State *L, v3s16 p, MapNode node);
|
||||
// Node destructor
|
||||
void scriptapi_node_on_destruct(lua_State *L, v3s16 p, MapNode node);
|
||||
// Node post-destructor
|
||||
void scriptapi_node_after_destruct(lua_State *L, v3s16 p, MapNode node);
|
||||
// Called when a metadata form returns values
|
||||
void scriptapi_node_on_receive_fields(lua_State *L, v3s16 p,
|
||||
const std::string &formname,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue