Only problem I had was that LÖVE does not have XOR so I made one.
Usage:
GetIsClockWise(x1,y1,x2,y2,x3,y3)
If points are given in clockwise order it returns true, else it returns false.
XOR(a,b)
if a is true and b is true returns false
if a is false and b is false returns false
if a is false and b is true returns true
if a is true and b is false returns true
example syntrax:
Code: Select all
if XOR(a > b, b < c) then
--my bla code if b neither biggest or smallest
else
--my bla code if b is biggest or smallest
end