[SOLVED] action PauseAudio with fadeout/fadein?
Posted: Wed Apr 05, 2017 3:00 pm
I hope you're all having a lovely morning/afternoon/evening.
I'm trying to achieve a fadein and fadeout when pausing audio.
I tried:
A) Making it work with PauseAudio, but that one doesn't have any fadein/fadeout options.
B) Make a custom function:
I thought this would work, but it gives me an "invalid syntax" on the very first line with "play".
Note: main_screen, ambience and noise are all registered channels.
Any ideas, please?
I'm trying to achieve a fadein and fadeout when pausing audio.
I tried:
A) Making it work with PauseAudio, but that one doesn't have any fadein/fadeout options.
B) Make a custom function:
Code: Select all
def musicStart():
play main_screen "main_screen.ogg" fadein 1.0
play ambience "ambience.mp3" fadein 1.0
play noise "noise.mp3" fadein 1.0
def musicStop():
stop main_screen fadeout 1.0
stop ambience fadeout 1.0
stop noise fadeout 1.0Note: main_screen, ambience and noise are all registered channels.
Any ideas, please?