Skip to content

Commit 66d551e

Browse files
committed
1 parent 01467b5 commit 66d551e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Objects/PVector.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ module.exports = function(options, undef) {
5151
};
5252

5353
PVector.angleBetween = function(v1, v2) {
54-
return Math.acos(v1.dot(v2) / (v1.mag() * v2.mag()));
54+
return Math.acos(v1.dot(v2) / Math.sqrt(v1.magSq() * v2.magSq()));
5555
};
5656

5757
PVector.lerp = function(v1, v2, amt) {

0 commit comments

Comments
 (0)