Added Ambient Sounds

This commit is contained in:
IamPyu 2024-12-14 22:47:23 -06:00
parent 9fefa0cd13
commit c43ea0b8ff
5 changed files with 24 additions and 0 deletions

View File

@ -27,6 +27,7 @@ Notable Game Changes:
- Added Magic Wands
- Added Golden Apples and Spellbooks of Healing
- Added Lightning
- Added Ambient Sounds
Other Game Changes:

View File

@ -12,6 +12,7 @@ Credit for sounds I didn't make and are not made with JFXR:
- Piano F#.wav by pinkyfinger -- https://freesound.org/s/68445/ -- License: Creative Commons 0
- Thunder.wav by IllusiaProductions -- https://freesound.org/s/249950/ -- License: Attribution 4.0
- Carpet nord wind(DR-05x,3lrs,grnlzr,fltr_frk,fltr,Eq).wav by newlocknew -- https://freesound.org/s/528810/ -- License: Attribution 4.0
## Textures

Binary file not shown.

View File

@ -0,0 +1,3 @@
local modpath = core.get_modpath(core.get_current_modname())
dofile(modpath .. "/wind.lua")

View File

@ -0,0 +1,19 @@
local pl = {}
local function do_wind(player)
local n = player:get_player_name()
if pl[n] == nil then
pl[n] = core.sound_play("pyutest-wind", {
player = n,
loop = true
})
end
end
core.register_globalstep(function(dtime)
for i, player in ipairs(core.get_connected_players()) do
do_wind(player)
end
end)