BeBot - An Anarchy Online and Age Of Conan chat automaton
Archive => Anarchy Online Archive => BeBot 0.4 support => Topic started by: Chakki on August 15, 2007, 05:43:22 am
-
Have a issue with just some players and autoinvite..
And for some reason i can not figure this one out.. out of all the guests we have on our list this affects perhaps 10-15 of them, the rest of them have no problems.
What happends is that whenever they log on even tho they are added on guest list
the bot flags them like this: [2007-08-10 02:20:28] [BUDDY] [LOG] ***** logged [on] (ANONYMOUS)
This happends even tho they are added to guestlist, and their autoinvite is set to on.
If i remove them and re-add them it will work untill they log off and comes back on.
Is anyone else have this problem? and is there a easy solution to this?
Any help would be appreciated :)
Chakki
-
you know now that you say something and after checking.. all 10 bots I run I am having the same problem.. the autoinvite isnt working anymore..even if it is turned on.
-
look inside Settings member ;) there is a Option for the Guest Autoinvite
Notify_level: 1
Description: Are only members (2) or guests too (1) automatically put on notify if Mark_notify is true?
Change to: [ 1 | 2 ]
you need to add again the Guest after.
-
All these were set like that from the get go, but gonna try and remove all guests and redo the entire notify and re-add them to see if this solves the issue
Chakki
-
Well in my case it was working, and I honestly dont remember when it quite working, but I will look into it this weekend and see if I can figure anything out..
-
Yeah same here, it was working, then it just started doing this with like i said some ppl, and these ppl are affected regardless of removing and re-adding them.
Just cant quite wrap my head around this one...
Chakki
-
ok lastnight I droped all my user tables and re-did them.. and the autoinvite seems to be working again.. not sure what the problem was but it dont seem to be affecting me now..
-
i having a problem that might be related
i have a 2nd org bot but to run 1 module thats heavy use
some times i try restart it and it says "i only listen to member of this bot"
i am set to owner
i manualy restart it and it works fine
the member list is empty as it should be
-
ok lastnight I droped all my user tables and re-did them.. and the autoinvite seems to be working again.. not sure what the problem was but it dont seem to be affecting me now..
My initial testing so far since last night indicate that those that have problems are the users that are added to the guest list with a non-capital first letter in their name.
If their name is in the list with a capital first letter they got no issues, if they dont have it they get anonymous status for some reason. Could some of you code gurus take a peek and see if this is the issue? :) The bot is running on a linux system as well, FreeBSD i belive it is but not 100% sure since its not actually my server. And if this is the case, is there a easy fix on this so it wont matter with capital letter or not?
Chakki
-
Well all Guests/members get added as format Name regardless of how u do it ingame , i checked surrent release+svn and they seem fine , maybe those guests were add with older version? and thats were the problem game from
-
I removed all, just havent been able to drop the table yet, still need to try and do that as soon as i can get access to the mysql db >) But tried to remove every single guest and re-ad them, yet the problem is still there. Gonna try and get the table dropped then redo it again and see the outcome there..
Chakki
-
This last update has really messed up the bots user database. Not sure why, but a few tables you may want to drop also is _online, online, _logon. found corruptions in those also. the normal <bot>_logon was fine.. but <bot>_online and _online and _logon where all corrupted or I should say had alot of strange data in it and droping those helped also for me.
-
the default table for online is "online" as online table is shared by deafult, altho im not sure if this prob in fixed in 0.4.1 , it is in SVN trunk
-
maybe related, maybe not ... but I can't seem to get my relay bot to autoinvite my org bots.
System is like so:
Relay bot = Aprelay
Org Bot 1 = Aporg
Org Bot 2 = Goaorg
If I manually invite Aporg and Goaorg to Aprelay, then the relay is set up properly (using privgroup).
However, I've turned on !notify. I've set "autoinvite on" for "both" in !settings Members. I've made both bots members of the Relay bot. I've even logged the bots individually after removing them from the "other bots" in the conf files to "/tell Aprelay !autoinvite on".
Am I getting bit by this as a bug, or am I just missing some step?
-
Have you checked the SQL DB and seen if autoinvite is actually set to 1?
I've had problems occassionally with getting that set.
Also, make sure that the !settings are done right, there's one in there for autoinviting.
-
looking at the DB for Relaybot:
1) relaybot_settings
Members Autoinvite = TRUE
Members AutoinviteGroup = BOTH
2) relaybot_users
Aporg auto_invite = 1 ; user_level = 2
Goaorg auto_invite = 1 ; user_level = 2
Should something else need to be set to make Relaybot autoinvite Aporg and Goaorg?
If no, then I'll do a final confirmation (restarting Aporg and Goaorg again) just to be sure, but I don't believe I changed anything since the last restart last night and I had to do manual invites again last night.
-
Actually, thinking back I remember that even though I got the autoinvites working, if the bots got dropped they didn't always get autoinvited back (sometimes the org bot came online before the relay bot, sometimes the org bot would never recieve the invite for some reason, etc).
Try this little module. It's a kludge, but it works for me.
<?php
$spam_autoinvites = new spam_autoinvites($bot);
$cron["5min"][] = &$spam_autoinvites;
class spam_autoinvites
{
var $bot;
function spam_autoinvites (&$bot)
{
$this -> bot = &$bot;
}
/*
This gets called on cron
*/
function cron()
{
$members = $this -> bot -> db -> select("SELECT nickname FROM #___users WHERE auto_invite = 1");
if(!empty($members))
foreach ($members as $member)
{
$this -> bot -> aoc -> privategroup_invite($member[0]);
echo "Inviting " . $member[0] . " to the bot\n";
}
}
}
?>
-
Installed that script and it worked great ... except ... when I fixed the XML Roster it started inviting every person in the org :) (yeah, I know, the relay bot doesn't even need to be an org member, but I hadn't considered that earlier and I already had joined the bot ... in fact was kind of useful, as it FORCED me to disable alot of commands).
That become a REAL problem when it auto-invited everyone again 5 minutes later.
So I added a group called "RelayedBots", added the 2 bots to that group, and made some changes to the script so that it only spaminvites people in this group, and only if they're not already in the private group
Commands:
* !addgroup RelayedBots bots that we autoinvite
* !adduser {botname} RelayedBots
NOTE: The group doesn't need any extra permissions
Modifications to Ebag's Spaminvite.php:
* Invite only people in the RelayedBots group (could be made a setting probably)
* Don't invite people who are already in the guest channel
<?php
/*
Modname: Spaminvites.php
Purpose: Autoinvites relayed bots to the Relaybot.
Details: See http://bebot.link/index.php/topic,947.0.html
Authors: Ebagmp@RK2 & Doctorhyde@RK2
*/
$spam_autoinvites = new spam_autoinvites($bot);
$cron["5min"][] = &$spam_autoinvites;
class spam_autoinvites
{
var $bot;
function spam_autoinvites (&$bot) { $this -> bot = &$bot; }
// This gets called on cron
function cron() {
// look up the gid of the security_group "relayedbots"
$security_groups_gid = $this -> bot -> db -> select("SELECT gid,name FROM #___security_groups WHERE name = \"RelayedBots\"");
if($security_groups_gid[0][0]) {
$relayedbots_gid = $security_groups_gid[0][0];
$thisbotname = $this -> bot -> botname;
$invitelist = $this -> bot -> db -> select("SELECT ol.nickname,ol.status_pg,ol.botname,sm.gid,sm.name FROM online AS ol LEFT JOIN #___security_members AS sm ON ol.nickname = sm.name WHERE sm.gid = $relayedbots_gid AND ol.status_pg = 0 AND ol.botname = \"$thisbotname\"");
if ($invitelist[0]) {
foreach ($invitelist as $inviteme) {
$this -> bot -> aoc -> privategroup_invite($inviteme[0]);
echo "... NOTICE: Inviting " . $inviteme[0] . " to the bot\n";
}
}
}
}
}
?>
-
(on the off chance someone downloaded the module above before I posted this note, fixed a bug ... added an if() so the invite would only happen if the inviteme array existed ... redownload if needed)
PS. If this gets incorporated into a Module it would seem to fit best in Relay_GUILD.php ... all of Relay_GUILD's settings currently seem to be focused on the client relays. Using this as the relay host setting would be useful. It would create "relayedbots" group and allow you to list all allowed clients.
-
Added to trunk.
(Note the name change from Relay_Guild.php to Relay.php)