BeBot - An Anarchy Online and Age Of Conan chat automaton

Archive => Anarchy Online Archive => BeBot 0.4 support => Topic started by: Snarfblatt on August 14, 2007, 06:09:09 pm

Title: Optional Command Prefix
Post by: Snarfblatt on August 14, 2007, 06:09:09 pm
I want to modify the AFK command to make the prefix optional. I have some lazy members in my org who can't be bothered to type "!afk" and would rather just type "afk".

In the afk module for 0.2.x I could just remove the "$this -> bot -> commpre" out of the "preg_match". But it doesn't seem to work the same way in 0.4. I'm assuming because the command prefix is "required" in some way for that code to be triggered.

Any suggestions?
Title: Re: Optional Command Prefix
Post by: Temar on August 14, 2007, 08:01:32 pm
1 way i can think of is adding the check under function gmsg which checks none command messages
Title: Re: Optional Command Prefix
Post by: Temar on August 14, 2007, 08:07:57 pm
http://bebot.link/index.php/topic,867.0.html

My Improved AFK module
Now has what you wanted :D
Title: Re: Optional Command Prefix
Post by: Snarfblatt on August 15, 2007, 04:37:52 am
Thanks a bunch.. makes sense what you did. I guess I should have thought of that.
SimplePortal 2.3.7 © 2008-2024, SimplePortal