Clean trailing spaces

This commit is contained in:
Ray
2023-02-05 16:30:23 +01:00
parent c91190fc6e
commit 1fea266472
9 changed files with 179 additions and 189 deletions

View File

@@ -300,7 +300,7 @@ void DrawLineBezierCubic(Vector2 startPos, Vector2 endPos, Vector2 startControlP
float dy = current.y-previous.y;
float dx = current.x-previous.x;
float size = 0.5f*thick/sqrtf(dx*dx+dy*dy);
if (i==1)
{
points[0].x = previous.x+dy*size;
@@ -1639,19 +1639,19 @@ bool CheckCollisionPointTriangle(Vector2 point, Vector2 p1, Vector2 p2, Vector2
bool CheckCollisionPointPoly(Vector2 point, Vector2 *points, int pointCount)
{
bool collision = false;
if (pointCount > 2)
{
for (int i = 0; i < pointCount - 1; i++)
{
Vector2 vc = points[i];
Vector2 vn = points[i + 1];
if ((((vc.y >= point.y) && (vn.y < point.y)) || ((vc.y < point.y) && (vn.y >= point.y))) &&
(point.x < ((vn.x - vc.x)*(point.y - vc.y)/(vn.y - vc.y) + vc.x))) collision = !collision;
}
}
return collision;
}