Fixed a 100AP conversion issue for morale and suppression fire.

Fixed a CTD caused by trying to "pickup" an item from sector inventory while simultaneously looking at that items description box.
Upgraded an INT8 to INT16 in training functions to try and catch a problem with INI values being set too high.

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@2419 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
ChrisL
2008-11-15 00:12:34 +00:00
parent ac6de87d47
commit 944dacd8a4
4 changed files with 14 additions and 7 deletions
@@ -826,6 +826,7 @@ void MapInvenPoolSlots(MOUSE_REGION * pRegion, INT32 iReason )
INT16 sDistanceFromObject = 0;
SOLDIERTYPE *pSoldier = NULL;
CHAR16 sString[ 128 ];
extern OBJECTTYPE *gpItemDescObject;
iCounter = MSYS_GetRegionUserData( pRegion, 0 );
@@ -887,6 +888,9 @@ void MapInvenPoolSlots(MOUSE_REGION * pRegion, INT32 iReason )
// Return if empty
if ( pInventoryPoolList[ ( iCurrentInventoryPoolPage * MAP_INVENTORY_POOL_SLOT_COUNT ) + iCounter ].object.exists() == false )
return;
// CHRISL: Also return if the item we've clicked on is currently displayed in the item description box
if(InItemDescriptionBox( ) && gpItemDescObject == &pInventoryPoolList[ ( iCurrentInventoryPoolPage * MAP_INVENTORY_POOL_SLOT_COUNT ) + iCounter ].object)
return;
}