mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
Use SoldierID
This commit is contained in:
@@ -4310,12 +4310,12 @@ BOOLEAN LoadPlayerGroupList( HWFILE hFile, GROUP **pGroup )
|
||||
{
|
||||
PLAYERGROUP *pTemp=NULL;
|
||||
PLAYERGROUP *pHead=NULL;
|
||||
UINT32 uiNumberOfNodes=0;
|
||||
UINT32 uiProfileID=0;
|
||||
UINT32 uiNumBytesRead;
|
||||
UINT32 cnt=0;
|
||||
INT16 sTempID;
|
||||
GROUP *pTempGroup = *pGroup;
|
||||
UINT32 uiNumberOfNodes=0;
|
||||
UINT32 uiProfileID=0;
|
||||
UINT32 uiNumBytesRead;
|
||||
UINT32 cnt=0;
|
||||
SoldierID sTempID;
|
||||
GROUP *pTempGroup = *pGroup;
|
||||
|
||||
// pTemp = pGroup;
|
||||
|
||||
@@ -4350,10 +4350,10 @@ BOOLEAN LoadPlayerGroupList( HWFILE hFile, GROUP **pGroup )
|
||||
sTempID = GetSoldierIDFromMercID( pTemp->ubProfileID );
|
||||
|
||||
//Should never happen
|
||||
Assert( sTempID != -1 );
|
||||
pTemp->ubID = (UINT16) sTempID;
|
||||
Assert( sTempID != NOBODY );
|
||||
pTemp->ubID = sTempID;
|
||||
|
||||
pTemp->pSoldier = &Menptr[ pTemp->ubID ];
|
||||
pTemp->pSoldier = pTemp->ubID;
|
||||
|
||||
pTemp->next = NULL;
|
||||
|
||||
|
||||
@@ -52,10 +52,10 @@ typedef struct WAYPOINT
|
||||
|
||||
typedef struct PLAYERGROUP
|
||||
{
|
||||
UINT8 ubProfileID; //SAVE THIS VALUE ONLY. The others are temp (for quick access)
|
||||
UINT16 ubID; //index in the Menptr array
|
||||
UINT8 ubProfileID; //SAVE THIS VALUE ONLY. The others are temp (for quick access)
|
||||
SoldierID ubID; //index in the Menptr array
|
||||
SOLDIERTYPE *pSoldier; //direct access to the soldier pointer
|
||||
UINT8 bFlags; //flags referring to individual player soldiers
|
||||
UINT8 bFlags; //flags referring to individual player soldiers
|
||||
struct PLAYERGROUP *next; //next player in list
|
||||
}PLAYERGROUP;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user