I am writing a TCL script for my WoW guild channel that would enable users to add their WoW characters to a database. I have this as script to add characters:
Code: Select all
proc cu_addchar {nick host handle chan text} {
set charname [lindex $text 0]
set race [lindex $text 1]
set class [lindex $text 2]
set level [lindex $text 3]
putmsg $nick "Adding \002$charname\002 (Level $level $race $class) to the database."
set wowdb [open wowchars.db a+]
puts $wowdb $charname $race $class $level
close $wowdb
putmsg $cuchan "$nick has added a new character, $charname (Level $level $race $class) to the database."
}
Code: Select all
[02:16] Tcl error [cu_addchar]: wrong # args: should be "cu_addchar nick host handle chan text"
Code: Select all
proc cu_addchar {nick host handle chan text} {