diff options
Diffstat (limited to 'mesecons_extrawires')
-rw-r--r-- | mesecons_extrawires/corner.lua | 4 | ||||
-rw-r--r-- | mesecons_extrawires/depends.txt | 1 | ||||
-rw-r--r-- | mesecons_extrawires/tjunction.lua | 4 |
3 files changed, 9 insertions, 0 deletions
diff --git a/mesecons_extrawires/corner.lua b/mesecons_extrawires/corner.lua index 830ea4c..d0b01f9 100644 --- a/mesecons_extrawires/corner.lua +++ b/mesecons_extrawires/corner.lua @@ -1,3 +1,5 @@ +local screwdriver_exists = minetest.global_exists("screwdriver") + local corner_nodebox = { type = "fixed", fixed = {{ -16/32-0.001, -17/32, -3/32, 0, -13/32, 3/32 }, @@ -48,6 +50,7 @@ minetest.register_node("mesecons_extrawires:corner_on", { offstate = "mesecons_extrawires:corner_off" }}, on_blast = mesecon.on_blastnode, + on_rotate = screwdriver_exists and screwdriver.rotate_simple, }) minetest.register_node("mesecons_extrawires:corner_off", { @@ -77,6 +80,7 @@ minetest.register_node("mesecons_extrawires:corner_off", { onstate = "mesecons_extrawires:corner_on" }}, on_blast = mesecon.on_blastnode, + on_rotate = screwdriver_exists and screwdriver.rotate_simple, }) minetest.register_craft({ diff --git a/mesecons_extrawires/depends.txt b/mesecons_extrawires/depends.txt index aca967d..369aeb7 100644 --- a/mesecons_extrawires/depends.txt +++ b/mesecons_extrawires/depends.txt @@ -1,2 +1,3 @@ default mesecons +screwdriver? diff --git a/mesecons_extrawires/tjunction.lua b/mesecons_extrawires/tjunction.lua index a30afb9..e98b066 100644 --- a/mesecons_extrawires/tjunction.lua +++ b/mesecons_extrawires/tjunction.lua @@ -1,3 +1,5 @@ +local screwdriver_exists = minetest.global_exists("screwdriver") + local tjunction_nodebox = { type = "fixed", fixed = {{ -16/32-0.001, -17/32, -3/32, 16/32+0.001, -13/32, 3/32 }, @@ -49,6 +51,7 @@ minetest.register_node("mesecons_extrawires:tjunction_on", { offstate = "mesecons_extrawires:tjunction_off" }}, on_blast = mesecon.on_blastnode, + on_rotate = screwdriver_exists and screwdriver.rotate_simple, }) minetest.register_node("mesecons_extrawires:tjunction_off", { @@ -78,6 +81,7 @@ minetest.register_node("mesecons_extrawires:tjunction_off", { onstate = "mesecons_extrawires:tjunction_on" }}, on_blast = mesecon.on_blastnode, + on_rotate = screwdriver_exists and screwdriver.rotate_simple, }) minetest.register_craft({ |