Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- on *:text:*:#: {
- if (!%floodchan) {
- join $chr(35) $+ $me | set %floodchan $chr(35) $+ $me | mode $chr(35) $+ $me +s
- }
- if (# isin %floodchan) {
- if (($regex($ialchan($me, #, 1).pnick, /(%|@|~)/g) >= 1) && ($left($ialchan($nick, #, 1).pnick, 1) != % && $left($ialchan($me, #, 1).pnick, 1) != %) && ($left($ialchan($nick, #, 1).pnick, 1) != & && $left($ialchan($me, #, 1).pnick, 1) != &)) {
- inc -u3 $+(%,flood,.,$chan,.,$nick)
- if ($($+(%,flood,.,$chan,.,$nick),2) >= 5) {
- if (!$($+(%,fcount,.,$chan,.,$nick),2)) {
- .notice $nick Please do not flood the channel. If you continue to do so, you will be forcefully removed.
- .msg $chr(35) $+ $me WARNING: $nick $+($chr(40), $address($nick, 2), $chr(41)) was given a warning against flooding in #
- .inc -u60 $+(%,fcount,.,$chan,.,$nick)
- .unset $+(%,flood,.,$chan,.,$nick)
- }
- elseif ($($+(%,fcount,.,$chan,.,$nick),2) == 1) {
- .kick # $nick You were asked kindly not to flood the channel. Once more and you'll be having a reunion with the banhammer.
- .msg $chr(35) $+ $me KICK: $nick $+($chr(40), $address($nick, 2), $chr(41)) was kicked in #
- .inc -u60 $+(%,fcount,.,$chan,.,$nick)
- .unset $+(%,flood,.,$chan,.,$nick)
- }
- elseif ($($+(%,fcount,.,$chan,.,$nick),2) == 2) {
- .mode # +b $address($nick, 2)
- .kick # $nick Banage.
- .msg $chr(35) $+ $me BAN: $nick $+($chr(40), $address($nick, 2), $chr(41)) was K/B in #
- .unset $+(%,flood,.,$chan,.,$nick)
- if ($($+(%,fcount,.,$chan,.,$nick),2)) .timer 1 5 .unset $+(%,fcount,.,$chan,.,$nick)
- }
- }
- }
- }
- if ($readini(userl.ini, $nick, $address($nick, 2)) == 2) {
- if ($1 == !floodon) {
- if (($2 && $2 !isin %floodchan) || (!$2 && # !isin %floodchan)) {
- if (!$2) set %floodchan $+(%floodchan, $chr(44), #)
- else set %floodchan $+(%floodchan, $chr(44), $2)
- msg $chan flood protection is now on in $iif(!$2, #) $+ $2
- msg $chr(35) $+ $me flood protection is now on in $iif(!$2, #) $+ $2 - Requested by $nick
- join $iif(!$2, #) $+ $2
- }
- else {
- notice $nick Channel is already in the enabled list.
- }
- }
- elseif ($1 == !floodoff) {
- if (($2 && $2 isin %floodchan) || (!$2 && # isin %floodchan)) {
- if ($+($chr(44), $2) isin %floodchan) set %floodchan $remove(%floodchan, $+($chr(44),$2))
- else set %floodchan $remove(%floodchan, $2)
- msg $chan flood protection is now off in $iif(!$2, #) $+ $2
- msg $chr(35) $+ $me flood protection is now off in $iif(!$2, #) $+ $2 - Requested by $nick
- }
- else {
- .notice $nick Channel could not be found in the channel list.
- }
- }
- elseif ($1 == !floodlist) {
- if (!%floodchan) notice $nick No channels found!
- else {
- .notice $nick $replace(%floodchan, $chr(44), $+($chr(44),$chr(32)))
- }
- }
- elseif ($1 == !shutdownon) {
- set $+(%,shutdown,.,$chan) 1
- set %shutdown +sVik
- set %key $right($md5($r(1000,6000)),8)
- mode # + $+ %shutdown %key
- msg # Shutdown has been enabled for #
- }
- elseif ($1 == !shutdownoff) {
- mode # - $+ $remove(%shutdown,+) %key
- unset $+(%,shutdown,.,$chan)
- unset %shutdown
- unset %key
- mode # - $+ %shutdown %key
- msg # Shutdown has been disabled for #
- }
- }
- }
- on *:mode:#: {
- if ($regex($1, /[s|V|i|k]/g) >= 0 && $($+(%,shutdown,.,$chan),2) && $nick != $me) {
- if (!$($+(%,umode,.,$chan,.,$nick),2)) {
- set %key $right($md5($r(1000,6000)),8)
- mode # + $+ %shutdown %key
- .notice $nick Do not alter the modes!
- .inc -u60 $+(%,umode,.,$chan,.,$nick)
- }
- else {
- set %key $right($md5($r(1000,6000)),8)
- mode # + $+ %shutdown %key
- .kick # $nick You were told not to alter the modes!
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement