Search Issue Tracker

Fixed in 2018.2.X

Votes

0

Found in

2017.1.1f1

Issue ID

979578

Regression

No

Vector2.Angle does not always return 0 between two identical vectors

Scripting

-

Steps to reproduce:
1. Open attached “Angle.zip” Unity project
2. Enter Play mode
3. Observe Console window

Expected results:
Angle with parameters Vector2(7.434414f, -10.59828f) and Vector2(7.434414f, -10.59828f) returns 0
Actual results:
Angle with parameters Vector2(7.434414f, -10.59828f) and Vector2(7.434414f, -10.59828f) returns 0.01978234

Reproduced in 2018.1.0b1, 2017.3.0f3, 2017.2.1p1, 2017.1.2p4, 5.6.5f1, 5.5.5p2, 5.5.0f3

Note: Same results with Vector2.SignedAngle

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.