diff options
25 files changed, 50 insertions, 1 deletions
diff --git a/mesecons_blinkyplant/init.lua b/mesecons_blinkyplant/init.lua index 853354d..4cde7d4 100644 --- a/mesecons_blinkyplant/init.lua +++ b/mesecons_blinkyplant/init.lua @@ -9,6 +9,7 @@ minetest.register_node("mesecons_blinkyplant:blinky_plant_off", { walkable = false, groups = {dig_immediate=3, mesecon = 2}, description="Blinky Plant", + sounds = default.node_sound_leaves_defaults(), selection_box = { type = "fixed", fixed = {-0.1, -0.5, -0.1, 0.1, -0.5+0.6, 0.1}, @@ -29,6 +30,7 @@ minetest.register_node("mesecons_blinkyplant:blinky_plant_on", { drop='"mesecons_blinkyplant:blinky_plant_off" 1', light_source = LIGHT_MAX-7, description = "Blinky Plant", + sounds = default.node_sound_leaves_defaults(), selection_box = { type = "fixed", fixed = {-0.1, -0.5, -0.1, 0.1, -0.5+0.6, 0.1}, diff --git a/mesecons_button/init.lua b/mesecons_button/init.lua index 282e305..5f47e71 100644 --- a/mesecons_button/init.lua +++ b/mesecons_button/init.lua @@ -6,6 +6,7 @@ mesecon.button_turnoff = function (pos) local node = minetest.env:get_node(pos) if node.name=="mesecons_button:button_on" then --has not been dug mesecon:swap_node(pos, "mesecons_button:button_off") + minetest.sound_play("mesecons_button_pop", {pos=pos}) local rules = mesecon.rules.buttonlike_get(node) mesecon:receptor_off(pos, rules) end @@ -41,9 +42,11 @@ minetest.register_node("mesecons_button:button_off", { description = "Button", on_punch = function (pos, node) mesecon:swap_node(pos, "mesecons_button:button_on") - mesecon:receptor_on(pos, mesecon.rules.buttonlike_get(node)) + mesecon:receptor_on(pos, mesecon.rules.buttonlike_get(node)) + minetest.sound_play("mesecons_button_push", {pos=pos}) minetest.after(1, mesecon.button_turnoff, pos) end, + sounds = default.node_sound_stone_defaults(), mesecons = {receptor = { state = mesecon.state.off, rules = mesecon.rules.buttonlike_get @@ -80,6 +83,7 @@ minetest.register_node("mesecons_button:button_on", { groups = {dig_immediate=2, not_in_creative_inventory=1, mesecon_needs_receiver = 1}, drop = 'mesecons_button:button_off', description = "Button", + sounds = default.node_sound_stone_defaults(), mesecons = {receptor = { state = mesecon.state.on, rules = mesecon.rules.buttonlike_get diff --git a/mesecons_button/sounds/mesecons_button_pop.ogg b/mesecons_button/sounds/mesecons_button_pop.ogg Binary files differnew file mode 100644 index 0000000..9d56bb8 --- /dev/null +++ b/mesecons_button/sounds/mesecons_button_pop.ogg diff --git a/mesecons_button/sounds/mesecons_button_push.ogg b/mesecons_button/sounds/mesecons_button_push.ogg Binary files differnew file mode 100644 index 0000000..53d45c1 --- /dev/null +++ b/mesecons_button/sounds/mesecons_button_push.ogg diff --git a/mesecons_commandblock/init.lua b/mesecons_commandblock/init.lua index 35eea25..0ae1321 100644 --- a/mesecons_commandblock/init.lua +++ b/mesecons_commandblock/init.lua @@ -152,6 +152,7 @@ minetest.register_node("mesecons_commandblock:commandblock_off", { local owner = minetest.env:get_meta(pos):get_string("owner")
return owner == "" or owner == player:get_player_name()
end,
+ sounds = default.node_sound_stone_defaults(),
mesecons = {effector = {
action_on = commandblock_action_on
}}
@@ -169,6 +170,7 @@ minetest.register_node("mesecons_commandblock:commandblock_on", { local owner = minetest.env:get_meta(pos):get_string("owner")
return owner == "" or owner == player:get_player_name()
end,
+ sounds = default.node_sound_stone_defaults(),
mesecons = {effector = {
action_off = commandblock_action_off
}}
diff --git a/mesecons_compatibility/init.lua b/mesecons_compatibility/init.lua index 451037e..42adfd1 100644 --- a/mesecons_compatibility/init.lua +++ b/mesecons_compatibility/init.lua @@ -153,6 +153,7 @@ doors:register_door("doors:door_wood", { groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,flammable=2,door=1}, tiles_bottom = {"door_wood_b.png", "door_brown.png"}, tiles_top = {"door_wood_a.png", "door_brown.png"}, + sounds = default.node_sound_wood_defaults(), }) doors:register_door("doors:door_steel", { @@ -162,4 +163,5 @@ doors:register_door("doors:door_steel", { tiles_bottom = {"door_steel_b.png", "door_grey.png"}, tiles_top = {"door_steel_a.png", "door_grey.png"}, only_placer_can_open = true, + sounds = default.node_sound_stone_defaults(), }) diff --git a/mesecons_delayer/init.lua b/mesecons_delayer/init.lua index f70629a..24ba293 100644 --- a/mesecons_delayer/init.lua +++ b/mesecons_delayer/init.lua @@ -110,6 +110,7 @@ minetest.register_node("mesecons_delayer:delayer_off_"..tostring(i), { end, delayer_time = delaytime, delayer_onstate = "mesecons_delayer:delayer_on_"..tostring(i), + sounds = default.node_sound_stone_defaults(), mesecons = { receptor = { diff --git a/mesecons_detector/init.lua b/mesecons_detector/init.lua index 802ca45..ece2bc8 100644 --- a/mesecons_detector/init.lua +++ b/mesecons_detector/init.lua @@ -54,6 +54,7 @@ minetest.register_node("mesecons_detector:object_detector_off", { }}, on_construct = object_detector_make_formspec, on_receive_fields = object_detector_on_receive_fields, + sounds = default.node_sound_stone_defaults(), digiline = object_detector_digiline }) @@ -68,6 +69,7 @@ minetest.register_node("mesecons_detector:object_detector_on", { }}, on_construct = object_detector_make_formspec, on_receive_fields = object_detector_on_receive_fields, + sounds = default.node_sound_stone_defaults(), digiline = object_detector_digiline }) diff --git a/mesecons_gates/init.lua b/mesecons_gates/init.lua index 0e3d934..162c7d8 100644 --- a/mesecons_gates/init.lua +++ b/mesecons_gates/init.lua @@ -156,6 +156,7 @@ for _, gate in ipairs(gates) do end, groups = groups, drop = drop, + sounds = default.node_sound_stone_defaults(), mesecons_gate = gate.name, mesecons = { diff --git a/mesecons_hydroturbine/init.lua b/mesecons_hydroturbine/init.lua index 70b7d28..a2836f2 100644 --- a/mesecons_hydroturbine/init.lua +++ b/mesecons_hydroturbine/init.lua @@ -23,6 +23,7 @@ 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}}, }, + sounds = default.node_sound_stone_defaults(), mesecons = {receptor = { state = mesecon.state.off }} @@ -49,6 +50,7 @@ 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}}, }, + sounds = default.node_sound_stone_defaults(), mesecons = {receptor = { state = mesecon.state.on }} diff --git a/mesecons_lamp/init.lua b/mesecons_lamp/init.lua index 175a22b..8b5a4ab 100644 --- a/mesecons_lamp/init.lua +++ b/mesecons_lamp/init.lua @@ -22,6 +22,7 @@ minetest.register_node("mesecons_lamp:lamp_on", { selection_box = mesecon_lamp_box, groups = {dig_immediate=3,not_in_creative_inventory=1, mesecon_effector_on = 1}, drop='"mesecons_lamp:lamp_off" 1', + sounds = default.node_sound_glass_defaults(), mesecons = {effector = { action_off = function (pos, node) mesecon:swap_node(pos, "mesecons_lamp:lamp_off") @@ -42,6 +43,7 @@ minetest.register_node("mesecons_lamp:lamp_off", { selection_box = mesecon_lamp_box, groups = {dig_immediate=3, mesecon_receptor_off = 1, mesecon_effector_off = 1}, description="Meselamp", + sounds = default.node_sound_glass_defaults(), mesecons = {effector = { action_on = function (pos, node) mesecon:swap_node(pos, "mesecons_lamp:lamp_on") diff --git a/mesecons_lightstone/init.lua b/mesecons_lightstone/init.lua index aa0c9b3..a2389ff 100644 --- a/mesecons_lightstone/init.lua +++ b/mesecons_lightstone/init.lua @@ -4,6 +4,7 @@ function mesecon:lightstone_add(name, base_item, texture_off, texture_on) inventory_image = minetest.inventorycube(texture_off), groups = {cracky=2, mesecon_effector_off = 1, mesecon = 2}, description=name.." Lightstone", + sounds = default.node_sound_stone_defaults(), mesecons = {effector = { action_on = function (pos, node) mesecon:swap_node(pos, "mesecons_lightstone:lightstone_" .. name .. "_on") @@ -16,6 +17,7 @@ function mesecon:lightstone_add(name, base_item, texture_off, texture_on) groups = {cracky=2,not_in_creative_inventory=1, mesecon = 2}, drop = "node mesecons_lightstone:lightstone_" .. name .. "_off 1", light_source = LIGHT_MAX-2, + sounds = default.node_sound_stone_defaults(), mesecons = {effector = { action_off = function (pos, node) mesecon:swap_node(pos, "mesecons_lightstone:lightstone_" .. name .. "_off") diff --git a/mesecons_luacontroller/init.lua b/mesecons_luacontroller/init.lua index f648b7a..41763bf 100644 --- a/mesecons_luacontroller/init.lua +++ b/mesecons_luacontroller/init.lua @@ -421,6 +421,7 @@ minetest.register_node(nodename, { if err then print(err) end reset_meta(pos, fields.code, err) end, + sounds = default.node_sound_stone_defaults(), mesecons = mesecons, digiline = digiline, is_luacontroller = true, diff --git a/mesecons_microcontroller/init.lua b/mesecons_microcontroller/init.lua index 6120ade..4bdf14c 100644 --- a/mesecons_microcontroller/init.lua +++ b/mesecons_microcontroller/init.lua @@ -128,6 +128,7 @@ minetest.register_node(nodename, { yc_reset (pos) update_yc(pos) end, + sounds = default.node_sound_stone_defaults(), mesecons = mesecons, after_dig_node = function (pos, node) rules = mesecon:get_rules(node.name) diff --git a/mesecons_movestones/init.lua b/mesecons_movestones/init.lua index 91b57c7..a78b879 100644 --- a/mesecons_movestones/init.lua +++ b/mesecons_movestones/init.lua @@ -61,6 +61,7 @@ minetest.register_node("mesecons_movestones:movestone", { legacy_facedir_simple = true, groups = {cracky=3}, description="Movestone", + sounds = default.node_sound_stone_defaults(), mesecons = {effector = { action_on = function (pos, node) local direction=mesecon:get_movestone_direction(pos) @@ -131,6 +132,7 @@ minetest.register_node("mesecons_movestones:sticky_movestone", { legacy_facedir_simple = true, groups = {cracky=3}, description="Sticky Movestone", + sounds = default.node_sound_stone_defaults(), mesecons = {effector = { action_on = function (pos, node) local direction=mesecon:get_movestone_direction(pos) diff --git a/mesecons_noteblock/init.lua b/mesecons_noteblock/init.lua index 073524c..12788d3 100644 --- a/mesecons_noteblock/init.lua +++ b/mesecons_noteblock/init.lua @@ -14,6 +14,7 @@ minetest.register_node("mesecons_noteblock:noteblock", { minetest.env:add_node(pos, {name = node.name, param2 = param2}) mesecon.noteblock_play(pos, param2) end, + sounds = default.node_sound_wood_defaults(), mesecons = {effector = { -- play sound when activated action_on = function (pos, node) mesecon.noteblock_play(pos, node.param2) diff --git a/mesecons_pistons/init.lua b/mesecons_pistons/init.lua index a6cb06c..d496b1e 100644 --- a/mesecons_pistons/init.lua +++ b/mesecons_pistons/init.lua @@ -136,6 +136,7 @@ minetest.register_node("mesecons_pistons:piston_normal_off", { paramtype2 = "facedir", after_place_node = piston_orientate, mesecons_piston = pistonspec_normal, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_on = piston_on, rules = piston_get_rules @@ -163,6 +164,7 @@ minetest.register_node("mesecons_pistons:piston_normal_on", { node_box = piston_on_box, selection_box = piston_on_box, mesecons_piston = pistonspec_normal, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_off = piston_off, rules = piston_get_rules @@ -215,6 +217,7 @@ minetest.register_node("mesecons_pistons:piston_sticky_off", { paramtype2 = "facedir", after_place_node = piston_orientate, mesecons_piston = pistonspec_sticky, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_on = piston_on, rules = piston_get_rules @@ -242,6 +245,7 @@ minetest.register_node("mesecons_pistons:piston_sticky_on", { node_box = piston_on_box, selection_box = piston_on_box, mesecons_piston = pistonspec_sticky, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_off = piston_off, rules = piston_get_rules @@ -339,6 +343,7 @@ minetest.register_node("mesecons_pistons:piston_up_normal_on", { node_box = piston_up_on_box, selection_box = piston_up_on_box, mesecons_piston = pistonspec_normal_up, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_off = piston_off, }} @@ -393,6 +398,7 @@ minetest.register_node("mesecons_pistons:piston_up_sticky_off", { paramtype2 = "facedir", drop = "mesecons_pistons:piston_sticky_off", mesecons_piston = pistonspec_sticky_up, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_on = piston_on, }} @@ -419,6 +425,7 @@ minetest.register_node("mesecons_pistons:piston_up_sticky_on", { node_box = piston_up_on_box, selection_box = piston_up_on_box, mesecons_piston = pistonspec_sticky_up, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_off = piston_off, }} @@ -491,6 +498,7 @@ minetest.register_node("mesecons_pistons:piston_down_normal_off", { paramtype2 = "facedir", drop = "mesecons_pistons:piston_normal_off", mesecons_piston = pistonspec_normal_down, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_on = piston_on, }} @@ -517,6 +525,7 @@ minetest.register_node("mesecons_pistons:piston_down_normal_on", { node_box = piston_down_on_box, selection_box = piston_down_on_box, mesecons_piston = pistonspec_normal_down, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_off = piston_off, }} @@ -567,6 +576,7 @@ minetest.register_node("mesecons_pistons:piston_down_sticky_off", { paramtype2 = "facedir", drop = "mesecons_pistons:piston_sticky_off", mesecons_piston = pistonspec_sticky_down, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_on = piston_on, }} @@ -593,6 +603,7 @@ minetest.register_node("mesecons_pistons:piston_down_sticky_on", { node_box = piston_down_on_box, selection_box = piston_down_on_box, mesecons_piston = pistonspec_sticky_down, + sounds = default.node_sound_wood_defaults(), mesecons = {effector={ action_off = piston_off, }} diff --git a/mesecons_powerplant/init.lua b/mesecons_powerplant/init.lua index 006fc19..57a05d8 100644 --- a/mesecons_powerplant/init.lua +++ b/mesecons_powerplant/init.lua @@ -15,6 +15,7 @@ minetest.register_node("mesecons_powerplant:power_plant", { type = "fixed", fixed = {-0.1, -0.5, -0.1, 0.1, -0.5+0.6, 0.1}, }, + sounds = default.node_sound_leaves_defaults(), mesecons = {receptor = { state = mesecon.state.on }} diff --git a/mesecons_pressureplates/init.lua b/mesecons_pressureplates/init.lua index 87b3bb9..16914d0 100644 --- a/mesecons_pressureplates/init.lua +++ b/mesecons_pressureplates/init.lua @@ -85,6 +85,7 @@ function mesecon:register_pressure_plate(offstate, onstate, description, texture drop = offstate, pressureplate = ppspec, on_timer = pp_on_timer, + sounds = default.node_sound_wood_defaults(), mesecons = {receptor = { state = mesecon.state.on }}, diff --git a/mesecons_random/init.lua b/mesecons_random/init.lua index 16ffa3b..f2e459a 100644 --- a/mesecons_random/init.lua +++ b/mesecons_random/init.lua @@ -5,6 +5,7 @@ minetest.register_node("mesecons_random:removestone", { inventory_image = minetest.inventorycube("jeija_removestone_inv.png"), groups = {cracky=3}, description="Removestone", + sounds = default.node_sound_stone_defaults(), mesecons = {effector = { action_on = function (pos, node) minetest.env:remove_node(pos) diff --git a/mesecons_solarpanel/init.lua b/mesecons_solarpanel/init.lua index b8f3ac0..5a5d6f3 100644 --- a/mesecons_solarpanel/init.lua +++ b/mesecons_solarpanel/init.lua @@ -22,6 +22,7 @@ minetest.register_node("mesecons_solarpanel:solar_panel_on", { }, drop = "mesecons_solarpanel:solar_panel_off", groups = {dig_immediate=3, not_in_creative_inventory = 1}, + sounds = default.node_sound_glass_defaults(), mesecons = {receptor = { state = mesecon.state.on }} @@ -51,6 +52,7 @@ minetest.register_node("mesecons_solarpanel:solar_panel_off", { }, groups = {dig_immediate=3}, description="Solar Panel", + sounds = default.node_sound_glass_defaults(), mesecons = {receptor = { state = mesecon.state.off }} diff --git a/mesecons_switch/init.lua b/mesecons_switch/init.lua index 0519e03..0ec5a27 100644 --- a/mesecons_switch/init.lua +++ b/mesecons_switch/init.lua @@ -5,12 +5,14 @@ minetest.register_node("mesecons_switch:mesecon_switch_off", { paramtype2="facedir", groups = {dig_immediate=2}, description="Switch", + sounds = default.node_sound_stone_defaults(), mesecons = {receptor = { state = mesecon.state.off }}, on_punch = function(pos, node) mesecon:swap_node(pos, "mesecons_switch:mesecon_switch_on") mesecon:receptor_on(pos) + minetest.sound_play("mesecons_switch", {pos=pos}) end }) @@ -19,12 +21,14 @@ minetest.register_node("mesecons_switch:mesecon_switch_on", { paramtype2="facedir", groups = {dig_immediate=2,not_in_creative_inventory=1}, drop='"mesecons_switch:mesecon_switch_off" 1', + sounds = default.node_sound_stone_defaults(), mesecons = {receptor = { state = mesecon.state.on }}, on_punch = function(pos, node) mesecon:swap_node(pos, "mesecons_switch:mesecon_switch_off") mesecon:receptor_off(pos) + minetest.sound_play("mesecons_switch", {pos=pos}) end }) diff --git a/mesecons_switch/sounds/mesecons_switch.ogg b/mesecons_switch/sounds/mesecons_switch.ogg Binary files differnew file mode 100644 index 0000000..53d45c1 --- /dev/null +++ b/mesecons_switch/sounds/mesecons_switch.ogg diff --git a/mesecons_walllever/init.lua b/mesecons_walllever/init.lua index 6fc0770..df79f33 100644 --- a/mesecons_walllever/init.lua +++ b/mesecons_walllever/init.lua @@ -34,7 +34,9 @@ minetest.register_node("mesecons_walllever:wall_lever_off", { on_punch = function (pos, node) mesecon:swap_node(pos, "mesecons_walllever:wall_lever_on") mesecon:receptor_on(pos, mesecon.rules.buttonlike_get(node)) + minetest.sound_play("mesecons_lever", {pos=pos}) end, + sounds = default.node_sound_wood_defaults(), mesecons = {receptor = { rules = mesecon.rules.buttonlike_get, state = mesecon.state.off @@ -74,7 +76,9 @@ minetest.register_node("mesecons_walllever:wall_lever_on", { on_punch = function (pos, node) mesecon:swap_node(pos, "mesecons_walllever:wall_lever_off") mesecon:receptor_off(pos, mesecon.rules.buttonlike_get(node)) + minetest.sound_play("mesecons_lever", {pos=pos}) end, + sounds = default.node_sound_wood_defaults(), mesecons = {receptor = { rules = mesecon.rules.buttonlike_get, state = mesecon.state.on diff --git a/mesecons_walllever/sounds/mesecons_lever.ogg b/mesecons_walllever/sounds/mesecons_lever.ogg Binary files differnew file mode 100644 index 0000000..53d45c1 --- /dev/null +++ b/mesecons_walllever/sounds/mesecons_lever.ogg |