Advertisement
westor

Network Relay Messages v1.4 for CooL

Sep 12th, 2019
525
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
mIRC 1.33 KB | None | 0 0
  1. alias -l from_network { return EFNet }
  2. alias -l from_channel { return #arv1 }
  3. alias -l output_network { return DALNet }
  4. alias -l output_channel { return #arv2 }
  5.  
  6. alias debug_output {
  7.   if (!$output_network) && (!$output_channel) || (!$from_network) || (!$from_channel) { return }
  8.  
  9.   var %cid = $find_cid($output_network)
  10.   if (!%cid) { return }
  11.  
  12.   scid -t1 %cid
  13.  
  14.   var %raw = $strip($1-)
  15.   var %msg = $mid($gettok(%raw,5-,32),2-)
  16.   var %chan = $gettok(%raw,4,32)
  17.  
  18.   if (%msg == $null) && ($network !== $output_network) && ($status !== connected) && ($me !ison $output_channel) && (%chan !== $from_channel) && (%msg == TIMEOUTCHECK) { return }
  19.  
  20.   if ($left(%msg,5) == [PRE]) { var %msg = Hello $gettok(%msg,3-,32) }
  21.  
  22.   if (*123* iswm %msg) || (*321* iswm %msg) { msg $output_channel %msg | return }
  23.  
  24.   editbox $output_channel %msg
  25.  
  26.   halt
  27. }
  28.  
  29. alias start_debug {
  30.   if ($debug) || (!$output_network) && (!$output_channel) || (!$from_network) || (!$from_channel) { return }
  31.   debug -ni @debuging $!debug_output
  32. }
  33.  
  34. alias stop_debug {
  35.   if (!$debug) { return }
  36.   debug -c off @debuging
  37. }
  38.  
  39. alias -l find_cid {
  40.   var %t = $scon(0)
  41.  
  42.   if (!$1) || (!%t) { return 0 }
  43.  
  44.   while (%t) {
  45.     var %network = $scon(%t).network
  46.     var %cid = $scon(%t).cid
  47.     if ($1 == %network) { return %cid }
  48.     dec %t
  49.   }
  50.  
  51.   return 0
  52. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement