BeBot - An Anarchy Online and Age Of Conan chat automaton
Archive => Anarchy Online Archive => BeBot 0.4 support => Topic started by: Hyde on August 23, 2007, 06:19:51 pm
-
I'm wondering if this can be done via Flex?
I have 2 orgbots, 1 for my main org and 1 for our sister org.
Ranks in the sister org are a bit of a mess because we let people have SC to run their own AI raids.
I'd like to set up the sister org bot to use the ranks of our main org to determine admin levels (in combination with alts, which are shared between the 2 bots).
It already works for -me- because I'm the owner of both bots and have alts set. But I'd like Generals in the main org to get the same permissions in the 2nd bot, too.
-
It can be done using the flexible security, yes.
- Create a security group and give it the rights you wish (or use one of the pre-defined leader, admin or superadmin groups).
- Create a flexible security extension to this group by calling the !flexible command and creating an AND-combined group via the link in the GUI.
- Now add an org requirement to that group (I'm using generals as groupname in the following lines, replace that as needed): !flexible add generals org = yourname - the command gets the org-id it needs from the whois info of yourname.
- Now add a requirement on the org rank 1 (= general): !flexible add generals rank_id = 1
That should be all, now try !security whois somegeneral to test it.
-
Thanks :)
Documenting the following in case someone else wants to do similar
NOTE: I tried the group name "ap-generals". That ended up not working. The "addgroup" command worked, but the "flexible" command silently failed when I clicked the AND. Turns out the "-" in there is bad. Probably a bug in flexible.
I created "apgenerals" and the AND worked. However I had to modify your command to have the keyword "condition".
So the steps end up being:
* !addgroup {groupname}
* !flexible
* (click "AND" for the new group)
* !flexible condition add {groupname} org = {myname}
* !flexible condition add {groupname} rank_id = 1
(for general, 0 for president, etc)
* !security levels
* (click the security level I want for this group)
-
Ah yes, sorry. Forgot the condition part.
-
You should grab the SVN versions of core/Alts.php too to be save, otherwise alts changes may not be noticed by connected bots (even with shared alts table).
0.4 version (http://svn.shadow-realm.org/index.py/BeBot/branches/0.4/core/Alts.php?view=co), save as .php into core/ directory
0.5 version (http://svn.shadow-realm.org/index.py/BeBot/trunk/core/Alts.php?view=co), save as .php into core/ directory