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.

BadServ.tcl modification

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
User avatar
erotism
Voice
Posts: 13
Joined: Tue Aug 10, 2010 7:39 am
Location: Sofia, Bulgaria
Contact:

BadServ.tcl modification

Post by erotism »

Hi, all

i want to modify badserv.tcl when user use !voice, !v or + in channel
bot whois user, and if user in a $server get voice..

Here tcl:

Code: Select all

##############################
# All Right Reserved by Paco #
##############################
# Vuvedete serverite, koito ako nqkoj potrebitel, koito e wlqzal na tqh da mu bude daden op ili voice!

set opvoiceserv {
  {irc.server1.com}
  {irc.server2.com}
}

# Napishete kanala, za koito da raboti scripta.
set chan "#Channel"


## Script ##

bind pub -|- + pun:server
bind pub -|- !v pun:server
bind pub -|- !voice pun:server

###################
#Start voice check#
###################
proc pun:server {nick uhost hand chan} {
  global botnick

  if {[string tolower $botnick] == [string tolower $nick]} {
    return
  }

  putquick "whois $nick"
}


# Start Voice check #
bind raw - 312 server:whois

proc server:whois {from key bns} {
  global chan opvoiceserv
  set nick [lindex [split $bns " "] 1]
  set server [string tolower [lindex [split $bns " "] 2]]
  foreach bserv $opvoiceserv {
	if {[string tolower $bserv] == $server} {
	  pushmode $chan +v $nick
	  return
    }
  }
}

putlog "Loaded Op/Voice server check tcl writen by Paco (irc.techno-link.net)"
but.. when type !voice on channel ->
Tcl error [pun:server]: wrong # args: should be "pun:server nick uhost hand chan"

Where is my error? :(
S
SmasHinG
Voice
Posts: 29
Joined: Mon Aug 29, 2011 2:58 am

Post by SmasHinG »

proc pun:server {nick uhost hand chan} {



proc pun:server {nick uhost hand chan text} {
SmasHinG®
Post Reply