mirror of
https://github.com/1dot13/source.git
synced 2026-08-05 14:00:23 +02:00
- Fixed problems with merc faces when doing certain actions. This bug was introduced in revision: 4396
o Fixes endless loop when clicking on items with explosives and merc starts to talk o Fixes hidden merc faces o Fixes wrong merc faces (merc face instead of skull) when merc is dead git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@4456 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -3166,12 +3166,48 @@ void SMInvClickCamoCallback( MOUSE_REGION * pRegion, INT32 iReason )
|
||||
{
|
||||
if ( fGoodAPs )
|
||||
{
|
||||
// WANNE: Old method for applying camo
|
||||
/*
|
||||
if (gGameExternalOptions.fShowCamouflageFaces == TRUE )
|
||||
{
|
||||
SetCamoFace( gpSMCurrentMerc );
|
||||
DeleteSoldierFace( gpSMCurrentMerc );// remove face
|
||||
gpSMCurrentMerc->iFaceIndex = InitSoldierFace( gpSMCurrentMerc );// create new face
|
||||
if ( gpSMCurrentMerc->bCamo > 0 )
|
||||
{
|
||||
gCamoFace[gpSMCurrentMerc->ubProfile].gCamoface = TRUE;
|
||||
DeleteSoldierFace( gpSMCurrentMerc );// remove face
|
||||
gpSMCurrentMerc->iFaceIndex = InitSoldierFace( gpSMCurrentMerc );// create new face
|
||||
}
|
||||
if ( gpSMCurrentMerc->urbanCamo > 0 )
|
||||
{
|
||||
gCamoFace[gpSMCurrentMerc->ubProfile].gUrbanCamoface = TRUE;
|
||||
DeleteSoldierFace( gpSMCurrentMerc );// remove face
|
||||
gpSMCurrentMerc->iFaceIndex = InitSoldierFace( gpSMCurrentMerc );// create new face
|
||||
}
|
||||
if ( gpSMCurrentMerc->desertCamo > 0)
|
||||
{
|
||||
gCamoFace[gpSMCurrentMerc->ubProfile].gDesertCamoface = TRUE;
|
||||
DeleteSoldierFace( gpSMCurrentMerc );// remove face
|
||||
gpSMCurrentMerc->iFaceIndex = InitSoldierFace( gpSMCurrentMerc );// create new face
|
||||
}
|
||||
if ( gpSMCurrentMerc->snowCamo > 0)
|
||||
{
|
||||
gCamoFace[gpSMCurrentMerc->ubProfile].gSnowCamoface = TRUE;
|
||||
DeleteSoldierFace( gpSMCurrentMerc );// remove face
|
||||
gpSMCurrentMerc->iFaceIndex = InitSoldierFace( gpSMCurrentMerc );// create new face
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
// WANNE: We should only delete the face, if there was a camo we applied.
|
||||
// This should fix the bug and crashes with missing faces
|
||||
if (gGameExternalOptions.fShowCamouflageFaces == TRUE )
|
||||
{
|
||||
if (SetCamoFace( gpSMCurrentMerc ))
|
||||
{
|
||||
DeleteSoldierFace( gpSMCurrentMerc );// remove face
|
||||
gpSMCurrentMerc->iFaceIndex = InitSoldierFace( gpSMCurrentMerc );// create new face
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Dirty
|
||||
fInterfacePanelDirty = DIRTYLEVEL2;
|
||||
|
||||
Reference in New Issue
Block a user