put back parenthesis
This commit is contained in:
parent
712f4562a9
commit
86f0cd8e63
|
|
@ -282,7 +282,7 @@ RMAPI float Vector2Length(Vector2 v)
|
||||||
// Calculate vector square length
|
// Calculate vector square length
|
||||||
RMAPI float Vector2LengthSqr(Vector2 v)
|
RMAPI float Vector2LengthSqr(Vector2 v)
|
||||||
{
|
{
|
||||||
float result = v.x*v.x + v.y*v.y;
|
float result = (v.x*v.x) + (v.y*v.y);
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
@ -290,7 +290,7 @@ RMAPI float Vector2LengthSqr(Vector2 v)
|
||||||
// Calculate two vectors dot product
|
// Calculate two vectors dot product
|
||||||
RMAPI float Vector2DotProduct(Vector2 v1, Vector2 v2)
|
RMAPI float Vector2DotProduct(Vector2 v1, Vector2 v2)
|
||||||
{
|
{
|
||||||
float result = v1.x*v2.x + v1.y*v2.y;
|
float result = (v1.x*v2.x + v1.y*v2.y);
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
@ -306,7 +306,7 @@ RMAPI float Vector2Distance(Vector2 v1, Vector2 v2)
|
||||||
// Calculate square distance between two vectors
|
// Calculate square distance between two vectors
|
||||||
RMAPI float Vector2DistanceSqr(Vector2 v1, Vector2 v2)
|
RMAPI float Vector2DistanceSqr(Vector2 v1, Vector2 v2)
|
||||||
{
|
{
|
||||||
float result = (v1.x - v2.x)*(v1.x - v2.x) + (v1.y - v2.y)*(v1.y - v2.y);
|
float result = ((v1.x - v2.x)*(v1.x - v2.x) + (v1.y - v2.y)*(v1.y - v2.y));
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user