2.0.7 | Bot Standing upon entering portal
Moderators: Moderators, Developers
-
- Plain Yogurt
- Posts: 53
- Joined: 25 Mar 2009, 22:20
- Noob?: No
- Location: in front of my computer
2.0.7 | Bot Standing upon entering portal
hi,
i apologize because i dont know how to read or write in perl. this "bug" has been seen since 2.0.6. the problem is that the bot just stands upon entering a portal to buy or sell (or for storage if it doesnt have wing).
im not sure if this helps but this is my logic:
current flow:
bot initiates auto buy/sell>bot calculates npc location>moves to NPC location>bot buys/sells> END
(with this the bot will not respond if it enters a portal)
suggested flow:
bot initiates auto buy/sell >bot calculates npc location>moves to NPC location>>
>>IF: bot enters portal>load map>bot initiates auto buy/sell (o initiates last command)>bot calculates npc location>moves to NPC location>>
>>bot buys/sells> END
(with this, on every map, the bot will recall its last command on queue. thus makes the bot move again)
** the current flow is just based on my own observation on how the bot runs. i wasn't able to look deeply into the OK codes because i do not know how to read perl syntax**
this is just a suggestion for our developers to check.
btw, im using 2.0.7
Thanks!
i apologize because i dont know how to read or write in perl. this "bug" has been seen since 2.0.6. the problem is that the bot just stands upon entering a portal to buy or sell (or for storage if it doesnt have wing).
im not sure if this helps but this is my logic:
current flow:
bot initiates auto buy/sell>bot calculates npc location>moves to NPC location>bot buys/sells> END
(with this the bot will not respond if it enters a portal)
suggested flow:
bot initiates auto buy/sell >bot calculates npc location>moves to NPC location>>
>>IF: bot enters portal>load map>bot initiates auto buy/sell (o initiates last command)>bot calculates npc location>moves to NPC location>>
>>bot buys/sells> END
(with this, on every map, the bot will recall its last command on queue. thus makes the bot move again)
** the current flow is just based on my own observation on how the bot runs. i wasn't able to look deeply into the OK codes because i do not know how to read perl syntax**
this is just a suggestion for our developers to check.
btw, im using 2.0.7
Thanks!
Re: 2.0.7 | Bot Standing upon entering portal
btdt.
tip: if there is a need to enter a portal to buy/sell stuff (i.e. alberta town), you should utilize the 'standpoint' option rather than 'distance'.
tip: if there is a need to enter a portal to buy/sell stuff (i.e. alberta town), you should utilize the 'standpoint' option rather than 'distance'.
-
- Plain Yogurt
- Posts: 53
- Joined: 25 Mar 2009, 22:20
- Noob?: No
- Location: in front of my computer
Re: 2.0.7 | Bot Standing upon entering portal
yup but that's still not a fix. that can solve some problems but it does not fix the issue... i hope u get what i mean
Re: 2.0.7 | Bot Standing upon entering portal
^yef... i know what you mean
Re: 2.0.7 | Bot Standing upon entering portal
I'm not sure if I understood well, but I was getting the same bug but using teleport.
Like, we are on lockMap and teleporting to saveMap to do autobuy, but after teleporting, it "forgets" that was autobuying and calculate route to lockMap again, causing a loop. I found this reference in the TalkToLockMap plugin from Thaize.
Like, we are on lockMap and teleporting to saveMap to do autobuy, but after teleporting, it "forgets" that was autobuying and calculate route to lockMap again, causing a loop. I found this reference in the TalkToLockMap plugin from Thaize.
Code: Select all
## This is a fucking hack, for some reason when autoBuy is called
## @ai_seq is getting cleared so the bot will automatically trigger
## processLockMap.. causing an infinite loop until the timing of
## the autobuy check falls during the idle period after warp.
sub on_teleport_send{
if (AI::action eq "buyAuto" && @_[1]->{level} eq 2){
message "buyAuto is queued and we are teleporting, setting the TalkToLockMap variable.\n";
$buyAuto = 1;
} else {
## Shouldn't be needed; will remove after sufficient testing.
$buyAuto = 0;
}
}
Quit.
-
- Developers
- Posts: 1798
- Joined: 05 Dec 2008, 05:42
- Noob?: Yes
Re: 2.0.7 | Bot Standing upon entering portal
teleportAuto_allPlayers, teleportAuto_hp/sp, teleport from monster by mon_control, teleportAuto_idle, teleportAuto_portal
- as one of these triggers, $ai_v{temp}{clear_aiQueue} is set.
When $ai_v{temp}{clear_aiQueue} is set, map_change packet handler clears AI, but doesn't reset this flag. So every map change will clear AI.
Currently it's being reset only with autoRestart, autoBreakTime.
- as one of these triggers, $ai_v{temp}{clear_aiQueue} is set.
When $ai_v{temp}{clear_aiQueue} is set, map_change packet handler clears AI, but doesn't reset this flag. So every map change will clear AI.
Currently it's being reset only with autoRestart, autoBreakTime.
Re: 2.0.7 | Bot Standing upon entering portal
This is not Really good Idea, to clean Up whole AI sequence.EternalHarvest wrote:So every map change will clear AI.
Some of the Entries must stay like: MapRoute (from map to map), AutoBuy, AutoSell. ans such things.
-
- Developers
- Posts: 1798
- Joined: 05 Dec 2008, 05:42
- Noob?: Yes
Re: 2.0.7 | Bot Standing upon entering portal
I was wrong, initMapChangeVars erases ai_v{temp}.
-
- Super Moderators
- Posts: 801
- Joined: 06 May 2008, 12:47
- Noob?: No
Re: 2.0.7 | Bot Standing upon entering portal
Not sure if it is related but i've experienced the bot standing BEFORE a portal, turned out the portal in portals.txt had a slightly wrong location.Bot Standing upon entering portal
If that is not the case, read on...
Ok, to be honest i (and others) don't have a clue what is going on, so we'll need a lot more information...
First of all, describe every step in great detail of the process starting from lockmap to where the bot gets stuck.
these commands are useful to see what the AI is doing, use them
Code: Select all
ai ai_v
ai print
aiv
EDIT:
i've also noticed the bot standing for a while after having entered a portal, is this what you mean?
One ST0 to rule them all? One PE viewer to find them!
One ST_kRO to bring them all and in the darkness bind them...
Mount Doom awaits us, fellowship of OpenKore!
One ST_kRO to bring them all and in the darkness bind them...
Mount Doom awaits us, fellowship of OpenKore!