-
Notifications
You must be signed in to change notification settings - Fork 2
raylib.Vector2Angle
JoeStrout edited this page Apr 29, 2026
·
2 revisions
Calculate the signed angle from v1 to v2, relative to the origin (0, 0) NOTE: Coordinate system convention: positive X right, positive Y down positive angles appear clockwise, and negative angles appear counterclockwise
| Parameter | Default Value | Note |
|---|---|---|
| v1 | [0, 0] | |
| v2 | [0, 0] |
| Condition | Return Value |
|---|---|
| (always) | number |
v1 = [1, 0]
v2 = [0, 1]
angle = raylib.Vector2Angle(v1, v2)
print angle // approximately 1.5708 (pi/2 radians)