Switch to `ephemeral' sounds of eating and picking up items
This commit is contained in:
parent
e3bb04d341
commit
0de69ddffb
@ -585,12 +585,14 @@ function core.do_item_eat(hp_change, replace_with_item, itemstack, user, pointed
|
|||||||
if def and def.sound and def.sound.eat then
|
if def and def.sound and def.sound.eat then
|
||||||
core.sound_play(def.sound.eat, {
|
core.sound_play(def.sound.eat, {
|
||||||
pos = pos,
|
pos = pos,
|
||||||
max_hear_distance = 16})
|
max_hear_distance = 16
|
||||||
|
}, true)
|
||||||
else
|
else
|
||||||
core.sound_play("player_eat", {
|
core.sound_play("player_eat", {
|
||||||
pos = pos,
|
pos = pos,
|
||||||
max_hear_distance = 10,
|
max_hear_distance = 16,
|
||||||
gain = 0.3})
|
gain = 0.3
|
||||||
|
}, true)
|
||||||
end
|
end
|
||||||
|
|
||||||
local dir = user:get_look_dir()
|
local dir = user:get_look_dir()
|
||||||
|
@ -421,7 +421,7 @@ if collection then
|
|||||||
max_hear_distance = 10,
|
max_hear_distance = 10,
|
||||||
gain = 0.2,
|
gain = 0.2,
|
||||||
pitch = random(60, 100) / 100
|
pitch = random(60, 100) / 100
|
||||||
})
|
}, true)
|
||||||
entity.itemstring = ""
|
entity.itemstring = ""
|
||||||
obj:remove()
|
obj:remove()
|
||||||
item = inv:add_item("main", item)
|
item = inv:add_item("main", item)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user