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.

need a little help with voicebitch.tcl

Help for those learning Tcl or writing their own scripts.
Post Reply
M
MMDollar
Voice
Posts: 8
Joined: Sat Mar 04, 2006 8:37 pm
Location: Bulgaria/Bourgas
Contact:

need a little help with voicebitch.tcl

Post by MMDollar »

I don't know how to make if a bot voices a user the other ones to devoice him or somehow to make if someone wan't to use the command voice from the bot he has to have flag H
here is my code :

Code: Select all

bind mode - * mode:bitchie_staff
proc mode:bitchie_staff {nick uhost handle channel mchange theone} {
 global channels botnick
  if {$mchange == "+v" || $mchange == "+v-o"} {
   if {[matchattr [nick2hand $theone] b] || [matchattr $handle H] || [matchattr [nick2hand $theone] H]} { return 0 }
   if {[matchattr $handle b]} { 
    putserv "MODE $channel -v $theone" 
    return 0
   }
   putserv "MODE $channel -ov $nick $theone"
   putserv "kick $channel $nick :Нямате право да давате voice (глас).Забранена е тази опция в канала!"
  }
}
[/code]
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Re: need a little help with voicebitch.tcl

Post by Sir_Fz »

MMDollar wrote:I don't know how to make if a bot voices a user the other ones to devoice him or somehow to make if someone wan't to use the command voice from the bot he has to have flag H
I did not get what you're trying to explain but I can tell you one thing about the mode bind. The mode bind catches one mode change at a time which means +v-o will never be equal to $mchange. To catch +v you can use this:

Code: Select all

bind mode - "* +v" proc
Post Reply