mIRC Homepage
Posted By: LCX Anti join/part script - 16/03/14 03:49 AM
Hello again,

I was wondering if there's a script for the following situation since I have looked around and have not be able to find anything online, and in this case google was not my friend... I'm looking for something that if a person were to join my channel then part it within under 2 minutes without at least stating something that upon their part it would set a ban on them for 15 minutes, an hour, etc?

Thanks in advance.
Posted By: pball Re: Anti join/part script - 16/03/14 12:58 PM
Code:
on *:join:#:{
  if (!$hget(spam)) hmake spam 100
  ;120 second join/part ban
  hadd -u120 spam $+(spam.join.,$address($nick,2)) 1
}

on *:part:#:{
  if (!$hget(spam)) hmake spam 100
  ;120 second join/part ban
  if ($hget(spam,$+(spam.join.,$address($nick,2)))) ban -u9000 $chan $address($nick,2)
}

on *:text:*:#:{
  if (!$hget(spam)) hmake spam 100
  if ($hget(spam,$+(spam.join.,$address($nick,2)))) hdel spam $+(spam.join.,$address($nick,2))
}


This should do the job, pulled this from my channel bot and tweaked it a little. Just make sure to set the channel you want to use it in and it should be good to go unless you want to change the times from 120 seconds from join to part and a 15 minute ban.
Posted By: LCX Re: Anti join/part script - 16/03/14 11:45 PM
pball, thank you for this script. I put it in and tested it and it works perfectly. Exactly what I need.
© mIRC Discussion Forums