Open Toma400 opened 2 years ago
for 2: you can set a variable to time.time() when you started to play a sound, and then set a variable for length of audio. create a while busy: and put if time.time() > start_time + length_of_audio: busy = False. You'll need threading because of while. only it is sad
Hello! First of all, I wanted to say that I really love the fact that
playsound
has really great competitor which seems to be almost everything I've dreamt of trying to use playsound. There are some elements that I would like to ask, though, and if they are not existing - I'd like to suggest.Do AudioPlayer support running itself via terminal program? Tried running it, but for some reason it didn't really worked for me, didn't showing errors though (except for .volume raising error that 'int' is not callable). This is function which is calling the sound.
How one recognise if there's any music object playing? I am constructing a game which operates on various music files being called, and it would be really helpful to have function that checks if there's any AudioPlayer file being run in exact moment. This way I could run one sound object and forgets about its properties, because whatever they'd be, there'd be a way to check if it is still playing.
This is something which is more of a dream than suggestion, but some form of ".stopFaded" function which would not stop sound immediately, but instead, fade it out for 5-10 seconds, would be also absolutely awesome. This way one could easily make seamless bridges between previous and next track.
Sorry for bothering with such long "issue", just wanted to show my gratitude to some extent ^^'