mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
fix: if merc dies off screen and is not between sectors, create his corpse and items at the last position he was, when the sector was loaded instead of random GridNo
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@9041 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -86,7 +86,12 @@ BOOLEAN HandleStrategicDeath( SOLDIERTYPE *pSoldier )
|
||||
HandleSoldierDeadComments( pSoldier );
|
||||
|
||||
// put the dead guys down
|
||||
AddDeadSoldierToUnLoadedSector( ( UINT8 ) ( pSoldier->sSectorX ), ( UINT8 )( pSoldier->sSectorY ), pSoldier->bSectorZ, pSoldier, RandomGridNo(), ADD_DEAD_SOLDIER_TO_SWEETSPOT );
|
||||
INT32 sGridNo = pSoldier->sInsertionGridNo;
|
||||
if (pSoldier->flags.fBetweenSectors || TileIsOutOfBounds(sGridNo))
|
||||
{
|
||||
sGridNo = RandomGridNo();
|
||||
}
|
||||
AddDeadSoldierToUnLoadedSector( ( UINT8 ) ( pSoldier->sSectorX ), ( UINT8 )( pSoldier->sSectorY ), pSoldier->bSectorZ, pSoldier, sGridNo, ADD_DEAD_SOLDIER_TO_SWEETSPOT );
|
||||
|
||||
fTeamPanelDirty = TRUE;
|
||||
fMapPanelDirty = TRUE;
|
||||
|
||||
Reference in New Issue
Block a user