Добавить максимальную дистанцию проигрывания звуков дверей от позиции установки

This commit is contained in:
Aleksandr Avdeev 2024-11-25 11:32:19 +03:00
parent a6bb728c5c
commit d3aab548e5

View File

@ -51,10 +51,11 @@ for i in ipairs(Porta_list) do
minetest.set_node(pos, node) minetest.set_node(pos, node)
minetest.sound_play("summer_porta_ch", { minetest.sound_play("summer_porta_ch", {
to_player = "", to_player = "",
gain = 0.1, gain = 0.1,
}) pos = pos,
max_hear_distance = 16,
})
end, end,
}) })
@ -88,9 +89,11 @@ minetest.register_node("summer:porta_"..colour.."_ch", {
node.name = "summer:porta_"..colour.."" node.name = "summer:porta_"..colour..""
minetest.set_node(pos, node) minetest.set_node(pos, node)
minetest.sound_play("summer_porta_op", { minetest.sound_play("summer_porta_op", {
to_player = "", to_player = "",
gain = 0.1, gain = 0.1,
}) pos = pos,
max_hear_distance = 16,
})
end, end,
}) })