mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Jan 2017
Posts: 20
Ameglian cow
OP Offline
Ameglian cow
Joined: Jan 2017
Posts: 20
When the song switches I want my bot to automatically say which song was playing/is now playing.
I've seen this one (on f.ex. Guardsmanbob's stream) and I'm quite interested in this function.

So far I have the simple work done with:

on *:TEXT:!song:#: {
if ((%floodsong) || ($($+(%,floodsong.,$nick),2))) { return }
set -u60 %floodsong On
if (!$play(#)) {
.play # C:\Snip\Snip.txt
}



Someone else gave me this part, however it does not work:

alias newsong {
if (%oldsong !isin %newsong) {
msg # Now Playing: $read(C:\Snip\Snip.txt)
%oldsong = %newsong
}
}

on *:TEXT:!song:#: {
if ((%floodsong) || ($($+(%,floodsong.,$nick),2))) { return }
set -u60 %floodsong On
if (!$play(#)) {
.play # C:\Snip\Snip.txt
/nowplayingtimer 0 5 newsong
var %oldsong
var %newsong = $read(C:\Snip\Snip.txt)
} }





I'm glad about any help!


Streaming games on Twitch, while guiding and helping other players!
www.twitch.tv/vijoplays
Joined: Jan 2017
Posts: 20
Ameglian cow
OP Offline
Ameglian cow
Joined: Jan 2017
Posts: 20
Okay, so as you might've noticed I have no clue about this stuff, although I slowly start to understand everything.

F.ex. I'm now using on:join: instead of on:text:*.
The problem still persists though, one thing that i guess would be possible is to post a message on join, then every 5 seconds it'll post the song name, but only if the song name is different than the one that got posted before... Would something like that be possible?

There's also a song rating system and the amount of times the song was played that I want to put into this message, (i.e. someone rates the song for 1, someone else for 3 and then the bot says "Average:2" - this one can probably be accomplished by adding a counting command to the bot).

Again, I am glad about any help, even if it's something that might not work or something that gets the job done in a similar way! =)


Streaming games on Twitch, while guiding and helping other players!
www.twitch.tv/vijoplays

Link Copied to Clipboard