Add nodedef.on_blast() to lua_api.txt in order to support chained explosions of any...
authorPerttu Ahola <celeron55@gmail.com>
Sun, 9 Sep 2012 18:54:11 +0000 (21:54 +0300)
committerPerttu Ahola <celeron55@gmail.com>
Sun, 9 Sep 2012 20:24:48 +0000 (23:24 +0300)
doc/lua_api.txt

index 8c6fedc1e3f54a311d568c974dcc7bc57683bb22..442937bd16ef833e4b2cc6a089f63f5e77feca6c 100644 (file)
@@ -1421,6 +1421,11 @@ Node definition (register_node)
        on_metadata_inventory_take = func(pos, listname, index, stack, player),
        ^ Called after the actual action has happened, according to what was allowed.
        ^ No return value
+    
+       on_blast = func(pos, intensity),
+       ^ intensity: 1.0 = mid range of regular TNT
+       ^ If defined, called when an explosion touches the node, instead of
+         removing the node
 }
 
 Recipe for register_craft: (shaped)