Add sound notification (#86)

* Add sound notification

* Change sound

Update translations
This commit is contained in:
Athozus 2023-05-06 21:21:20 +02:00
parent a79ebd94b8
commit 955f7d123f
No known key found for this signature in database
GPG key ID: B50895022E8484BF
13 changed files with 68 additions and 50 deletions

View file

@ -106,6 +106,9 @@ function mail.send(m)
minetest.chat_send_player(name, unified_inventory_alert)
end
end
if mail.get_setting(name, "sound_notifications") == true then
minetest.sound_play("mail_notif", {to_player=name})
end
local receiver_entry = mail.get_storage_entry(name)
local receiver_messages = receiver_entry.inbox
mail.hud_update(name, receiver_messages)