From: havoc Date: Sat, 3 Feb 2007 03:36:26 +0000 (+0000) Subject: fixed two bugs that caused a constant state of "player stuck" (one was that it always... X-Git-Tag: xonotic-v0.1.0preview~3637 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=c70f975029c0915bc9f3f5914135f7646f05c276;p=xonotic%2Fdarkplaces.git fixed two bugs that caused a constant state of "player stuck" (one was that it always thought this was a q1bsp/hlbsp map, and the other was that the q1bsp/hlbsp corner checking was checking the wrong locations) git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@6774 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/sv_phys.c b/sv_phys.c index dbd6b33e..4cddc0a7 100644 --- a/sv_phys.c +++ b/sv_phys.c @@ -90,7 +90,7 @@ static int SV_TestEntityPosition (prvm_edict_t *ent) return true; else { - if (sv.worldmodel->brushq1.hulls && !VectorCompare(ent->fields.server->mins, ent->fields.server->maxs)) + if (sv.worldmodel->brushq1.numclipnodes && !VectorCompare(ent->fields.server->mins, ent->fields.server->maxs)) { // q1bsp/hlbsp use hulls and if the entity does not exactly match // a hull size it is incorrectly tested, so this code tries to @@ -99,9 +99,9 @@ static int SV_TestEntityPosition (prvm_edict_t *ent) vec3_t v; for (i = 0;i < 8;i++) { - v[0] = (i & 1) ? ent->fields.server->maxs[0] : ent->fields.server->mins[0]; - v[1] = (i & 2) ? ent->fields.server->maxs[1] : ent->fields.server->mins[1]; - v[2] = (i & 4) ? ent->fields.server->maxs[2] : ent->fields.server->mins[2]; + v[0] = ent->fields.server->origin[0] + (i & 1) ? ent->fields.server->maxs[0] : ent->fields.server->mins[0]; + v[1] = ent->fields.server->origin[1] + (i & 2) ? ent->fields.server->maxs[1] : ent->fields.server->mins[1]; + v[2] = ent->fields.server->origin[2] + (i & 4) ? ent->fields.server->maxs[2] : ent->fields.server->mins[2]; if (SV_PointSuperContents(v) & SUPERCONTENTS_SOLID) return true; }