mirror of
https://github.com/1dot13/source.git
synced 2026-07-29 13:52:17 +02:00
LocateSoldier() & HandleMercLeavingEquipmentInDrassen() & HandleMercLeavingEquipmentInOmerta()
This commit is contained in:
@@ -1625,7 +1625,7 @@ void HandleLeavingOfEquipmentInCurrentSector( SoldierID uiMercId )
|
||||
|
||||
|
||||
|
||||
void HandleMercLeavingEquipmentInOmerta( UINT32 uiMercId )
|
||||
void HandleMercLeavingEquipmentInOmerta( SoldierID uiMercId )
|
||||
{
|
||||
INT32 iSlotIndex = 0;
|
||||
|
||||
@@ -1643,7 +1643,7 @@ void HandleMercLeavingEquipmentInOmerta( UINT32 uiMercId )
|
||||
}
|
||||
|
||||
|
||||
void HandleMercLeavingEquipmentInDrassen( UINT32 uiMercId )
|
||||
void HandleMercLeavingEquipmentInDrassen( SoldierID uiMercId )
|
||||
{
|
||||
INT32 iSlotIndex = 0;
|
||||
|
||||
@@ -1856,7 +1856,7 @@ INT32 FindFreeSlotInLeaveList( void )
|
||||
}
|
||||
|
||||
|
||||
INT32 SetUpDropItemListForMerc( UINT32 uiMercId )
|
||||
INT32 SetUpDropItemListForMerc( SoldierID uiMercId )
|
||||
{
|
||||
// will set up a drop list for this grunt, remove items from inventory, and profile
|
||||
INT32 iSlotIndex = -1;
|
||||
@@ -1867,27 +1867,27 @@ INT32 SetUpDropItemListForMerc( UINT32 uiMercId )
|
||||
return( -1 );
|
||||
}
|
||||
|
||||
UINT32 invsize = Menptr[ uiMercId ].inv.size();
|
||||
UINT32 invsize = uiMercId->inv.size();
|
||||
for( UINT32 iCounter = 0; iCounter < invsize; ++iCounter )
|
||||
{
|
||||
// slot found,
|
||||
// check if actual item
|
||||
if( Menptr[ uiMercId ].inv[ iCounter ].exists() == true )
|
||||
if( uiMercId->inv[ iCounter ].exists() == true )
|
||||
{
|
||||
// make a linked list of the items left behind, with the ptr to its head in this free slot
|
||||
AddItemToLeaveIndex( &( Menptr[ uiMercId ].inv[ iCounter ] ), iSlotIndex );
|
||||
AddItemToLeaveIndex( &( uiMercId->inv[ iCounter ] ), iSlotIndex );
|
||||
|
||||
// store owner's profile id for the items added to this leave slot index
|
||||
SetUpMercAboutToLeaveEquipment( Menptr[ uiMercId ].ubProfile, iSlotIndex );
|
||||
SetUpMercAboutToLeaveEquipment( uiMercId->ubProfile, iSlotIndex );
|
||||
}
|
||||
}
|
||||
|
||||
// ATE: Added this to drop keyring keys - the 2nd last paramter says to add it to a leave list...
|
||||
// the gridno, level and visiblity are ignored
|
||||
DropKeysInKeyRing( MercPtrs[ uiMercId ], NOWHERE, 0, 0, TRUE, iSlotIndex, FALSE );
|
||||
DropKeysInKeyRing( uiMercId, NOWHERE, 0, 0, TRUE, iSlotIndex, FALSE );
|
||||
|
||||
// zero out profiles
|
||||
gMercProfiles[ Menptr[ uiMercId ].ubProfile ].clearInventory();
|
||||
gMercProfiles[ uiMercId->ubProfile ].clearInventory();
|
||||
|
||||
return( iSlotIndex );
|
||||
}
|
||||
|
||||
@@ -516,8 +516,8 @@ void GetMoraleString( SOLDIERTYPE *pSoldier, STR16 sString );
|
||||
void HandleLeavingOfEquipmentInCurrentSector( SoldierID uiMercId );
|
||||
|
||||
// set up a linked list of items being dropped and post an event to later drop them
|
||||
void HandleMercLeavingEquipmentInDrassen( UINT32 uiMercId );
|
||||
void HandleMercLeavingEquipmentInOmerta( UINT32 uiMercId );
|
||||
void HandleMercLeavingEquipmentInDrassen( SoldierID uiMercId );
|
||||
void HandleMercLeavingEquipmentInOmerta( SoldierID uiMercId );
|
||||
|
||||
// actually drop the stored list of items
|
||||
void HandleEquipmentLeftInOmerta( UINT32 uiSlotIndex );
|
||||
@@ -537,7 +537,7 @@ void FreeLeaveListSlot( UINT32 uiSlotIndex );
|
||||
INT32 FindFreeSlotInLeaveList( void );
|
||||
|
||||
// set up drop list
|
||||
INT32 SetUpDropItemListForMerc( UINT32 uiMercId );
|
||||
INT32 SetUpDropItemListForMerc( SoldierID uiMercId );
|
||||
// store owner's profile id for the items added to this leave slot index
|
||||
void SetUpMercAboutToLeaveEquipment( UINT32 ubProfileId, UINT32 uiSlotIndex );
|
||||
|
||||
|
||||
@@ -3488,7 +3488,7 @@ BOOLEAN ResetAllAnimationCache( )
|
||||
|
||||
|
||||
|
||||
void LocateSoldier( UINT16 usID, BOOLEAN fSetLocator)
|
||||
void LocateSoldier( SoldierID usID, BOOLEAN fSetLocator)
|
||||
{
|
||||
SOLDIERTYPE *pSoldier;
|
||||
INT16 sNewCenterWorldX, sNewCenterWorldY;
|
||||
@@ -3501,7 +3501,7 @@ void LocateSoldier( UINT16 usID, BOOLEAN fSetLocator)
|
||||
if (!SoldierOnScreen(usID) || fSetLocator == 10 )
|
||||
{
|
||||
// Get pointer of soldier
|
||||
pSoldier = MercPtrs[ usID ];
|
||||
pSoldier = usID;
|
||||
|
||||
// Center on guy
|
||||
sNewCenterWorldX = (INT16)pSoldier->dXPos;
|
||||
|
||||
+1
-1
@@ -231,7 +231,7 @@ void SelectSoldier( UINT16 usSoldierID, BOOLEAN fAcknowledge, BOOLEAN fForceRese
|
||||
void RevealAllDroppedEnemyItems();
|
||||
|
||||
void LocateGridNo( INT32 sGridNo );
|
||||
void LocateSoldier( UINT16 usID, BOOLEAN fSetLocator);
|
||||
void LocateSoldier( SoldierID usID, BOOLEAN fSetLocator);
|
||||
|
||||
void BeginTeamTurn( UINT8 ubTeam );
|
||||
void SlideTo(INT32 sGridNo, UINT16 usSoldierID , UINT16 usReasonID, BOOLEAN fSetLocator) ;
|
||||
|
||||
Reference in New Issue
Block a user