This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

How to stop msg output?

Old posts that have not been replied to for several years.
Locked
[
[EW]MaxxCrash

How to stop msg output?

Post by [EW]MaxxCrash »

Hi there,

I sometimes find my bot spamming the channel with some scripts e.g. Dictionary.tcl by Wcc. Is there any way to make the eggdrop halt all output to a certain channel? In other words, how can I purge / edit the message queue which is generated by putserv?

I hope you can help me. Thanks very much in advance.
User avatar
user
 
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Re: How to stop msg output?

Post by user »

You can't edit the queue. The only way to stop it is to empty the entire queue using 'clearqueue'.
Have you ever read "The Manual"?
[
[EW]MaxxCrash

Post by [EW]MaxxCrash »

Why didn't I find that :D

Thanks for the quick reply
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

Somthing like this

Code: Select all

# list channels that should not be sent to - keep lower case
set null_chan {
 #chan1
}

if {![info exits _putserv]} {
  set _putserv 0
  rename putserv _putserv
  proc putserv {arg {option {}}} {
    if {[lsearch $::null_chan [lindex [split $arg] 1]] > -1} {
      return
    }
    if {$option != {}} {
      putserv $arg $option
    } else {
      putserv $arg
    }
  }
}
That only works with putserv. Puthelp and others still need adjustment.
User avatar
user
 
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Post by user »

ppslim wrote:

Code: Select all

proc putserv {} {putserv}
Notice any problems? :P
Another thing about the code; why use that variable when you can do 'info commands _putserv'? :)
Have you ever read "The Manual"?
p
ppslim
Revered One
Posts: 3914
Joined: Sun Sep 23, 2001 8:00 pm
Location: Liverpool, England

Post by ppslim »

Point taken, I had some eyes poping over my sholder ever few seconds. I wouldn't worry, that code wouldn't do anything more nasty than send the code into a loop.

The other program I am working on of my own however, managed to delete its own source code, remove the CVS access files and a rather long winded documention report.

I have now lost my password for the CVS server on the day the person that maintains our CVS system has gone on holiday. Oh well.

Code: Select all

set null_chan { 
 #chan1 
} 

if {[info commands _putserv] == ""} { 
  rename putserv _putserv 
  proc putserv {arg {option {}}} { 
    if {[lsearch $::null_chan [lindex [split $arg] 1]] > -1} { 
      return 
    } 
    if {$option != {}} { 
      _putserv $arg $option 
    } else { 
      _putserv $arg 
    } 
  } 
}
Locked