Use something like /splay <filename> StartSound
Now, when the song is finished, it triggers
on *:endofsong:*:{ }
Then the user can use this
on *:endofsong:StartSound:{ echo The start song is now finished }
Forgive me for asking the obvious - but won't you know that a song has finished due to the fact that you can't hear it any more? If I'm misunderstanding you here, my apologies.
Hehe, i ment for a script to understand that its finished
on *:MIDIEND
on *:WAVEND
on *:MP3END
these already exist.
Yeah but so you can know exacly what song that's finished..
If its the song from the mp3 player or the join-sound when you join a channel..
Lets say i'm playing a mp3, and then join a channel. When i join that channel another mp3 is played. Then it triggers the on mp3end, and the mp3song from the mp3player gets stopped and a new one starts.
just: whenever u use splay
.set %song yoursong
on *:MP3END %song has finished
No need to set a variable like that, $filename is valid in an ON MP3END. If he wants the title of the song, he can use $sound($filename).title
well.. when the on *:endofsong:*:{ } you can check if its the start sound, the mp3 player, the "you've got mail"-sound or some other sound so it doesn't mix with the mp3 player.
Therefore, i think it would be easier with an implemented on endofsong
How does mIRC know what the difference between a simple wave file is and what a song is? There is no way to tell.
well yeah _he_ can test like that, but I mean there couldn't be an ON ENDOFSONG that would allow mIRC to know whether it was a song or just a sound. Meaning, from what he is saying, ON ENDOFSONG would trigger for:
/splay someband-somesong.mp3
but not for:
/splay beep.wav
o i c, yeah thats true, also i dont see why he would need an on endofsong, when all the sound files that can be used in mirc without the use of dll's already have an on *:END
on *:endofsong:mp3player:{ playnexsong }
on *:endofsong:startsound:{ echo -s Welcome to my script }
It does trigger when a song or sound mIRC is playing stops, and if the song or sound is "marked" when the song/sound starts to play (/splay filename.wav startsound), i can see if that is the startsound or if its the mp3player.
Ok then set a variable to signal that it is a song. Making an event for that seems stupid. Use a variable and signals.