mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
-added code for enemies to carry money items / wallets w/actual deposit-able cash
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@173 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -1786,7 +1786,11 @@ void ChooseMiscGearForSoldierCreateStruct( SOLDIERCREATE_STRUCT *pp, INT8 bMiscC
|
||||
usItem = PickARandomItem (MISCITEMS , bMiscClass, FALSE);
|
||||
if ( usItem > 0 )
|
||||
{
|
||||
CreateItem( usItem, (INT8)(80 + Random( 21 )), &Object );
|
||||
int bStatus = 80 + Random( 21 );
|
||||
if ( Item[usItem].usItemClass == IC_MONEY )
|
||||
bStatus = 1 + Random( 20 );
|
||||
|
||||
CreateItem( usItem, (INT8)(bStatus), &Object );
|
||||
Object.fFlags |= OBJECT_UNDROPPABLE;
|
||||
PlaceObjectInSoldierCreateStruct( pp, &Object );
|
||||
}
|
||||
|
||||
+1
-1
@@ -4699,7 +4699,7 @@ BOOLEAN CreateItem( UINT16 usItem, INT8 bStatus, OBJECTTYPE * pObj )
|
||||
{
|
||||
pObj->usItem = usItem;
|
||||
pObj->ubNumberOfObjects = 1;
|
||||
if (usItem == MONEY)
|
||||
if (usItem == MONEY || Item[usItem].usItemClass == IC_MONEY )
|
||||
{
|
||||
// special case... always set status to 100 when creating
|
||||
// and use status value to determine amount!
|
||||
|
||||
Reference in New Issue
Block a user