Skip to content

Commit

Permalink
bspfile: explain why AUX and MIST are forced to be detail
Browse files Browse the repository at this point in the history
  • Loading branch information
ericwa committed Nov 18, 2024
1 parent cdedc62 commit 178e04e
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion common/bspfile.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1322,7 +1322,18 @@ struct gamedef_q2_t : public gamedef_t
// translucent objects are automatically classified as detail
if (surf_contents & EWT_CFLAG_TRANSLUCENT) {
surf_contents |= EWT_CFLAG_DETAIL;
} else if (surf_contents & (EWT_VISCONTENTS_MIST | EWT_VISCONTENTS_AUX)) {
}

// MIST and AUX are forced to be detail because:
// - you can see out of AUX if you go inside it, since the inside faces are omitted, so it doesn't make sense
// to be visblocking
// - MIST is typically used for small details that the mapper doesn't want the player to collide with.
//
// If the mapper really wants visblocking mist, we have a separate feature for that,
// func_illusionary_visblocker (but this feature is likely to let the player
// see into the void when their camera is right on top of the bordering faces, at least in the
// Q2 remaster engine, so it's not recommended.)
if (surf_contents & (EWT_VISCONTENTS_MIST | EWT_VISCONTENTS_AUX)) {
surf_contents |= EWT_CFLAG_DETAIL;
}

Expand Down

0 comments on commit 178e04e

Please sign in to comment.