Game Development Community

Another float comparison bug in Point2D.

by Tom Spilman · in Torque Game Engine Advanced · 08/14/2005 (9:58 pm) · 1 replies

There is a second float comparison bug in Point2D::operator==() in mPoint.h:

inline bool Point2D::operator==(const Point2D& _test) const
{
   return (x == _test.x) && (y == _test.x); // bug!
}

About the author

Tom is a programmer and co-owner of Sickhead Games, LLC.


#1
08/15/2005 (10:57 am)
Already fixed in 1.4, so hopefully it'll be fixed when we merge 1.4 up into TSE... Brian may get to it sooner, of course.