| View previous topic :: View next topic |
| Author |
Message |
quantum0726 Voice
Joined: 03 Mar 2006 Posts: 9
|
Posted: Thu Mar 09, 2006 4:04 pm Post subject: binding commands without a ! or @ |
|
|
Hi, I am writing a help script for my eggdrop. I want a user to be able to ask for help and the eggdrop respond with some information about itself. I have done this easily using a binding for '!help'. Now I would like to add a binding for just 'help', without any characters in front of it. If I just add the lines:
set help(pub2) "help"
bind pub "$help(flag)" "$help(pub2)" help:pub
to the script, the bot will respond to the user typing 'help', but will also respond to the user typing 'help those who help themselves' or any other sentence starting with 'help' for that matter. Is there any way to limit the binding to only respond to 'help' and not to 'help*'? |
|
| Back to top |
|
 |
dusk Halfop

Joined: 06 Mar 2005 Posts: 91 Location: Belgium
|
Posted: Thu Mar 09, 2006 4:33 pm Post subject: |
|
|
Just let the bot give the info line when $arg doesn't exist.
ex : | Code: | if {$arg == ""} {
putserv "NOTICE $nick : your info line
return 0
} |
GRTZ
Last edited by dusk on Thu Mar 09, 2006 7:48 pm; edited 1 time in total |
|
| Back to top |
|
 |
quantum0726 Voice
Joined: 03 Mar 2006 Posts: 9
|
Posted: Thu Mar 09, 2006 7:39 pm Post subject: |
|
|
In my case I actually wanted to send the info line if $arg == "" since I don't want 'help*' to trigger it. Using that it works great.
Thanks! |
|
| Back to top |
|
 |
|