Alexandru commented on a Page, Need Help Reading !song Cmd  -  May 12, 2017

As I understand to this code, I can say that if Bacon_Space writes !song on a channel, then the script will read a random line from the file CurrentSong.txt and give this message on that channel.

Pay attention that this script will work if Bacon_Space will write !song and if another writes, then will not work. If CurrentSong.txt has only one line of text in it, so this line will be sent to channel, otherwise will read a random line from it.

The Script will not work if Bacon_Space will add something to !song, i.e. !song cmd or !song play. In this case, you have to change the code to the following (of course if !song is the first word separated by space):

on *:TEXT:*:#: {
  if ($nick == Bacon_Space) && ($1 == !song) {
    msg $chan $Read(‪C:\Users\Bacon_Space\AppData\Roaming\AnkhHeart\AnkhBotR2\Twitch\Files\CurrentSong.txt)
  }
}
Bacon_Space  -  May 12, 2017

How would i make it say if its not playing anything new else if Not Playing Anything https://surl.im/i/20ude.png
Not Reading it

illhawkthat  -  May 19, 2017

@Bacon_Space
try adding a if $Read(‪C:\Users\Bacon_Space\AppData\Roaming\AnkhHeart\AnkhBotR2\Twitch\Files\CurrentSong.txt) != $null msg chan

Sign in to comment

Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.