mirror of
https://github.com/Shpoike/Quakespasm.git
synced 2025-02-03 06:20:57 +00:00
Try to mimic vanilla's allsolid behaviour a bit better, for rogue's lavamen.
This commit is contained in:
parent
03435446b4
commit
c6ecb243d6
1 changed files with 6 additions and 2 deletions
|
@ -670,7 +670,6 @@ reenter:
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
trace->allsolid = false;
|
|
||||||
if (num == CONTENTS_EMPTY)
|
if (num == CONTENTS_EMPTY)
|
||||||
trace->inopen = true;
|
trace->inopen = true;
|
||||||
else if (num != CONTENTS_SOLID)
|
else if (num != CONTENTS_SOLID)
|
||||||
|
@ -731,6 +730,7 @@ reenter:
|
||||||
rht = Q1BSP_RecursiveHullTrace(ctx, node->children[side], p1f, midf, p1, mid, trace);
|
rht = Q1BSP_RecursiveHullTrace(ctx, node->children[side], p1f, midf, p1, mid, trace);
|
||||||
if (rht != rht_empty && !trace->allsolid)
|
if (rht != rht_empty && !trace->allsolid)
|
||||||
return rht;
|
return rht;
|
||||||
|
trace->allsolid = false;
|
||||||
rht = Q1BSP_RecursiveHullTrace(ctx, node->children[side^1], midf, p2f, mid, p2, trace);
|
rht = Q1BSP_RecursiveHullTrace(ctx, node->children[side^1], midf, p2f, mid, p2, trace);
|
||||||
if (rht != rht_solid)
|
if (rht != rht_solid)
|
||||||
return rht;
|
return rht;
|
||||||
|
@ -790,13 +790,17 @@ qboolean SV_RecursiveHullCheck (hull_t *hull, vec3_t p1, vec3_t p2, trace_t *tra
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
qboolean ret;
|
||||||
struct rhtctx_s ctx;
|
struct rhtctx_s ctx;
|
||||||
VectorCopy(p1, ctx.start);
|
VectorCopy(p1, ctx.start);
|
||||||
VectorCopy(p2, ctx.end);
|
VectorCopy(p2, ctx.end);
|
||||||
ctx.clipnodes = hull->clipnodes;
|
ctx.clipnodes = hull->clipnodes;
|
||||||
ctx.planes = hull->planes;
|
ctx.planes = hull->planes;
|
||||||
ctx.hitcontents = hitcontents;
|
ctx.hitcontents = hitcontents;
|
||||||
return Q1BSP_RecursiveHullTrace(&ctx, hull->firstclipnode, 0, 1, p1, p2, trace) != rht_impact;
|
ret = Q1BSP_RecursiveHullTrace(&ctx, hull->firstclipnode, 0, 1, p1, p2, trace) != rht_impact;
|
||||||
|
if (!trace->startsolid)
|
||||||
|
trace->allsolid = false;
|
||||||
|
return ret;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue