point within hexagon?

BlitzPlus Forums/BlitzPlus Programming/point within hexagon?

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

FYI,

(x1-x0)*(y2-y1)-(x2-x1)*(y1-y0) is just an equation that returns the distance from a point (x2,y2) to the closest point on a line (x0,y0)-(x1,y1). The cool part of the equation is that it will return negative numbers if a point is left of a line and positive numbers if the point is right of the line and 0 if the point is on the line.