Use ephemeral sounds
This commit is contained in:
parent
b2c75acd68
commit
c5e4ec5e27
61 changed files with 123 additions and 122 deletions
|
@ -145,7 +145,7 @@ ARROW_ENTITY.on_step = function(self, dtime)
|
|||
pos = pos,
|
||||
max_hear_distance = 16,
|
||||
gain = 1.0,
|
||||
})
|
||||
}, true)
|
||||
end
|
||||
end
|
||||
self.object:remove()
|
||||
|
@ -224,7 +224,7 @@ ARROW_ENTITY.on_step = function(self, dtime)
|
|||
if is_player then
|
||||
if self._shooter and self._shooter:is_player() then
|
||||
-- “Ding” sound for hitting another player
|
||||
minetest.sound_play({name="mcl_bows_hit_player", gain=0.1}, {to_player=self._shooter})
|
||||
minetest.sound_play({name="mcl_bows_hit_player", gain=0.1}, {to_player=self._shooter}, true)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -48,7 +48,7 @@ mcl_bows.shoot_arrow = function(arrow_item, pos, dir, yaw, shooter, power, damag
|
|||
le._shooter = shooter
|
||||
le._damage = damage
|
||||
le._startpos = pos
|
||||
minetest.sound_play("mcl_bows_bow_shoot", {pos=pos})
|
||||
minetest.sound_play("mcl_bows_bow_shoot", {pos=pos}, true)
|
||||
if shooter ~= nil and shooter:is_player() then
|
||||
if obj:get_luaentity().player == "" then
|
||||
obj:get_luaentity().player = shooter
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue