mIRC Home    About    Download    Register    News    Help

Topic Options
#265584 - 03/06/19 07:50 AM twitch subscriber script help
Hazman Offline
Pikka bird

Registered: 13/12/16
Posts: 16
Hello I'm just getting back into mirc and am wondering if someone could help me with this, trying to get it so the sub gift script would post 1 message with "%nick has gifted x amount of subs" with the number of subs gifted rather than it being a constant spam of the user who gifted the subs to the other users if multiple, if only one it would be the %nick who gifted the sub to the username.

on :LOGON::{
raw CAP REQ :twitch.tv/membership
raw CAP REQ :twitch.tv/tags
raw CAP REQ :twitch.tv/commands
/debug @raw
}

raw USERNOTICE::{
if (($msgtags(msg-id).key == subgift) && ($1 == #channel)) {
var %nick_from $iif($msgtags(display-name).key, $v1, $msgtags(login).key) , %nick_to $iif($msgtags(msg-param-recipient-display-name).key, $v1, $msgtags(msg-param-recipient-user-name).key)
describe $1 Thank you %nick_from for gifting a sub to %nick_to
raw USERNOTICE::{
if (($msgtags(msg-id).key == sub) && ($1 == #channel)) {
var %nick $iif($msgtags(display-name).key, $v1, $msgtags(login).key)
msg $1 NEW SUB!! %nick welcome
}
elseif (($msgtags(msg-id).key == resub) && ($1 == #channel)) {
var %nick $iif($msgtags(display-name).key, $v1, $msgtags(login).key)
if ($0 == 1) {
msg $1 RESUB!! %nick welcome back for $msgtags(msg-param-months).key months in a row!
}
else {
msg $1 RESUB!! %nick welcome back for $msgtags(msg-param-months).key months in a row!
}
}
}

Top
#265591 - 04/06/19 09:47 PM Re: twitch subscriber script help [Re: Hazman]
Blas Offline
Vogon poet

Registered: 27/10/15
Posts: 111
Hi. There seems to be new topic on Twitch Sub alerts scripts very often, so I'm trying answer everything in one thread. You can take a look at my example script there as it does the function that you are requesting. If you have any questions, please ask there. Thanks. smile
_________________________
My Twitch mIRC Bot Games and Stuff

Top