Parens for operator priority.

This commit is contained in:
Jay Dolan 2020-11-10 10:46:43 -05:00
parent f3db4e4523
commit 5c78413a45
2 changed files with 6 additions and 5 deletions

View File

@ -724,6 +724,7 @@ struct bfilter_t //c++ style
// 4=brush->owner->eclass->nShowFlags
// 5=brush->face->texdef.flags (q2)
// 6=brush->face->texdef.contents (q2)
// 7=!brush->face->texdef.contents (q2)
int mask;
const char *string;
bool active;
@ -735,7 +736,7 @@ struct bfilter_t //c++ style
typedef struct
{
int iTexMenu; // nearest, linear, etc
float fGamma; // gamma for textures
float fGamma; // gamma for textures
vec3_t colors[COLOR_LAST];
int exclude;
int include;

View File

@ -201,7 +201,7 @@ bool FilterBrush( brush_t *pb ){
if ( g_qeglobals.d_savedinfo.exclude & EXCLUDE_DETAILS ) {
if ( !pb->patchBrush && pb->brush_faces->texdef.contents & CONTENTS_DETAIL ) {
if ( !pb->patchBrush && ( pb->brush_faces->texdef.contents & CONTENTS_DETAIL ) ) {
return TRUE;
}
}
@ -239,16 +239,16 @@ bool FilterBrush( brush_t *pb ){
filterbrush = true;
break;
}
// quake2 - 5 == surface flags, 6 == content flags
}
// quake2 - 5 == surface flags, 6 == content flags, 7 == !content flags
else if ( filters->attribute == 5 ) {
if ( f->texdef.flags && f->texdef.flags & filters->mask ) {
if ( f->texdef.flags && ( f->texdef.flags & filters->mask ) ) {
filterbrush = true;
break;
}
}
else if ( filters->attribute == 6 ) {
if ( f->texdef.contents && f->texdef.contents & filters->mask ) {
if ( f->texdef.contents && ( f->texdef.contents & filters->mask ) ) {
filterbrush = true;
break;
}