modules/menusystem:add batch management functions for sounds

This commit is contained in:
Kazhnuz 2019-04-20 17:56:18 +02:00
parent 4c1acb0afa
commit 627395c83f

View file

@ -144,6 +144,18 @@ end
-- SOUND FUNCTIONS
-- Add sounds to every menus
function MenuSystem:setSoundFromSceneAssets(soundname)
for k,v in pairs(self.menus) do
v:setSoundFromSceneAssets(soundname)
end
end
function MenuSystem:setSound(soundasset)
for k,v in pairs(self.menus) do
v:setSound(soundasset)
end
end
-- UPDATE FUNCTIONS
-- Update the menus of the menusystem