|
![]() |
#1 |
Adept
Join Date: Jul 2007
Location: St George Utah, USA
Posts: 244
![]() |
borg out of sync sometimes due to lag in update on p_ptr->inventory[]
I was reviewing some odd borg behavior that crept in during the change to Angband 320. One error seems to be the borg selling at item at the house, then immediately trying to sell the exact same item to a shop; as if he still had it in the inventory. Once he gets to the shop, he sells an item in the old items inventory slot. So the inventory is not being updated after he drops the item in the house.
Same thing happens with ring swapping. During one round he will remove both rings, scan the inventory and re-wear the rings in the proper order (wearing the ring which had been on the left hand first, then wearing the ring which had been on the right hand). I have stepped through the code and found that the borg is correctly scanning the &p_ptr->inventory[], but the p_ptr->inventory is not being immediately updated after the borg's keypresses. So the borg is essentially scanning the old inventory and equipment state instead of the state following the keypresses. Vanilla 309 and previous versions immediately updated the p_ptr->inventory[] following any borg keypresses. Does anyone know if the update is being delayed? Maybe waiting for an event handler change or something? And if so, how do I fix it? |
![]() |
![]() |
![]() |
#2 | |
Veteran
Join Date: Apr 2007
Posts: 1,951
Donated: $40
![]() |
Quote:
Code:
process_command(CMD_STORE, TRUE); Is that helpful at all?
__________________
takkaria whispers something about options. -more- |
|
![]() |
![]() |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
p_ptr->class vs. p_ptr->pclass | APWhite | Development | 5 | August 17, 2011 16:32 |
Ready for borg update? | APWhite | Development | 8 | April 21, 2009 19:22 |
Borg update | APWhite | Vanilla | 75 | April 11, 2009 12:14 |
309 Borg Update | APWhite | Vanilla | 1 | October 11, 2007 09:29 |
Borg 3.0.9 Progress Update | APWhite | Vanilla | 3 | August 10, 2007 02:15 |