summaryrefslogtreecommitdiffhomepage
path: root/src/raymath.h
diff options
context:
space:
mode:
authorMurlocohol <[email protected]>2023-10-10 04:42:11 -0400
committerGitHub <[email protected]>2023-10-10 10:42:11 +0200
commit9702a17152d137766d85cd02060219787e3e228b (patch)
tree6057e9085aa81c11c22f4100e0463d1596a2728c /src/raymath.h
parentf0d949f931e286773aa0d0b87af4f58214ef611b (diff)
downloadraylib-9702a17152d137766d85cd02060219787e3e228b.tar.gz
raylib-9702a17152d137766d85cd02060219787e3e228b.zip
[raymath] Hotfix for Vector2Angle() and Vector2LineAngle() (#3396)
* Hotfix for Vector2LineAngle(), should probably be reviewed along with the rest of raylib angle functions to determine what coordinate system we want. * Hotfix for Vector2LineAngle(), should probably be reviewed along with the rest of raylib angle functions to determine what coordinate system we want. * [raymath] Hotfix for Vector2Angle and corresponding example * [raymath] Hotfix for Vector2Angle and corresponding example --------- Co-authored-by: Ray <[email protected]>
Diffstat (limited to 'src/raymath.h')
-rw-r--r--src/raymath.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/raymath.h b/src/raymath.h
index b01b0b22..ff601703 100644
--- a/src/raymath.h
+++ b/src/raymath.h
@@ -324,8 +324,7 @@ RMAPI float Vector2Angle(Vector2 v1, Vector2 v2)
float dot = v1.x*v2.x + v1.y*v2.y;
float det = v1.x*v2.y - v1.y*v2.x;
- // TODO(10/9/2023): Currently angles move clockwise, determine if this is wanted behavior
- result = -atan2f(det, dot);
+ result = atan2f(det, dot);
return result;
}