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.

wrong args on proc

Help for those learning Tcl or writing their own scripts.
Post Reply
User avatar
ultralord
Master
Posts: 255
Joined: Mon Nov 06, 2006 6:52 pm

wrong args on proc

Post by ultralord »

Code: Select all

proc g_nexts { nick uhost handle channel } {
  global g_active g_clearqueue1 g_serverholder g_shutupchan g_q1 clr g_q2 g_q3 g_q4 g_q5 g_q6 g_q7 g_q8 g_pickupchan g_privategatherchannel
if { $g_active == 1 } {
putserv "PRIVMSG $g_privategatherchannel :14,1\[7«0 1.: $g_q1 2.: $g_q2 3.: $g_q3 4.: $g_q4 5.: $g_q5 6.: $g_q6 7.: $g_q7 8.: $g_q8 7»14]"
} else {
g_clearqueue1
}
}
g_clearqueue1 is other proc

when this proc g_nexts runs i saw in dcc chat

Code: Select all

wrong # args: should be "g_nexts nick uhost handle channel arg"
when i overwrite with that problem still exist etc..

anyone can help me?

thnks
User avatar
YooHoo
Owner
Posts: 939
Joined: Thu Feb 13, 2003 10:07 pm
Location: Redwood Coast

Post by YooHoo »

the error is telling you what it needs. The procedure g_nexts is expecting 5 arguments, not 4, as in

Code: Select all

proc g_nexts {nick host handle channel text} {
User avatar
ultralord
Master
Posts: 255
Joined: Mon Nov 06, 2006 6:52 pm

Post by ultralord »

now the error in dcc chat is :

> [02:46] wrong # args: should be "g_nexts nick host handle channel text"

:/ what i must put in arg?


thnx
User avatar
rosc2112
Revered One
Posts: 1454
Joined: Sun Feb 19, 2006 8:36 pm
Location: Northeast Pennsylvania

Post by rosc2112 »

Depends on the bind..How bout showing us? Or better yet, read the tcl-commands.doc that comes with eggdrop and learn the syntax for the bind yourself, it shouldn't be that hard to do.. Once you know how many parameters that particular bind needs, then you can fix your script.
User avatar
DragnLord
Owner
Posts: 711
Joined: Sat Jan 24, 2004 4:58 pm
Location: C'ville, Virginia, USA

Post by DragnLord »

'proc g_nexts' is not being passed enough arguments, post the entire script so you can actually get help with it
User avatar
ultralord
Master
Posts: 255
Joined: Mon Nov 06, 2006 6:52 pm

Post by ultralord »

Fixed ty :)
Post Reply