diff options
author | Lizzy Fleckenstein <eliasfleckenstein@web.de> | 2022-12-10 15:31:22 +0100 |
---|---|---|
committer | Lizzy Fleckenstein <eliasfleckenstein@web.de> | 2023-03-07 18:18:18 +0100 |
commit | 925309eba69a95bcd2a49233125ce32e530fa663 (patch) | |
tree | 5d9cb1b30c4a3f24a681a46fdc731f7b6238b926 /src/script/common/c_content.cpp | |
parent | 1f0d042377ed506ad460067495e5911b2fc2aacc (diff) | |
download | minetest-925309eba69a95bcd2a49233125ce32e530fa663.tar.xz |
Dual wielding
Diffstat (limited to 'src/script/common/c_content.cpp')
-rw-r--r-- | src/script/common/c_content.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/script/common/c_content.cpp b/src/script/common/c_content.cpp index 4be6457d8..8b03f0910 100644 --- a/src/script/common/c_content.cpp +++ b/src/script/common/c_content.cpp @@ -81,6 +81,16 @@ void read_item_definition(lua_State* L, int index, def.usable = lua_isfunction(L, -1); lua_pop(L, 1); + lua_pushstring(L, "on_place"); + lua_rawget(L, index); + def.has_on_place = lua_isfunction(L, -1); + lua_pop(L, 1); + + lua_pushstring(L, "on_secondary_use"); + lua_rawget(L, index); + def.has_on_secondary_use = lua_isfunction(L, -1); + lua_pop(L, 1); + getboolfield(L, index, "liquids_pointable", def.liquids_pointable); lua_getfield(L, index, "tool_capabilities"); |