Hey. I'm trying to make it bind to a certain command. But when someone enters the text, it doesn't bind it.
bind pub - !info show:info
proc show:info { nick chan hand } {
putserv "PRIVMSG $chan :MysticBots is a MysticNetwork service that provides real EggDrop bots for your channel. $nick, if you have a channel, you can get a bot for yourself."
return 0
}
If you take a look in your log/or stay on the partyline with the right .console settings, you'll notice a error message appearing as the proc is triggered.
The bind will cause the proc to be called with a fixed number of arguments (depending on what kind of bind you're using...check tcl-commands.doc for details). Unless your proc is designed to accept that number of argumens it won't work.
Why are you posting again about the same error when I already told you how to solve it? If you have a problem understanding parts of my reply, please tell me, and I'll try to explain in a bit more detail.
That you can't just leave out the arguments you don't need from the proc. A proc called by a msg bind will recieve 4 arguments no matter what and must be able to handle these some how. Either by having four variable names or using the special variable name 'args' (that can handle any number of arguments (even none)).
Check the 'binds' section of doc/tcl-commands.doc to find out what these arguments are and in what order they are passed along or else you might end up mixing things up. Your previous proc were only capable of handling ONE argument (no more, no less) and thus, when the bind called it with four arguments it had to go wrong