summaryrefslogtreecommitdiff
path: root/crate.lua
diff options
context:
space:
mode:
authorFaceDeer <derksenmobile@gmail.com>2017-01-17 00:31:41 -0700
committerFaceDeer <derksenmobile@gmail.com>2017-01-17 00:31:41 -0700
commit9ddec013de650dbfc87c6c960a1e27df820f2977 (patch)
treee6316e607dbfce26d562ce7889c41d862308345c /crate.lua
parent376f83cdd6033d03322dddffc9e405c0bf4c20c4 (diff)
added sounds to crate packing and unpacking
Diffstat (limited to 'crate.lua')
-rw-r--r--crate.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/crate.lua b/crate.lua
index 6797755..ddcc594 100644
--- a/crate.lua
+++ b/crate.lua
@@ -36,6 +36,7 @@ minetest.register_node("digtron:empty_crate", {
-- Create the loaded crate node
minetest.set_node(pos, {name="digtron:loaded_crate", param1=node.param1, param2=node.param2})
+ minetest.sound_play("machine1", {gain=1.0, pos=pos})
local meta = minetest.get_meta(pos)
meta:set_string("crated_layout", layout_string)
@@ -110,6 +111,7 @@ minetest.register_node("digtron:loaded_crate", {
-- build digtron. Since the empty crate was included in the layout, that will overwrite this loaded crate and destroy it.
if layout then
+ minetest.sound_play("machine2", {gain=1.0, pos=pos})
layout:write_layout_image(sender)
end
end,