remove Q2_CONTENTS_TRANSLUCENT on load, since it breaks stuff
more areaportal fatal -> warning
This commit is contained in:
parent
8b4bd6deeb
commit
f64c8e7160
|
|
@ -1400,6 +1400,9 @@ static void ParseTextureDef(parser_t &parser, mapface_t &mapface, const mapbrush
|
|||
} else if (!extinfo.info) {
|
||||
extinfo.info = extended_texinfo_t{};
|
||||
}
|
||||
|
||||
// remove TRANSLUCENT; it's only meant to be set by the compiler
|
||||
extinfo.info->contents.native &= ~Q2_CONTENTS_TRANSLUCENT;
|
||||
}
|
||||
|
||||
tx->miptex = FindMiptex(mapface.texname.c_str(), extinfo.info);
|
||||
|
|
|
|||
16
qbsp/qbsp.cc
16
qbsp/qbsp.cc
|
|
@ -456,7 +456,14 @@ static void FloodAreas_r(node_t *node)
|
|||
if (node->planenum == PLANENUM_LEAF && node->contents.native == Q2_CONTENTS_AREAPORTAL) {
|
||||
// grab the func_areanode entity
|
||||
mapentity_t *entity = AreanodeEntityForLeaf(node);
|
||||
Q_assert(entity != nullptr);
|
||||
|
||||
if (entity == nullptr)
|
||||
{
|
||||
logging::print("WARNING: areaportal contents in node, but no entity found {} -> {}\n",
|
||||
node->bounds.mins(),
|
||||
node->bounds.maxs());
|
||||
return;
|
||||
}
|
||||
|
||||
// this node is part of an area portal;
|
||||
// if the current area has allready touched this
|
||||
|
|
@ -555,6 +562,13 @@ static void SetAreaPortalAreas_r(node_t *node)
|
|||
// grab the func_areanode entity
|
||||
mapentity_t *entity = AreanodeEntityForLeaf(node);
|
||||
|
||||
if (!entity)
|
||||
{
|
||||
logging::print("WARNING: areaportal missing for node: {} -> {}\n",
|
||||
node->bounds.mins(), node->bounds.maxs());
|
||||
return;
|
||||
}
|
||||
|
||||
node->area = entity->portalareas[0];
|
||||
if (!entity->portalareas[1]) {
|
||||
logging::print("WARNING: areaportal entity {} doesn't touch two areas\n Entity Bounds: {} -> {}\n",
|
||||
|
|
|
|||
Loading…
Reference in New Issue