diff --git a/docs/rh-log.txt b/docs/rh-log.txt index 91cf8d951..ca3b8e848 100644 --- a/docs/rh-log.txt +++ b/docs/rh-log.txt @@ -1,4 +1,7 @@ April 5, 2008 (Changes by Graf Zahl) +- Changed secret sector drawing in automap so that lines with the ML_SECRET + flag are only drawn as part of a secret sector if that secret has already + been found, even if the option is set to always show secret sectors. - Added the option to use $ as a prefix to a string table name everywhere in MAPINFO where 'lookup' could be specified so that there is one consistent way to do it. diff --git a/src/am_map.cpp b/src/am_map.cpp index 132b281e7..c0ed1deaa 100644 --- a/src/am_map.cpp +++ b/src/am_map.cpp @@ -1297,15 +1297,19 @@ static bool AM_CheckSecret(line_t *line) { if (line->frontsector != NULL) { - if (line->frontsector->oldspecial && - (am_map_secrets==2 || (am_map_secrets==1 && !(line->frontsector->special&SECRET_MASK)))) - return true; + if (line->frontsector->oldspecial) + { + if (am_map_secrets!=0 && !(line->frontsector->special&SECRET_MASK)) return true; + if (am_map_secrets==2 && !(line->flags & ML_SECRET)) return true; + } } if (line->backsector != NULL) { - if (line->backsector->oldspecial && - (am_map_secrets==2 || (am_map_secrets==1 && !(line->backsector->special&SECRET_MASK)))) - return true; + if (line->backsector->oldspecial) + { + if (am_map_secrets!=0 && !(line->backsector->special&SECRET_MASK)) return true; + if (am_map_secrets==2 && !(line->flags & ML_SECRET)) return true; + } } return false; } diff --git a/src/wi_stuff.cpp b/src/wi_stuff.cpp index fbc8c480f..0c47f5df6 100644 --- a/src/wi_stuff.cpp +++ b/src/wi_stuff.cpp @@ -331,7 +331,7 @@ void WI_LoadBackground(bool isenterpic) // If going from E1-E3 to E4 the default should be used, not the exit pic. // Not if the exit pic is user defined! - if (level.info->exitpic[0]!=0) return; + if (level.info->exitpic != NULL && level.info->exitpic[0]!=0) return; // E1-E3 need special treatment when playing Doom 1. if (gamemode!=commercial)