Please help

cf = CFrame.new
vc = Vector3.new
ang = CFrame.Angles
rd = math.rad
rd2 = math.random

local SSS = game:GetService("ServerScriptService")
local FRAMEWORK = SSS.pX_Handlers.Framework;
local EFFECTS = require(FRAMEWORK.Effects);

function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
	return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
end

function CastProperRay(StartPos, EndPos, Distance, Ignore)
	local DIRECTION = cf(StartPos,EndPos).lookVector
	return Raycast(StartPos, DIRECTION, Distance, Ignore)
end

1 comment

0

Here's the mistake. with the Vector3.new, it should have brackets with the new, so it should be like Vector3.new(). Do it to the CFrame as well, or that won't work either