diff options
author | Jeija <norrepli@gmail.com> | 2012-12-11 19:49:55 +0100 |
---|---|---|
committer | Jeija <norrepli@gmail.com> | 2012-12-11 19:49:55 +0100 |
commit | de46729b971b5e59394834b8a01d4a7005318114 (patch) | |
tree | 5a2cf1f18b485ddefa8e255ac6d6a600ef2e2e12 /mesecons_hydroturbine | |
parent | 31f3c99288355193dc68a6e83dfc63140fd02fa0 (diff) | |
parent | 5540fcbcb31eb32003fa0391113ed3b1dea25e47 (diff) | |
download | mesecons-de46729b971b5e59394834b8a01d4a7005318114.tar mesecons-de46729b971b5e59394834b8a01d4a7005318114.tar.gz mesecons-de46729b971b5e59394834b8a01d4a7005318114.tar.bz2 mesecons-de46729b971b5e59394834b8a01d4a7005318114.tar.xz mesecons-de46729b971b5e59394834b8a01d4a7005318114.zip |
Merge branch 'mesecons_in_nodedef'
Conflicts:
mesecons/internal.lua
Diffstat (limited to 'mesecons_hydroturbine')
-rw-r--r-- | mesecons_hydroturbine/init.lua | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/mesecons_hydroturbine/init.lua b/mesecons_hydroturbine/init.lua index 872d18d..70b7d28 100644 --- a/mesecons_hydroturbine/init.lua +++ b/mesecons_hydroturbine/init.lua @@ -1,9 +1,12 @@ -- HYDRO_TURBINE +-- Water turbine: +-- Active if flowing >water< above it +-- (does not work with other liquids) minetest.register_node("mesecons_hydroturbine:hydro_turbine_off", { drawtype = "nodebox", tiles = {"jeija_hydro_turbine_off.png"}, - groups = {dig_immediate=2, mesecon = 2}, + groups = {dig_immediate=2}, description="Water Turbine", paramtype = "light", selection_box = { @@ -20,13 +23,16 @@ minetest.register_node("mesecons_hydroturbine:hydro_turbine_off", { {-0.45, 1.15, -0.1, 0.45, 1.45, 0.1}, {-0.1, 1.15, -0.45, 0.1, 1.45, 0.45}}, }, + mesecons = {receptor = { + state = mesecon.state.off + }} }) minetest.register_node("mesecons_hydroturbine:hydro_turbine_on", { drawtype = "nodebox", tiles = {"jeija_hydro_turbine_on.png"}, drop = '"mesecons_hydroturbine:hydro_turbine_off" 1', - groups = {dig_immediate=2,not_in_creative_inventory=1, mesecon = 2}, + groups = {dig_immediate=2,not_in_creative_inventory=1}, description="Water Turbine", paramtype = "light", selection_box = { @@ -43,6 +49,9 @@ minetest.register_node("mesecons_hydroturbine:hydro_turbine_on", { {-0.5, 1.15, -0.1, 0.5, 1.45, 0.1}, {-0.1, 1.15, -0.5, 0.1, 1.45, 0.5}}, }, + mesecons = {receptor = { + state = mesecon.state.on + }} }) @@ -74,9 +83,6 @@ nodenames = {"mesecons_hydroturbine:hydro_turbine_on"}, end, }) -mesecon:add_receptor_node("mesecons_hydroturbine:hydro_turbine_on") -mesecon:add_receptor_node_off("mesecons_hydroturbine:hydro_turbine_off") - minetest.register_craft({ output = '"mesecons_hydroturbine:hydro_turbine_off" 2', recipe = { |