Add comment explaining what Vector2Limit does

This commit is contained in:
Vinícius Bispo 2024-09-16 15:25:07 -03:00 committed by GitHub
parent 719de8db39
commit 7e234c79aa
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -393,6 +393,7 @@ RMAPI Vector2 Vector2Normalize(Vector2 v)
return result;
}
// Limit vector's length to the limit value
RMAPI Vector2 Vector2Limit(Vector2 v, float limit) {
Vector2 result = {v.x, x.y};
float length = sqrtf((v.x * v.x) + (v.y * v.y))