qbsp: add a -nodetail switch, for debugging func_detail issues

This commit is contained in:
Eric Wasylishen 2017-05-31 23:23:53 -06:00
parent f5d4cd9202
commit 213e4b9f7d
3 changed files with 6 additions and 1 deletions

View File

@ -312,6 +312,7 @@ typedef struct options_s {
bool fNofill;
bool fNoclip;
bool fNoskip;
bool fNodetail;
bool fOnlyents;
bool fConvertMapFormat;
conversion_t convertMapFormat;

View File

@ -970,8 +970,9 @@ Brush_LoadEntity(mapentity_t *dst, const mapentity_t *src, const int hullnum)
}
/* If the source entity is func_detail, set the content flag */
if (!Q_strcasecmp(classname, "func_detail"))
if (!Q_strcasecmp(classname, "func_detail") && !options.fNodetail) {
cflags |= CFLAGS_DETAIL;
}
/* entities with custom lmscales are important for the qbsp to know about */
i = 16 * atof(ValueForKey(src, "_lmscale"));

View File

@ -607,6 +607,7 @@ PrintOptions(void)
" -nofill Doesn't perform outside filling\n"
" -noclip Doesn't build clip hulls\n"
" -noskip Doesn't remove faces with the 'skip' texture\n"
" -nodetail Convert func_detail to structural\n"
" -onlyents Only updates .MAP entities\n"
" -verbose Print out more .MAP information\n"
" -noverbose Print out almost no information at all\n"
@ -730,6 +731,8 @@ ParseOptions(char *szOptions)
options.fNoclip = true;
else if (!Q_strcasecmp(szTok, "noskip"))
options.fNoskip = true;
else if (!Q_strcasecmp(szTok, "nodetail"))
options.fNodetail = true;
else if (!Q_strcasecmp(szTok, "onlyents"))
options.fOnlyents = true;
else if (!Q_strcasecmp(szTok, "verbose"))