mirror of
https://github.com/1dot13/source.git
synced 2026-07-29 13:52:17 +02:00
Fix: if no squad name is provided in xml, fall back on hardcoded name
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@8867 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -375,8 +375,6 @@ SGPPoint OrigSnitchSectorPosition={320,150};
|
||||
|
||||
SGPPoint OrigPrisonerPosition = {320, 150};
|
||||
|
||||
SQUAD_NAMES SquadNames[20];
|
||||
|
||||
//extern BOOLEAN fMapExitDueToMessageBox;
|
||||
|
||||
// at least one merc was hired at some time
|
||||
@@ -3845,15 +3843,15 @@ void AddStringsToMoveBox( void )
|
||||
// add this squad, now add all the grunts in it
|
||||
if( fSquadIsMoving[ iCount ] )
|
||||
{
|
||||
if ( gGameExternalOptions.fUseXMLSquadNames )
|
||||
swprintf( sString, L"*%s*", SquadNames[ iSquadMovingList[ iCount ] ].squadname );
|
||||
if ( gGameExternalOptions.fUseXMLSquadNames && iSquadMovingList[iCount] < gSquadNameVector.size() )
|
||||
swprintf( sString, L"*%s*", gSquadNameVector[iSquadMovingList[iCount]].c_str() );
|
||||
else
|
||||
swprintf( sString, L"*%s*", pSquadMenuStrings[iSquadMovingList[ iCount ] ] );
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( gGameExternalOptions.fUseXMLSquadNames )
|
||||
swprintf( sString, L"%s", SquadNames[ iSquadMovingList[ iCount ] ].squadname );
|
||||
if ( gGameExternalOptions.fUseXMLSquadNames && iSquadMovingList[iCount] < gSquadNameVector.size() )
|
||||
swprintf( sString, L"%s", gSquadNameVector[iSquadMovingList[iCount]].c_str() );
|
||||
else
|
||||
swprintf( sString, L"%s", pSquadMenuStrings[iSquadMovingList[ iCount ] ] );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user