fix effects in audio:play
This commit is contained in:
parent
dee4ed9719
commit
99b176342f
@ -63,11 +63,14 @@ end
|
|||||||
|
|
||||||
--- @param source love.Source
|
--- @param source love.Source
|
||||||
--- @param settings SourceFilter?
|
--- @param settings SourceFilter?
|
||||||
|
--- @param effectName string?
|
||||||
function audio:play(source, settings, effectName)
|
function audio:play(source, settings, effectName)
|
||||||
if settings then
|
if settings then
|
||||||
source:setFilter(settings)
|
source:setFilter(settings)
|
||||||
end
|
end
|
||||||
|
if effectName then
|
||||||
source:setEffect(effectName, true)
|
source:setEffect(effectName, true)
|
||||||
|
end
|
||||||
if source:getType() == "stream" then
|
if source:getType() == "stream" then
|
||||||
source:setLooping(self.looped)
|
source:setLooping(self.looped)
|
||||||
source:setVolume(self.musicVolume)
|
source:setVolume(self.musicVolume)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user