Advertisement
Bacon_Space

my link protection

Apr 27th, 2014
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.37 KB | None | 0 0
  1. on @*:text:*:#:linkpost $1-
  2. on @*:action:*:#:linkpost $1-
  3. on @*:notice:*:#:linkpost $1-
  4. alias -l linkpost {
  5. if ((!%p) && (!$hfind(permit,$nick))) { inc -u4 %p
  6. var %purge /^!(link\so(n|ff)|(permit))\b/iS
  7. var %domain com|edu|gov|mil|net|org|biz|info|name|museum|us|ca|uk
  8. var %link /(?<=^|\s)((?>\S{3,8}:\/\/|w{3}\56)\S+)|\56( $+ %domain $+ )\b/iS
  9. if ($findtok(%chanon,#,1,32)) && ($nick(#,$nick,vr)) && ($regex($1-,%link)) {
  10. kick # $nick | /mode # -b $nick
  11. msg # $nick -> plz don't post links
  12. msg # /timeout $nick 30
  13. }
  14. elseif (($regex($1-,%purge)) && ($regml(1) = permit) && ($nick isop #) && ($$2 ison #)) {
  15. hadd -mz permit $v1 30 | notice $v1 You have 30 seconds to post a link. Starting now!
  16. }
  17. elseif (($regml(1) = link on) && ($nick isop #)) {
  18. goto $iif(!$istok(%chanon,#,32),a,b) | :a | set %chanon $addtok(%chanon,#,32)
  19. .msg # Link Protection Is Now on in: $+($chr(2),#)
  20. halt | :b | .msg # $nick $+ , my link protection is already on $&
  21. $+($chr(2),#,$chr(2)) !
  22. }
  23. elseif (($regml(1) = link off) && ($nick isop #)) {
  24. goto $iif($istok(%chanon,#,32),c,d) | :c | set %chanon $remtok(%chanon,#,1,32)
  25. .msg # Link Protection Is Now off in: $+($chr(2),#)
  26. halt | :d | .msg # $nick $+ , My link protection is already off $&
  27. !
  28. }
  29. }
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement