summaryrefslogtreecommitdiff
path: root/mesecons_random
diff options
context:
space:
mode:
authorKyle <kyle.kylina@gmail.com>2013-02-08 16:49:27 -0800
committerKyle <kyle.kylina@gmail.com>2013-02-08 16:49:27 -0800
commitfb45ee1d777a486eb973b9406b131223e9d9ab13 (patch)
tree3b9e29122c7c3a92155c4e775bf66037cf5b56b2 /mesecons_random
parent5b5e919683c2932592a7879fba29c4f2f0289e1c (diff)
downloadmesecons-fb45ee1d777a486eb973b9406b131223e9d9ab13.tar
mesecons-fb45ee1d777a486eb973b9406b131223e9d9ab13.tar.gz
mesecons-fb45ee1d777a486eb973b9406b131223e9d9ab13.tar.bz2
mesecons-fb45ee1d777a486eb973b9406b131223e9d9ab13.tar.xz
mesecons-fb45ee1d777a486eb973b9406b131223e9d9ab13.zip
Remove ghoststone shadow when active.
Diffstat (limited to 'mesecons_random')
-rw-r--r--mesecons_random/init.lua10
1 files changed, 9 insertions, 1 deletions
diff --git a/mesecons_random/init.lua b/mesecons_random/init.lua
index 78c3825..16ffa3b 100644
--- a/mesecons_random/init.lua
+++ b/mesecons_random/init.lua
@@ -51,6 +51,7 @@ minetest.register_node("mesecons_random:ghoststone_active", {
walkable = false,
diggable = false,
sunlight_propagates = true,
+ paramtype = "light",
mesecons = {conductor = {
state = mesecon.state.on,
rules = {
@@ -62,7 +63,14 @@ minetest.register_node("mesecons_random:ghoststone_active", {
{x = 0, y = 0, z = 1},
},
offstate = "mesecons_random:ghoststone"
- }}
+ }},
+ on_construct = function(pos)
+ --remove shadow
+ pos2 = {x = pos.x, y = pos.y + 1, z = pos.z}
+ if ( minetest.env:get_node(pos2).name == "air" ) then
+ minetest.env:dig_node(pos2)
+ end
+ end
})