Play sound after using hoe

This commit is contained in:
Wuzzy 2017-03-12 02:03:45 +01:00
parent d535d0e19e
commit c88e4f8e0b

View File

@ -9,12 +9,14 @@ local function create_soil(pos, inv)
if above.name == "air" then if above.name == "air" then
node.name = "mcl_farming:soil" node.name = "mcl_farming:soil"
minetest.set_node(pos, node) minetest.set_node(pos, node)
minetest.sound_play("default_dig_crumbly", { pos = pos, gain = 0.5 })
return true return true
end end
elseif minetest.get_item_group(name, "cultivatable") == 1 then elseif minetest.get_item_group(name, "cultivatable") == 1 then
if above.name == "air" then if above.name == "air" then
node.name = "mcl_core:dirt" node.name = "mcl_core:dirt"
minetest.set_node(pos, node) minetest.set_node(pos, node)
minetest.sound_play("default_dig_crumbly", { pos = pos, gain = 0.6 })
return true return true
end end
end end