mirror of
https://github.com/1dot13/source.git
synced 2026-08-05 14:00:23 +02:00
If a container is destroyed by gunfire or vehicle collision, don't destroy the contents, reveal them instead.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@9087 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -3500,6 +3500,28 @@ void RemoveAllUnburiedItems( INT32 sGridNo, UINT8 ubLevel )
|
||||
}
|
||||
}
|
||||
|
||||
void RevealAllUnburiedItems( INT32 sGridNo, UINT8 ubLevel )
|
||||
{
|
||||
ITEM_POOL *pItemPool;
|
||||
|
||||
// Check for and existing pool on the object layer
|
||||
GetItemPool( sGridNo, &pItemPool, ubLevel );
|
||||
|
||||
while ( pItemPool )
|
||||
{
|
||||
if ( gWorldItems[pItemPool->iItemIndex].bVisible != BURIED )
|
||||
{
|
||||
gWorldItems[pItemPool->iItemIndex].bVisible = VISIBLE;
|
||||
gWorldItems[pItemPool->iItemIndex].bRenderZHeightAboveLevel = 0;
|
||||
gWorldItems[pItemPool->iItemIndex].ubNonExistChance = 0;
|
||||
gWorldItems[pItemPool->iItemIndex].usFlags &= ( ~WORLD_ITEM_DONTRENDER );
|
||||
}
|
||||
|
||||
pItemPool = pItemPool->pNext;
|
||||
}
|
||||
|
||||
NotifySoldiersToLookforItems();
|
||||
}
|
||||
|
||||
void LoopLevelNodeForShowThroughFlag( LEVELNODE *pNode, INT32 sGridNo, UINT8 ubLevel )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user