RayCast breaking! (distance from origin)

My problem is that Raycasting breaks when too far from the Origin (0,0,0)

local RayCastResult = workspace:Raycast(Sword.Position, Sword.Position + Vector3.new(0,-2000,0) ,Params)

This Video shows the raycast at a few hundered studs away
https://streamable.com/vsxy57
This Video shows the raycast at a few thousand studs away
https://streamable.com/9g83w7
(It just completely inverts!)

The second argument is a direction in local space, not world space.

- local RayCastResult = workspace:Raycast(Sword.Position, Sword.Position + Vector3.new(0,-2000,0) ,Params)
+ local RaycastResult = workspace:Raycast(Sword.Position, Vector3.new(0, -2000, 0), Params)
1 Like

hmm, I didn’t know you could just do that, i though the second one was relative to the world position…
But thanks anyway!