summaryrefslogtreecommitdiffhomepage
path: root/src/core.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/core.c')
-rw-r--r--src/core.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/core.c b/src/core.c
index 2171835a..3692845f 100644
--- a/src/core.c
+++ b/src/core.c
@@ -1061,8 +1061,7 @@ Ray GetMouseRay(Vector2 mousePosition, Camera camera)
Vector3 cameraPlanePointerPos = rlUnproject((Vector3){ deviceCoords.x, deviceCoords.y, -1.0f }, matProj, matView);
// Calculate normalized direction vector
- Vector3 direction = Vector3Subtract(farPoint, nearPoint);
- direction = Vector3Normalize(direction);
+ Vector3 direction = Vector3Normalize(Vector3Subtract(farPoint, nearPoint));
if(camera.type == CAMERA_PERSPECTIVE)
{