Store the profile type in the profile structure and remove superfluous code

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@8620 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Flugente
2018-09-24 19:36:28 +00:00
parent 8ae2eacfcd
commit 494dbc6e69
41 changed files with 385 additions and 942 deletions
+2 -21
View File
@@ -1133,8 +1133,7 @@ BOOLEAN CopyVehiclePathToSoldier( SOLDIERTYPE *pSoldier )
return( FALSE );
}
}
// reset mvt group for the grunt
// ATE: NOT if we are the vehicle
if ( !( pSoldier->flags.uiStatusFlags & SOLDIER_VEHICLE ) )
@@ -1155,31 +1154,13 @@ BOOLEAN CopyVehiclePathToSoldier( SOLDIERTYPE *pSoldier )
pSoldier->pMercPath = CopyPaths(pVehicleList[ iId ].pMercPath, pSoldier->pMercPath );
return( TRUE );
}
BOOLEAN IsVehicle(SOLDIERTYPE *pSoldier)
{
if ( gProfilesVehicle[ pSoldier->ubProfile ].ProfilId == pSoldier->ubProfile )
return(TRUE);
else
return(FALSE);
/*switch(pSoldier->ubProfile)
{
case PROF_HUMMER:
case PROF_ELDERODO:
case PROF_ICECREAM:
return(TRUE);
default:
return(FALSE);
}
return(FALSE);
*/
return ( gMercProfiles[pSoldier->ubProfile].Type == PROFILETYPE_VEHICLE );
}
BOOLEAN SetUpMvtGroupForVehicle( SOLDIERTYPE *pSoldier )
{
// given this grunt, find out if asscoiated vehicle has a mvt group, if so, set this grunts mvt group tho the vehicle