diff options
author | Perttu Ahola <celeron55@gmail.com> | 2012-06-05 23:51:37 +0300 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2012-06-05 23:51:37 +0300 |
commit | 3a0562bebcb91d05fceb5a1f9ded539f77a625e4 (patch) | |
tree | 8b788689029fbeaf7880b628186b77c5f667845f /games/minimal/mods/experimental | |
parent | c3658e7c797cbf5b9d04a6d950505d37dcdd422b (diff) | |
download | minetest-3a0562bebcb91d05fceb5a1f9ded539f77a625e4.tar.gz minetest-3a0562bebcb91d05fceb5a1f9ded539f77a625e4.tar.bz2 minetest-3a0562bebcb91d05fceb5a1f9ded539f77a625e4.zip |
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
Diffstat (limited to 'games/minimal/mods/experimental')
-rw-r--r-- | games/minimal/mods/experimental/init.lua | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/games/minimal/mods/experimental/init.lua b/games/minimal/mods/experimental/init.lua index ea11e6d3b..c8ffb25de 100644 --- a/games/minimal/mods/experimental/init.lua +++ b/games/minimal/mods/experimental/init.lua @@ -468,6 +468,10 @@ minetest.register_node("experimental:tester_node_1", { experimental.print_to_everything("experimental:tester_node_1:on_destruct("..minetest.pos_to_string(pos)..")") end, + after_destruct = function(pos) + experimental.print_to_everything("experimental:tester_node_1:after_destruct("..minetest.pos_to_string(pos)..")") + end, + after_dig_node = function(pos, oldnode, oldmetadata, digger) experimental.print_to_everything("experimental:tester_node_1:after_dig_node("..minetest.pos_to_string(pos)..")") end, |