mirror of
https://github.com/1dot13/source.git
synced 2026-09-02 14:36:06 +02:00
Fix: Adding mercs to a vehicle when the player already has the maximum number of vehicles caused the game to crash on the next move order.
Trying to add more mercs to a vehicle than there was seats caused an error message with a 'null' name for the vehicle. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7554 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -8392,7 +8392,7 @@ void VehicleMenuBtnCallback( MOUSE_REGION * pRegion, INT32 iReason )
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_UI_FEEDBACK, gzLateLocalizedString[ 18 ], zVehicleName[ pVehicleList[ iVehicleID ].ubVehicleType ] );
|
ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_UI_FEEDBACK, gzLateLocalizedString[ 18 ], gNewVehicle[ pVehicleList[ iVehicleID ].ubVehicleType ].NewVehicleStrings );
|
||||||
}
|
}
|
||||||
|
|
||||||
fShowAssignmentMenu = FALSE;
|
fShowAssignmentMenu = FALSE;
|
||||||
|
|||||||
@@ -1718,7 +1718,8 @@ BOOLEAN EnterVehicle( SOLDIERTYPE *pVehicle, SOLDIERTYPE *pSoldier, UINT8 ubSeat
|
|||||||
}
|
}
|
||||||
|
|
||||||
// OK, add....
|
// OK, add....
|
||||||
AddSoldierToVehicle( pSoldier, pVehicle->bVehicleID, ubSeatIndex );
|
if ( !AddSoldierToVehicle( pSoldier, pVehicle->bVehicleID, ubSeatIndex) )
|
||||||
|
return( FALSE);
|
||||||
|
|
||||||
if ( !(guiTacticalInterfaceFlags & INTERFACE_MAPSCREEN ) )
|
if ( !(guiTacticalInterfaceFlags & INTERFACE_MAPSCREEN ) )
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user