Update raymath.h (#1802)

This commit is contained in:
isaac553876299 2021-06-01 17:00:40 +02:00 committed by GitHub
parent 1a7dace57e
commit d1ac38171c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -326,7 +326,7 @@ RMDEF Vector2 Vector2MoveTowards(Vector2 v, Vector2 target, float maxDistance)
float dy = target.y - v.y;
float value = (dx*dx) + (dy*dy);
if ((value == 0) || ((maxDistance >= 0) && (value <= maxDistance*maxDistance))) result = target;
if ((value == 0) || ((maxDistance >= 0) && (value <= maxDistance * maxDistance))) return target;
float dist = sqrtf(value);