mIRC Home    About    Download    Register    News    Help

Print Thread
Create a Twitch uptime command #249433 29/11/14 04:53 PM
Joined: Nov 2014
Posts: 21
N
Nathanael Offline OP
Ameglian cow
OP Offline
Ameglian cow
N
Joined: Nov 2014
Posts: 21
What I want to be able to do is get the text that is being said on the website and be able to make my Twitch bot say it.

www.decapi.me/twitch/uptime.php?channel="CHANNEL_NAME"

Re: Create a Twitch uptime command [Re: Nathanael] #249434 29/11/14 04:57 PM
Joined: Dec 2013
Posts: 779
N
Nillen Offline
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
Never seen that site before, when I tried it I kept getting "Channel does not exist"..

I made a script for someone way back using nightdev, you can find it here. You'd have found it if you searched for "uptime" using the search feature.


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Re: Create a Twitch uptime command [Re: Nillen] #249455 30/11/14 03:52 PM
Joined: Nov 2014
Posts: 21
N
Nathanael Offline OP
Ameglian cow
OP Offline
Ameglian cow
N
Joined: Nov 2014
Posts: 21
Thanks for that! However, how do I add a cool down for that command? For example:

Originally Posted By: code
on *:text:!bot:$($allowed):{
if (!%comwait. [ $+ [ $chan ] ]) {
set -u120 %comwait. $+ $chan 1
describe $chan Hello. My name is Emmanuel, but people call me TheCatbot. My owner is Old_School_RuneScape.
}
}


Also, how do I make the first letter of the channel a capital letter?

Last edited by Nathanael; 30/11/14 03:54 PM.
Re: Create a Twitch uptime command [Re: Nathanael] #249456 30/11/14 03:58 PM
Joined: Dec 2013
Posts: 779
N
Nillen Offline
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
Capital: see http://forums.mirc.com/ubbthreads.php/topics/249415/ID_uppercase_first_letter#Post249417

Cooldown: If you already have that, then you should know how to add it to other features. If you don't, you just copy over
Code:
if (!%comwait. [ $+ [ $chan ] ]) {
set -u120 %comwait. $+ $chan 1
to the code you want.


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Re: Create a Twitch uptime command [Re: Nillen] #249480 30/11/14 11:16 PM
Joined: Nov 2014
Posts: 21
N
Nathanael Offline OP
Ameglian cow
OP Offline
Ameglian cow
N
Joined: Nov 2014
Posts: 21
That is my problem. I do not know where to put it.

Oh I figured out where to put it.

What do I put if I want it to work in a specific channel

Last edited by Nathanael; 30/11/14 11:21 PM.
Re: Create a Twitch uptime command [Re: Nathanael] #249481 30/11/14 11:16 PM
Joined: Dec 2013
Posts: 779
N
Nillen Offline
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
At the very top. Just like the other script you have.


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Re: Create a Twitch uptime command [Re: Nillen] #249482 30/11/14 11:27 PM
Joined: Nov 2014
Posts: 21
N
Nathanael Offline OP
Ameglian cow
OP Offline
Ameglian cow
N
Joined: Nov 2014
Posts: 21
What do I put if I want it to work in a specific channel? Also, I do not know where to put the alias frown

I am quite newbie with mIRC :P

Re: Create a Twitch uptime command [Re: Nathanael] #249485 30/11/14 11:44 PM
Joined: Dec 2013
Posts: 779
N
Nillen Offline
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
Put the alias anywhere in your remote.
The variable is set to work on all channels since it uses "$chan"


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Re: Create a Twitch uptime command [Re: Nillen] #249488 01/12/14 01:05 AM
Joined: Nov 2014
Posts: 21
N
Nathanael Offline OP
Ameglian cow
OP Offline
Ameglian cow
N
Joined: Nov 2014
Posts: 21
I figured out how to message certain channels.

I do not know where I put $capital(string)

Re: Create a Twitch uptime command [Re: Nathanael] #249489 01/12/14 01:12 AM
Joined: Dec 2013
Posts: 779
N
Nillen Offline
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
Try this and see if you can figure it out from context:
Code:
on *:text:!capital:#: {
if ($2) msg # You just wrote $2 $+ ! The capital version is $capital($2)
else msg # Your nick is $nick $+ ! The capital version is $capital($nick)
}


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Re: Create a Twitch uptime command [Re: Nillen] #249490 01/12/14 01:26 AM
Joined: Nov 2014
Posts: 21
N
Nathanael Offline OP
Ameglian cow
OP Offline
Ameglian cow
N
Joined: Nov 2014
Posts: 21
Thanks for the help!