mirror of
https://github.com/1dot13/source.git
synced 2026-07-29 13:52:17 +02:00
BUGFIX 514 - A vector error in the size of the world inventory was causing a mouse button to be deleted twice resulting in an assertion error.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@4485 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -1020,7 +1020,7 @@ void BeginSellAllCallBack( UINT8 bExitValue )
|
||||
{
|
||||
return;
|
||||
}
|
||||
for(UINT32 wItem = 0; wItem < guiNumWorldItems; wItem++) //WS TODO: is "for(UINT32 wItem = 0; wItem < pInventoryPoolList.size(); wItem++)" better? It resolved a bug in the old SVN, but things have changed now. (It was likely only fighting symptons anyway)
|
||||
for(UINT32 wItem = 0; wItem < pInventoryPoolList.size(); wItem++) //CHRISL: It's safer to use pInventoryPoolList.size() versus guiNumWorldItems as it avoids any possibility of a vector size error
|
||||
{
|
||||
if(pInventoryPoolList[wItem].object.exists() == true && (pInventoryPoolList[wItem].usFlags & WORLD_ITEM_REACHABLE))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user