mIRC Home    About    Download    Register    News    Help

Topic Options
#249433 - 29/11/14 04:53 PM Create a Twitch uptime command
Nathanael Offline
Ameglian cow

Registered: 29/11/14
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"

Top
#249434 - 29/11/14 04:57 PM Re: Create a Twitch uptime command [Re: Nathanael]
Nillen Offline
Hoopy frood

Registered: 24/12/13
Posts: 779
Loc: Sweden
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

Top
#249455 - 30/11/14 03:52 PM Re: Create a Twitch uptime command [Re: Nillen]
Nathanael Offline
Ameglian cow

Registered: 29/11/14
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?


Edited by Nathanael (30/11/14 03:54 PM)

Top
#249456 - 30/11/14 03:58 PM Re: Create a Twitch uptime command [Re: Nathanael]
Nillen Offline
Hoopy frood

Registered: 24/12/13
Posts: 779
Loc: Sweden
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

Top
#249480 - 30/11/14 11:16 PM Re: Create a Twitch uptime command [Re: Nillen]
Nathanael Offline
Ameglian cow

Registered: 29/11/14
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


Edited by Nathanael (30/11/14 11:21 PM)

Top
#249481 - 30/11/14 11:16 PM Re: Create a Twitch uptime command [Re: Nathanael]
Nillen Offline
Hoopy frood

Registered: 24/12/13
Posts: 779
Loc: Sweden
At the very top. Just like the other script you have.
_________________________
Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net

Top
#249482 - 30/11/14 11:27 PM Re: Create a Twitch uptime command [Re: Nillen]
Nathanael Offline
Ameglian cow

Registered: 29/11/14
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

Top
#249485 - 30/11/14 11:44 PM Re: Create a Twitch uptime command [Re: Nathanael]
Nillen Offline
Hoopy frood

Registered: 24/12/13
Posts: 779
Loc: Sweden
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

Top
#249488 - 01/12/14 01:05 AM Re: Create a Twitch uptime command [Re: Nillen]
Nathanael Offline
Ameglian cow

Registered: 29/11/14
Posts: 21
I figured out how to message certain channels.

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

Top
#249489 - 01/12/14 01:12 AM Re: Create a Twitch uptime command [Re: Nathanael]
Nillen Offline
Hoopy frood

Registered: 24/12/13
Posts: 779
Loc: Sweden
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

Top
#249490 - 01/12/14 01:26 AM Re: Create a Twitch uptime command [Re: Nillen]
Nathanael Offline
Ameglian cow

Registered: 29/11/14
Posts: 21
Thanks for the help!

Top