Merged from revision: 7676

Features (by anv)
- new Ja2_Options.ini setting - HIDE_EXPLORED_ROOM_ROOF_STRUCTURES (e.g. sandbags) at ground level view
- Hold CTRL hotkey in mapeditor to place any object on roof

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7677 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Wanne
2014-12-06 13:37:25 +00:00
parent bb264d6815
commit eaa153b310
7 changed files with 104 additions and 6 deletions
+16 -1
View File
@@ -2022,20 +2022,35 @@ BOOLEAN HideStructOfGivenType(INT32 iMapIndex, UINT32 fType, BOOLEAN fHide)//dnl
{
if(fHide)
{
/*
if(fType >= FIRSTONROOF && fType <= LASTONROOF)
SetOnRoofIndexFlagsFromTypeRange(iMapIndex, fType, fType, LEVELNODE_HIDDEN);
else
SetRoofIndexFlagsFromTypeRange(iMapIndex, fType, fType, LEVELNODE_HIDDEN);
*/
// Buggler: set all tiles to their proper roof index flags
if(fType >= FIRSTROOF && fType <= SECONDSLANTROOF)
SetRoofIndexFlagsFromTypeRange(iMapIndex, fType, fType, LEVELNODE_HIDDEN);
else
SetOnRoofIndexFlagsFromTypeRange(iMapIndex, fType, fType, LEVELNODE_HIDDEN);
}
else
{
// ONLY UNHIDE IF NOT REAVEALED ALREADY
// ONLY UNHIDE IF NOT REVEALED ALREADY
if(!(gpWorldLevelData[iMapIndex].uiFlags & MAPELEMENT_REVEALED))
{
/*
if(fType >= FIRSTONROOF && fType <= LASTONROOF)
RemoveOnRoofIndexFlagsFromTypeRange(iMapIndex, fType, fType, LEVELNODE_HIDDEN);
else
RemoveRoofIndexFlagsFromTypeRange(iMapIndex, fType, fType, LEVELNODE_HIDDEN);
*/
if(fType >= FIRSTROOF && fType <= SECONDSLANTROOF)
RemoveRoofIndexFlagsFromTypeRange(iMapIndex, fType, fType, LEVELNODE_HIDDEN);
else
RemoveOnRoofIndexFlagsFromTypeRange(iMapIndex, fType, fType, LEVELNODE_HIDDEN);
}
}
return(TRUE);