Advertisement
westor

IPKO protection for niemand v1.0

Sep 19th, 2023
2,085
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
mIRC 1.26 KB | None | 0 0
  1. ON *:TEXT:*:#opers: { ; by westor on 1695133759
  2.   tokenize 32 $strip($1-)
  3.  
  4.   if ($1 !== !ipko) { return }
  5.   if (!$2) { msg $chan ( $+ $nick $+ ): Use an option, ON or OFF to continue! | return }
  6.   if (!$istok(on off,$2,32)) { msg $chan ( $+ $nick $+ ): Use only ON or OFF option! | return }
  7.  
  8.   if ($2 == ON) {
  9.     if (%ipko) { msg $chan ( $+ $nick $+): IPKO protection is already enabled! | return }
  10.  
  11.     set %ipko 1
  12.  
  13.     msg $chan ( $+ $nick $+ ): IPKO protection has been enabled.
  14.   }
  15.  
  16.   if ($2 == OFF) {
  17.     if (!%ipko) { msg $chan ( $+ $nick $+): IPKO protection is already disabled! | return }
  18.  
  19.     set %ipko 0
  20.  
  21.     msg $chan ( $+ $nick $+ ): IPKO protection has been disabled.
  22.   }
  23.  
  24. }
  25.  
  26. ON *:SNOTICE:*: { ; by westor on 1695133759
  27.   if (!%ipko) { return }
  28.  
  29.   tokenize 32 $strip($1-)
  30.  
  31.   if (*webirc-users* iswm $gettok($1-,$findtok($1-,[security-groups:,1,32) $+ -,32)) { return }
  32.  
  33.   var %nick = $4
  34.   var %ip = $remove($6,[,])
  35.  
  36.   if (%nick == $me) { return }
  37.  
  38.   if (46.99.* !iswm %ip) { return }
  39.  
  40.   var %file = shitnicks.txt
  41.   var %read = $read(%file,nw,%nick)
  42.  
  43.   if (%read) { return }
  44.  
  45.   tempshun + $+ %nick [IPKO]: This user has been temporary shunned!
  46.  
  47.   msg #opers [IPKO]: Nickname $qt(%nick) with $qt(%ip) has been temporary shunned.
  48. }
  49.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement