Share Pastebin
Guest
Public paste!

Marr

By: a guest | Mar 13th, 2010 | Syntax: None | Size: 2.38 KB | Hits: 34 | Expires: Never
Copy text to clipboard
  1. ~~~~~~~~~~~~~~~~~~~~
  2. |||||| Talker [Wissel] Script ||||||
  3. ~~~~~~~~~~~~~~~~~~~~
  4.  
  5. menu * {
  6.   WisselTalker
  7.   . $iif($group(#talker) == on,$style(1) Enabled,Enabled): enable #talker
  8.   . $iif($group(#talker) == off,$style(1) Disabled,Disabled): disable #talker
  9. }
  10.  
  11. #talker on
  12.  
  13. on *:input:*: {
  14.   if ($chan == #room1) || ($chan == #room2) || ($chan == #room3) {
  15.     ;; Don't change anything unless you know what you're doing
  16.     if ($left($1,1) == /) { return }
  17.     if ($left($1,1) == !) { return }
  18.     if ($left($1,1) == <) { return }
  19.     if ($left($1,1) == [) { return }
  20.     if ($left($1,1) == http) { return }
  21.     if (help isin $chan) { goto none }
  22.     else {    
  23.       msg $active $checkNickColor($1-)
  24.       haltdef
  25.     }
  26.   }
  27.   else {
  28.     if ($left($1,1) == /) { return }
  29.     if ($left($1,1) == !) { return }
  30.     if ($left($1,1) == <) { return }
  31.     if ($left($1,1) == [) { return }
  32.     if ($left($1,1) == http) { return }
  33.     if (help isin $chan) { goto none }
  34.     else {
  35.       set %max.len $len($1-)
  36.       :loop
  37.       while (%max.len > 0) {
  38.         if ($ [ $+ [ %max.len ] ] == $null) { set %max.len $calc(%max.len - 1) | goto loop }
  39.         else {
  40.           set %zeg-zin 14,01  $+ $left($ [ $+ [ %max.len ] ] ,1) $+ 0,01 $+ $mid($ [ $+ [ %max.len ] ] ,2) %zeg-zin
  41.           set %max.len $calc(%max.len - 1) | goto loop
  42.         }
  43.       }
  44.       if ($rand(1,6) == 1) { msg $active 04,01** $checkNickColor(%zeg-zin) $+ 04,01 ** $+(14,$left(%teller,1),15,$mid(%teller,2,-1),04,$right(%teller,1)) }
  45.       else { msg $active 04,01** $checkNickColor(%zeg-zin) $+ 04,01 ** %woord [ $+ [ $r(1,6) ] ] }
  46.       unset %zeg-zin
  47.       halt
  48.     }
  49.   }
  50. }
  51.  
  52. ;; Don't change this, it checks if there's a nick in your text
  53. alias -l checkNickColor {
  54.   var %a 1, %str $null
  55.   while (%a <= $numtok($1,32)) {
  56.     var %w = $gettok($1,%a,32)
  57.     if ($strip(%w) ison #) var %str %str $setNickColor($strip(%w))
  58.     else var %str %str %w
  59.     inc %a
  60.   }
  61.   return %str
  62. }
  63.  
  64. ;; Change the colors of the nick-thing
  65. alias -l setNickColor {
  66.   var %a $rand(1,10)
  67.   if (%a == 1) var %c 02
  68.   if (%a == 2) var %c 03
  69.   if (%a == 3) var %c 04
  70.   if (%a == 4) var %c 06
  71.   if (%a == 5) var %c 07
  72.   if (%a == 6) var %c 08
  73.   if (%a == 7) var %c 09
  74.   if (%a == 7) var %c 10
  75.   if (%a == 8) var %c 11
  76.   if (%a == 9) var %c 12
  77.   if (%a == 10) var %c 13
  78.   return $+(,%c,$1,01)
  79. }
  80.  
  81. #talker end