Use ephemeral sounds
This commit is contained in:
parent
b2c75acd68
commit
c5e4ec5e27
61 changed files with 123 additions and 122 deletions
|
@ -264,7 +264,7 @@ function awards.unlock(name, award)
|
|||
-- Enforce sound delay to prevent sound spamming
|
||||
local lastsound = awards.players[name].lastsound
|
||||
if lastsound == nil or os.difftime(os.time(), lastsound) >= 1 then
|
||||
minetest.sound_play(sound, {to_player=name})
|
||||
minetest.sound_play(sound, {to_player=name}, true)
|
||||
awards.players[name].lastsound = os.time()
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue