hardcode choppy sound for backwards compatibility
This commit is contained in:
parent
bfde48768e
commit
4b7692789f
10
api.lua
10
api.lua
|
@ -1367,12 +1367,12 @@ end
|
||||||
---@param damage number|integer
|
---@param damage number|integer
|
||||||
---@return boolean
|
---@return boolean
|
||||||
function XBowsEntityDef.on_punch(self, selfObj, puncher, time_from_last_punch, tool_capabilities, dir, damage)
|
function XBowsEntityDef.on_punch(self, selfObj, puncher, time_from_last_punch, tool_capabilities, dir, damage)
|
||||||
local wood_sound_def = minetest.global_exists('default') and default.node_sound_wood_defaults() or nil
|
local pos = selfObj.object:get_pos()
|
||||||
|
|
||||||
if wood_sound_def then
|
if pos then
|
||||||
minetest.sound_play(wood_sound_def.dig.name, {
|
minetest.sound_play('default_dig_choppy', {
|
||||||
pos = selfObj.object:get_pos(),
|
pos = pos,
|
||||||
gain = wood_sound_def.dig.gain
|
gain = 0.4
|
||||||
})
|
})
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Ŝarĝante…
Reference in New Issue