So I want to find where my ray ends so I can tween a part to it, it’s 300 studs long so there must be an end right?
local ray = Ray.new(SpellCastPart.CFrame.p, (MousePos - SpellCastPart.CFrame.p).unit *300)
So I want to find where my ray ends so I can tween a part to it, it’s 300 studs long so there must be an end right?
local ray = Ray.new(SpellCastPart.CFrame.p, (MousePos - SpellCastPart.CFrame.p).unit *300)
You would need to declare it as a variable:
local EndPos = (MousePos - SpeelCastPart.CFrame.p).Unit * 300
local Ray = Ray.new(SpellCastPart.CFrame.p, EndPos)
--[[
//Tween part here
]]--
This should work
local EndPosition = Ray.Origin + Ray.Direction