[botlib] Use floating point absolute value rather than truncate to integer
This commit is contained in:
parent
9a5add2b60
commit
18d6c8fda2
5 changed files with 9 additions and 8 deletions
|
@ -168,7 +168,7 @@ int AAS_AgainstLadder(vec3_t origin)
|
|||
//get the plane the face is in
|
||||
plane = &aasworld.planes[face->planenum ^ side];
|
||||
//if the origin is pretty close to the plane
|
||||
if (abs(DotProduct(plane->normal, origin) - plane->dist) < 3)
|
||||
if (fabsf(DotProduct(plane->normal, origin) - plane->dist) < 3)
|
||||
{
|
||||
if (AAS_PointInsideFace(abs(facenum), origin, 0.1f)) return qtrue;
|
||||
} //end if
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue