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.

Autovoice plus manual +v -v

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
l
lighten
Voice
Posts: 1
Joined: Fri Jan 08, 2010 4:47 pm

Autovoice plus manual +v -v

Post by lighten »

I am currently using lol.tcl, and am trying to find a way to have the eggie autovoice, and allow the chanops to voice, devoice... and have the bot remember which users were devoiced so they can't just cycle and be +v again..

When I set +autovoice and +v -v, the manual part stopped the autovoice from working. I set a generic user at *!*@* with mode +g so that all would be voiced, but now what is happening is that -v folks can cycle and get voice again.

The eggie that used to do this correctly disappeared along with the script.. so we are back at the beginning :)

Thanks,

Lighten

(eggie is on efnet)
User avatar
TCL_no_TK
Owner
Posts: 509
Joined: Fri Aug 25, 2006 7:05 pm
Location: England, Yorkshire

Post by TCL_no_TK »

This should probably be scripting help or request, none the less. I hope this script helps, it dose remove the person as well if they are re-voiced by an Operator and it dose ignore valid users (people in eggdrop's userfile)

Code: Select all

 proc join:autovoice {nick host hand chan} {
  global devoice
   if {(![info exists devoice([maskhost $host])])&&(![validuser $hand])} {
    pushmode $chan +v $nick
   }
 }

 proc mode:devoice {nick host hand chan mode {target ""}} {
  global devoice botnick
   if {$target == ""} {set target "$botnick"}
    if {(![isbotnick $target])&&([isop $nick $chan])&&(![validuser [hand2nick $target]])} {
     set devoice([maskhost [getchanhost $target $chan]]) "1"
    }
 }

 proc mode:voice {nick host hand chan mode {target ""}} {
  global devoice botnick
   if {$target == ""} {set target "$botnick"}
    if {(![isbotnick $target])&&([isop $nick $chan])&&(![validuser [hand2nick $target]])&&([info exists devoice([maskhost [getchanhost $target $chan]])])} {
     array unset devoice [maskhost [getchanhost $target $chan]]
    }
 }

 bind join -|- "*%*" join:autovoice
 bind mode -|- "*-v*" mode:devoice
 bind mode -|- "*+v*" mode:voice

 putlog "loaded devoice.tcl version 1.0 by TCL_no_TK"
 return
Post Reply