mIRC Home    About    Download    Register    News    Help

Print Thread
script to hold a nick for a few seconds on connect #269137 23/06/21 11:34 AM
Joined: Oct 2014
Posts: 49
O
Orobas Offline OP
Ameglian cow
OP Offline
Ameglian cow
O
Joined: Oct 2014
Posts: 49
Looking for a script please that will tempshun a nick on connect for a few seconds that matches a set pattern before unshunning just to help us out with some spammers trying to get on

the connect message looks like

[11:20] <ChanServ> USERS: Monica694!~Mibbit@xx.xx.xx.xx (990693CA.9FC5C4F3.F9E92EF2.IP) (http://www.mibbit.com) connected to the network (our network is here)
11:14] <ChanServ> USERS: Stephanie800!Mibbit@xx.xx.xx.xx (555560E4.5124B86E.EB45475D.IP) (http://www.mibbit.com) connected to the network (our network is here)

want the script to act on the 3 numbers and first letter before the ! eg.. the a694 or e800 ... whatever the last letter and 3 numbers are.. no more numbers.. its always 3 numbers, then the ! on this catch

When the user connects i would like a tempshun placed and run for 20secs before it is removed

I'm mirc 7.63 and its unrealircd 5.2.0. We have a working spamfilter already that is set correctly and working.. we're just looking to go a bit more proactive with the deterrent

Re: script to hold a nick for a few seconds on connect [Re: Orobas] #269139 23/06/21 06:12 PM
Joined: Jul 2006
Posts: 3,790
W
Wims Offline
Hoopy frood
Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 3,790
Code
on $*:Snotice:$( USERS: ([^!]*[a-zA-Z]\d{3})![^@]+@[^ ]+ \([^) ]+\) \(\S+\) connected to the network NETWORKHERE):/tempshun $regml(1)
Something like that

Last edited by Wims; 23/06/21 09:00 PM.

Looking for a good help channel about mIRC? Check #mircscripting @ irc.swiftirc.net
Re: script to hold a nick for a few seconds on connect [Re: Wims] #269140 23/06/21 07:06 PM
Joined: Oct 2014
Posts: 49
O
Orobas Offline OP
Ameglian cow
OP Offline
Ameglian cow
O
Joined: Oct 2014
Posts: 49
I like the idea.. but .. i would have to copy this for each of the different networks we have
can we strip this down to cut off at connected to the network to make things easier ?

Re: script to hold a nick for a few seconds on connect [Re: Orobas] #269145 25/06/21 10:45 AM
Joined: Jul 2006
Posts: 3,790
W
Wims Offline
Hoopy frood
Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 3,790
Yes smile


Looking for a good help channel about mIRC? Check #mircscripting @ irc.swiftirc.net
Re: script to hold a nick for a few seconds on connect [Re: Wims] #269151 29/06/21 03:07 PM
Joined: Oct 2014
Posts: 49
O
Orobas Offline OP
Ameglian cow
OP Offline
Ameglian cow
O
Joined: Oct 2014
Posts: 49
Had to go filter side in the end as there was a regml error on the script when it was running

I'll probably have a look and see if i can debug it ... but the script as is was not a worker.

Thanks for the idea and first thoughts though

Re: script to hold a nick for a few seconds on connect [Re: Orobas] #269153 29/06/21 05:50 PM
Joined: Jul 2006
Posts: 3,790
W
Wims Offline
Hoopy frood
Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 3,790
Script works but I probably misread what your input string would be from the on snotice event, I'm not even sure that you would need that event as the only thing you have shown here is a message sent from chanserv on some channels.
You can see the regex working here, but it then depends on your input, if you even need the snotice event or some on text event instead: https://regex101.com/r/YTrccL/1

That being said, mirc scripts are of course not suited for this task and writing a custom module or using the one already existing for your IRCD would be far better.


Looking for a good help channel about mIRC? Check #mircscripting @ irc.swiftirc.net