- bugfix: Sam sites with index >=5 lacks ability to train militia (fixed by Lesh)

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@1376 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Wanne
2007-09-16 11:11:09 +00:00
parent 5035e83261
commit ce385421f1
+5 -15
View File
@@ -4468,6 +4468,7 @@ BOOLEAN IsThereAFunctionalSAMSiteInSector( INT16 sSectorX, INT16 sSectorY, INT8
BOOLEAN IsThisSectorASAMSector( INT16 sSectorX, INT16 sSectorY, INT8 bSectorZ )
{
INT32 cnt;
// is the sector above ground?
if( bSectorZ != 0 )
@@ -4475,21 +4476,10 @@ BOOLEAN IsThisSectorASAMSector( INT16 sSectorX, INT16 sSectorY, INT8 bSectorZ )
return( FALSE );
}
if( ( SAM_1_X == sSectorX ) && ( SAM_1_Y == sSectorY ) )
{
return( TRUE );
}
else if( ( SAM_2_X == sSectorX ) && ( SAM_2_Y == sSectorY ) )
{
return( TRUE );
}
else if( ( SAM_3_X == sSectorX ) && ( SAM_3_Y == sSectorY ) )
{
return( TRUE );
}
else if( ( SAM_4_X == sSectorX ) && ( SAM_4_Y == sSectorY ) )
{
return( TRUE );
for ( cnt = 0; cnt < NUMBER_OF_SAMS; cnt++ )
{
if( ( sSectorX == gpSamSectorX[cnt] ) && ( sSectorY == gpSamSectorY[cnt] ) )
return( TRUE );
}
return ( FALSE );