mirror of
https://github.com/UberGames/ioef.git
synced 2024-11-23 20:52:54 +00:00
Set bsp_trace_t::surface.flags to surfaceFlags in server and game
Revert last commit so that grapple sky check is compatible with BSPC BotImport_Trace in (removed from repo) code/bspc/be_aas_bspq3.c. Set bsp_trace_t::surface.flags instead of surface.value to trace_t::surfaceFlags. surface.flags is only used for the sky check for grapple AAS reachability. surface.value is not used at all. bsp_trace_t is not part of the game VM API, so this does not affect VM compatibility. BotAI_Trace in game was changed to match server. surface.value/flags are not used in game.
This commit is contained in:
parent
dbd6f6d8b1
commit
c4f5176af4
3 changed files with 7 additions and 4 deletions
|
@ -3857,7 +3857,7 @@ int AAS_Reachability_Grapple(int area1num, int area2num)
|
|||
//
|
||||
bsptrace = AAS_Trace(start, NULL, NULL, end, 0, CONTENTS_SOLID);
|
||||
//the grapple won't stick to the sky and the grapple point should be near the AAS wall
|
||||
if ((bsptrace.surface.value & SURF_SKY) || (bsptrace.fraction * 500 > 32)) continue;
|
||||
if ((bsptrace.surface.flags & SURF_SKY) || (bsptrace.fraction * 500 > 32)) continue;
|
||||
//trace a full bounding box from the area center on the ground to
|
||||
//the center of the face
|
||||
VectorSubtract(facecenter, areastart, dir);
|
||||
|
|
|
@ -149,7 +149,8 @@ void BotAI_Trace(bsp_trace_t *bsptrace, vec3_t start, vec3_t mins, vec3_t maxs,
|
|||
VectorCopy(trace.plane.normal, bsptrace->plane.normal);
|
||||
bsptrace->plane.signbits = trace.plane.signbits;
|
||||
bsptrace->plane.type = trace.plane.type;
|
||||
bsptrace->surface.value = trace.surfaceFlags;
|
||||
bsptrace->surface.value = 0;
|
||||
bsptrace->surface.flags = trace.surfaceFlags;
|
||||
bsptrace->ent = trace.entityNum;
|
||||
bsptrace->exp_dist = 0;
|
||||
bsptrace->sidenum = 0;
|
||||
|
|
|
@ -188,7 +188,8 @@ static void BotImport_Trace(bsp_trace_t *bsptrace, vec3_t start, vec3_t mins, ve
|
|||
VectorCopy(trace.plane.normal, bsptrace->plane.normal);
|
||||
bsptrace->plane.signbits = trace.plane.signbits;
|
||||
bsptrace->plane.type = trace.plane.type;
|
||||
bsptrace->surface.value = trace.surfaceFlags;
|
||||
bsptrace->surface.value = 0;
|
||||
bsptrace->surface.flags = trace.surfaceFlags;
|
||||
bsptrace->ent = trace.entityNum;
|
||||
bsptrace->exp_dist = 0;
|
||||
bsptrace->sidenum = 0;
|
||||
|
@ -213,7 +214,8 @@ static void BotImport_EntityTrace(bsp_trace_t *bsptrace, vec3_t start, vec3_t mi
|
|||
VectorCopy(trace.plane.normal, bsptrace->plane.normal);
|
||||
bsptrace->plane.signbits = trace.plane.signbits;
|
||||
bsptrace->plane.type = trace.plane.type;
|
||||
bsptrace->surface.value = trace.surfaceFlags;
|
||||
bsptrace->surface.value = 0;
|
||||
bsptrace->surface.flags = trace.surfaceFlags;
|
||||
bsptrace->ent = trace.entityNum;
|
||||
bsptrace->exp_dist = 0;
|
||||
bsptrace->sidenum = 0;
|
||||
|
|
Loading…
Reference in a new issue