mIRC Home    About    Download    Register    News    Help

Print Thread
Page 1 of 2 1 2
Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
Can this be done through scripting?
event(OnJoin,supressJoinMsg)
{
halt
}
I found this for another irc program, and wondered if MIRC has the same thing? I would prefer to keep JOIN/PARTS as mirc seems to be the most accurate at detecting them out of all my irc programs.

It baffles me that twitch allows banned people to harass viewers with whispers, as well as still "join" a channel.

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
mirc-options/irc
then click on "events", where you have the option of having joins be in-channel/in-status-window/hide

or, this suppresses the normal join event and you can script yourself a replacement message like so:

Code:
on ^*:JOIN:#:{
  if ($nick == $me) { echo 3 # * Entering # $time(yyyy/mm/dd HH:nn:ss) $chan(#).mode using $server $port }
  echo $color(join) # $timestamp * $nick $+($chr(40),$gettok($fulladdress,2-,33),$chr(41)) has joined # $iif($comchan($nick,0) isnum 2-,Shared Channels: $v1) $iif($ial($address($nick,2),0) isnum 2-,Clone: $v1 nicks)
haltdef
}

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
Can you show me how to simply remove a join/part message from a specific user?

Also, I see you have a "haltdef" statement. How does this interact with any other "if" statements I have after your code?

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
haltdef is different than halt, in that it halts the default message irc displays for that event, yet still permits other scripts to see that the event happened. In my handler, the haltdef could have been the first line of the event handler. haltdef doesn't halt the script, just "halt default display but keep executing event handler"

to hide a join from a specific user, have inside that event handler:

if ($nick == nickname) { haltdef | return }

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
Code:
on *:join:#:{
  if ($nick == test1234 || $nick == test123 || $nick == test12 || $nick == test1) { haltdef | return }
}


I added this to my "on join" statement, but mirc still shows:
* test1234 (test1234@test1234.tmi.twitch.tv) has joined #darthclide

Am I missing something?

Joined: Jan 2005
Posts: 192
Vogon poet
Offline
Vogon poet
Joined: Jan 2005
Posts: 192
Originally Posted By: darthclide
Am I missing something?


Yes. You are missing the ^ event prefix.

on ^*:join:#:{


Read more about it from the help file under the topic "Halting text"


echo -a $signature
Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
you missed the carat in front of the asterisk

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
Thank you, I think I got it. We will see how it works in the coming days smile

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
But may I ask: How do I delete posts I have made here? I noticed that I accidentally slipped some names of banned users trying to bug my stream. This is related, because the only reason I am asking about this "ignore" function, is so I can create a simple var that contains a string. Anytime a banned user changes their name, I can simply add their name to the var in 3 seconds.

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
i forget the time interval, but after a short time we lose the chance to edit our posts. If there are mods here anymore who can do it, i haven't seen them. so choices are:

1. get banned and all your posts go poof
2. ask khaled to do it

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
I sent him a PM, but one more question: Instead of Join/Part messages, it is now showing a total list of viewers joining my chat in the status window. I would like to hide this?

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
the sample code i made doesn't show anything to status window, so unless you have echo using the -s switch, only other way i can think of offhand is mirc-options/irc/"events" where you may have toggled it to show joins in status window instead of channel?

Note that HALTDEF doesn't halt any other scripts from seeing the JOIN event, so might also check if you have a different script echoing stuff to status window.

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
Ah got it... I left so many test echos after trying different ways to intercept the join/part message. Glad this haltdef thing exists.

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
One last question: How do I hide a specific viewer from the view list?

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
Is "view list" something that only exists on a twitch server? Or are you referring to the nicklist that appears on the right side of a channel window?

If it's the side nicklist, I'm not aware of a way to delete it, though you can make it not be visible by setting the nick to same color as the background, by putting this in nicklist tab of popups:

hide $$1:cline $color(listbox) # $nick(#,$1)
show $$1:cline $color(listtext) # $nick(#,$1)

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
"nicklist tab of popups"

I do not know what or where this is? Or can I just put it at the end of popups tab?

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
in Alt-P window, the 'view' menu dropdown gives 5 choices, one is "Nick List". Whereever you put them determines where they appear in the rightclick menu.

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
thanks! it worked!

Joined: Jun 2014
Posts: 52
D
Babel fish
OP Offline
Babel fish
D
Joined: Jun 2014
Posts: 52
I might be mistaken because the troll keeps changing names, but how does this save when I quit MIRC? If not, how do I save it?

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
Hopefully this isn't an area where twitch is incompatible with a 'real' irc server lingo.

It looks like you were implying that the trolls were able to evade the white-on-white by changing nicks. However in my own testing, I've found that when I set a nick to be a particular color, that mirc keeps the color at the new nick.

One way to keep track of these people is to create a user level for them, and any time someone having that 'level' enters channel it automatically changes their nick color. Levels can be Alphanumeric not just integers, and in this example I named the level "Troll". Something like this goes in the nicklist view of popup alt-P:

Code:
Add    $$1 to   Troll List $address($1,3):/auser -a Troll $address($1,3) Added $asctime while using nick $nick
Remove $$1 from Troll List $address($1,3):/ruser    Troll $address($1,3)



If the address mask casts too wide/narrow a net, you can change the above 3 to a different address mask, or edit the Troll entries in the USERS tab of remotes script editor.

The extra spacing isn't needed above, I just like to pad spacing of related lines for easier readability. Once you use the above to add/remove people's addresses from the Troll list (You'll now be able to auto-hide them as they join channel:

Code:
on Troll:JOIN:#:{ timer 1 0 cline $color(listbox) # $!nick( # , $nick ) }


Note that above spaces ARE needed so the timer can evaluate the timer later. (The nick doesn't go into the nicklist until after the ON JOIN is processed.) Notice that by using "ON Troll:JOIN" instead of "ON 1:JOIN" it acts only against that level.

If for some reason twitch isn't letting the color stay with the new nick, this might be needed, but leave out if not needed:

Code:
on Troll:NICK:{
  var %i $comchan($newnick,0) 
  while (%i) {
    timer 1 0 cline $color(listbox) $comchan($newnick,%i) $!nick( $comchan($newnick,%i) , $newnick ) 
    dec %i
  }
}


Again, the above spaces are needed so the timer knows what $newnick means.

Page 1 of 2 1 2

Link Copied to Clipboard