|
[Twitch] Important Change to Resub Notifications
#258258
21/06/16 05:53 PM
|
Joined: May 2015
Posts: 133
keyeslol
OP
Vogon poet
|
OP
Vogon poet
Joined: May 2015
Posts: 133 |
All, before a ton of posts get made here to ask why their resubs no longer are being seen, you can read about it here: https://discuss.dev.twitch.tv/t/important-re-subscription-change/6463 I have the following code to account for this change (credit goes to JACKY1356400) : raw USERNOTICE:*:{
if ($msgtags(room-id).key == [CHANNEL ID HERE]) {
if ($2- == $null) && (resub isin $msgtags) {
msg $1 Welcome back $msgtags(display-name).key has resubscribed for $msgtags(msg-param-months).key months in a row!
}
else {
msg $1 Welcome back $msgtags(display-name).key has resubscribed for $msgtags(msg-param-months).key months in a row with the message $2-
}
}
} You'll need to get your room-id, i recommend debugging @raw and pulling the ID. Run the following: //window -e @raw | debug @raw Then change your key in the referenced code.
twitter @keyeslol
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: keyeslol]
#258262
21/06/16 11:42 PM
|
Joined: Jun 2014
Posts: 77
Khonor
Babel fish
|
Babel fish
Joined: Jun 2014
Posts: 77 |
Hey @keyeslol, So to get the Room-ID would be something as this? on *:TEXT:!roomid *:#: { if ($nick == $me) { .timermsg 1 1 /msg # Room ID: $msgtags(room-id).key } }
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Khonor]
#258276
23/06/16 03:19 PM
|
Joined: May 2015
Posts: 133
keyeslol
OP
Vogon poet
|
OP
Vogon poet
Joined: May 2015
Posts: 133 |
You can get it by putting this in a new remotes: on *:TEXT:*:#: {
if ($nick == $me) {
msg # Room ID: $msgtags(room-id).key
}
}
twitter @keyeslol
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: keyeslol]
#258278
23/06/16 03:47 PM
|
Joined: Jun 2014
Posts: 77
Khonor
Babel fish
|
Babel fish
Joined: Jun 2014
Posts: 77 |
Hi @keyeslol,
With this, the bot would have to be able to pick up the "Room-ID" of each channel automatically?
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Khonor]
#258279
23/06/16 05:13 PM
|
Joined: May 2015
Posts: 133
keyeslol
OP
Vogon poet
|
OP
Vogon poet
Joined: May 2015
Posts: 133 |
That is correct. Just have the bot type anything in the channel you need the room-id for.
We could technically do this all automatically, write this to a var, like %roomid. < key > .channel and call this in our resub.
Instead of the room-id == [ ID HERE ] it would be room-id == %room.id
I'd have to write the code though to do it all automatically. But here's the thing, i wouldn't want to process the on * event all the time, as i only need the room ID once.
Better to just grab it once, instead of writing the ID to a var.
twitter @keyeslol
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: keyeslol]
#258288
23/06/16 07:52 PM
|
Joined: Jun 2014
Posts: 77
Khonor
Babel fish
|
Babel fish
Joined: Jun 2014
Posts: 77 |
Something like this works? I apologize if you have errors and ask many questions, it's just I'm new to mIRC. Original: raw USERNOTICE:*:{ if ($msgtags(room-id).key == [CHANNEL ID HERE]) { if ($2- == $null) && (resub isin $msgtags) { msg $1 Welcome back $msgtags(display-name).key has resubscribed for $msgtags(msg-param-months).key months in a row! } else { msg $1 Welcome back $msgtags(display-name).key has resubscribed for $msgtags(msg-param-months).key months in a row with the message $2- } } } Example edited script: raw USERNOTICE:*:{ if ($chan == #channame && ( $msgtags(msg-id).key == resub)) {
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Khonor]
#258289
23/06/16 08:15 PM
|
Joined: May 2015
Posts: 133
keyeslol
OP
Vogon poet
|
OP
Vogon poet
Joined: May 2015
Posts: 133 |
No need to check if $chan == xxx && room-id == xxx
room-id is unique, and only for the channel the resub occurs in. Use my original code, and reference the room-id where it says [channel id]
twitter @keyeslol
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: keyeslol]
#258292
23/06/16 08:32 PM
|
Joined: Jun 2014
Posts: 77
Khonor
Babel fish
|
Babel fish
Joined: Jun 2014
Posts: 77 |
Well thank you very much for all the information and help @keyeslol. Very thankful.
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Khonor]
#258306
24/06/16 09:55 AM
|
Joined: Apr 2015
Posts: 42
Artiiz
Ameglian cow
|
Ameglian cow
Joined: Apr 2015
Posts: 42 |
@keyeslol So this one should work fine then? I've put "#yznb", because I only want it to type in that channel, since I'm connected to more than 1 in IRC.
raw USERNOTICE:*:#yznb:{
if ($msgtags(room-id).key == [31582993]) {
if ($2- == $null) && (resub isin $msgtags) {
msg $1 xanHY xanPE yznSOLD (ノ◕ヮ◕)ノ ✧ ( $+ $msgtags(display-name).key $+ ) stayed on #YZNARMY for ( $+ $msgtags(msg-param-months).key $+ ) months! yznLOVE yznHYPE
}
else {
msg $1 xanHY xanPE yznSOLD (ノ◕ヮ◕)ノ ✧ ( $+ $msgtags(display-name).key $+ ) stayed on #YZNARMY for ( $+ $msgtags(msg-param-months).key $+ ) months! yznLOVE yznHYPE ( Note: $2- )
}
}
}
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Artiiz]
#258314
24/06/16 06:16 PM
|
Joined: May 2015
Posts: 133
keyeslol
OP
Vogon poet
|
OP
Vogon poet
Joined: May 2015
Posts: 133 |
You don't need to put the channel in, as the room-id is unique to the channel the resub occurs in. IE, it won't display in any other channel than the one the room-id is tied to. But it doesn't hurt if you want to have it in there. Technically it saves a minuscule amount of CPU. @keyeslol So this one should work fine then? I've put "#yznb", because I only want it to type in that channel, since I'm connected to more than 1 in IRC.
raw USERNOTICE:*:#yznb:{
if ($msgtags(room-id).key == [31582993]) {
if ($2- == $null) && (resub isin $msgtags) {
msg $1 xanHY xanPE yznSOLD (ノ◕ヮ◕)ノ ✧ ( $+ $msgtags(display-name).key $+ ) stayed on #YZNARMY for ( $+ $msgtags(msg-param-months).key $+ ) months! yznLOVE yznHYPE
}
else {
msg $1 xanHY xanPE yznSOLD (ノ◕ヮ◕)ノ ✧ ( $+ $msgtags(display-name).key $+ ) stayed on #YZNARMY for ( $+ $msgtags(msg-param-months).key $+ ) months! yznLOVE yznHYPE ( Note: $2- )
}
}
}
twitter @keyeslol
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: keyeslol]
#258315
24/06/16 06:28 PM
|
Joined: Apr 2015
Posts: 42
Artiiz
Ameglian cow
|
Ameglian cow
Joined: Apr 2015
Posts: 42 |
You don't need to put the channel in, as the room-id is unique to the channel the resub occurs in. IE, it won't display in any other channel than the one the room-id is tied to. But it doesn't hurt if you want to have it in there. Technically it saves a minuscule amount of CPU. @keyeslol So this one should work fine then? I've put "#yznb", because I only want it to type in that channel, since I'm connected to more than 1 in IRC.
raw USERNOTICE:*:#yznb:{
if ($msgtags(room-id).key == [31582993]) {
if ($2- == $null) && (resub isin $msgtags) {
msg $1 xanHY xanPE yznSOLD (ノ◕ヮ◕)ノ ✧ ( $+ $msgtags(display-name).key $+ ) stayed on #YZNARMY for ( $+ $msgtags(msg-param-months).key $+ ) months! yznLOVE yznHYPE
}
else {
msg $1 xanHY xanPE yznSOLD (ノ◕ヮ◕)ノ ✧ ( $+ $msgtags(display-name).key $+ ) stayed on #YZNARMY for ( $+ $msgtags(msg-param-months).key $+ ) months! yznLOVE yznHYPE ( Note: $2- )
}
}
}
Oh alright. I tried using this earlier today but it didn't quite seem to be working anyway. Do I need to make a whole new Remote script for this, and restart mIRC after writing it in?
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Artiiz]
#258323
25/06/16 01:35 AM
|
Joined: May 2015
Posts: 133
keyeslol
OP
Vogon poet
|
OP
Vogon poet
Joined: May 2015
Posts: 133 |
Try taking out the brackets after room-id.key ==
twitter @keyeslol
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: keyeslol]
#258326
25/06/16 06:44 AM
|
Joined: Jun 2016
Posts: 1
ifuse
Mostly harmless
|
Mostly harmless
Joined: Jun 2016
Posts: 1 |
I'm guessing that I need to do raw CAP REQ :twitch.tv/tags. But when I do it, my bot wont get any of the chat messages from twitch. Do I need to add/do a script to capture chat or something?
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Artiiz]
#258333
25/06/16 02:10 PM
|
Joined: Jun 2014
Posts: 77
Khonor
Babel fish
|
Babel fish
Joined: Jun 2014
Posts: 77 |
Hey @Artiiz, Actually in the Room-ID is not going " [ ]" or the bot will not respond you, at least in my case did not. raw USERNOTICE:*:#yznb:{ if ($msgtags(room-id).key == 31582993) { if ($2- == $null) && (resub isin $msgtags) { msg $1 xanHY xanPE yznSOLD (ノ◕ヮ◕)ノ ✧ ( $+ $msgtags(display-name).key $+ ) stayed on #YZNARMY for ( $+ $msgtags(msg-param-months).key $+ ) months! yznLOVE yznHYPE } else { msg $1 xanHY xanPE yznSOLD (ノ◕ヮ◕)ノ ✧ ( $+ $msgtags(display-name).key $+ ) stayed on #YZNARMY for ( $+ $msgtags(msg-param-months).key $+ ) months! yznLOVE yznHYPE ( Note: $2- ) } } }
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: keyeslol]
#258340
25/06/16 10:37 PM
|
Joined: Jun 2016
Posts: 1
Bnz
Mostly harmless
|
Mostly harmless
Joined: Jun 2016
Posts: 1 |
Hi im a little bit confused. i used the following script for new subs and resubs and it worked great. Now with the changes sometimes it works, sometimes it doesnt. Appreciate any help for a solution.
ON *:TEXT:*subscribed*:#channelname:{
if ( $nick == twitchnotify ) && ($istok($1-,subscribed to,32)) halt
elseif ($nick == twitchnotify) && ( $4 == $null ) { describe $chan Welcome $1! RANDOM MSG }
elseif ($nick == twitchnotify) && ( $4 isnum ) { describe $chan Wow! $1 Welcome $1! RANDOM MSG }
}
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Bnz]
#258349
26/06/16 03:31 PM
|
Joined: Apr 2016
Posts: 86
Bestpeff
Babel fish
|
Babel fish
Joined: Apr 2016
Posts: 86 |
If the channel name is removed and automatically recognized....I don't understand how it'll work if your bot is connect to multiple Twitch partner's chat??
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: ifuse]
#258362
27/06/16 04:42 PM
|
Joined: May 2015
Posts: 133
keyeslol
OP
Vogon poet
|
OP
Vogon poet
Joined: May 2015
Posts: 133 |
I'm guessing that I need to do raw CAP REQ :twitch.tv/tags. But when I do it, my bot wont get any of the chat messages from twitch. Do I need to add/do a script to capture chat or something? What version of mIRC are you using? I'm using the latest, and requesting the following: raw CAP REQ :twitch.tv/membership
raw CAP REQ :twitch.tv/tags
raw CAP REQ :twitch.tv/commands Chat messages appear just fine for me.
twitter @keyeslol
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Bnz]
#258363
27/06/16 04:43 PM
|
Joined: May 2015
Posts: 133
keyeslol
OP
Vogon poet
|
OP
Vogon poet
Joined: May 2015
Posts: 133 |
Take out the last line of your code and use the new code. Hi im a little bit confused. i used the following script for new subs and resubs and it worked great. Now with the changes sometimes it works, sometimes it doesnt. Appreciate any help for a solution.
ON *:TEXT:*subscribed*:#channelname:{
if ( $nick == twitchnotify ) && ($istok($1-,subscribed to,32)) halt
elseif ($nick == twitchnotify) && ( $4 == $null ) { describe $chan Welcome $1! RANDOM MSG }
elseif ($nick == twitchnotify) && ( $4 isnum ) { describe $chan Wow! $1 Welcome $1! RANDOM MSG }
}
twitter @keyeslol
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: Bestpeff]
#258364
27/06/16 04:45 PM
|
Joined: May 2015
Posts: 133
keyeslol
OP
Vogon poet
|
OP
Vogon poet
Joined: May 2015
Posts: 133 |
It works because you'll specify unique room-ids for the channels your bot is connected to. Room-id's are unique to each room. We were talking about how to auto populate the room-id variable in the above code. However, the bots I've coded/managed do not do it this way. I've grabbed them once and set them. If the channel name is removed and automatically recognized....I don't understand how it'll work if your bot is connect to multiple Twitch partner's chat??
twitter @keyeslol
|
|
|
Re: [Twitch] Important Change to Resub Notifications
[Re: keyeslol]
#258713
15/08/16 10:30 PM
|
Joined: Jun 2016
Posts: 8
GoldenTaco
Nutrimatic drinks dispenser
|
Nutrimatic drinks dispenser
Joined: Jun 2016
Posts: 8 |
I know this section may have been forgotten and this may or may not be such a basic question, but whenever I add multiple messages to the script it doesn't come through, I use the $msg #chan Blah blah and it does make extra chat lines, help would be greatly appreciated. Thank you! 
|
|
|
|
|
|