how do i stop it from doing this? i want it to be “locked” to player, i used weldconstraints to do this
https://gyazo.com/260794daa71ed8fdf149eb4b19892059.mp4
local Start = (RightHand.CFrame * CFrame.new(0,0,3))
local End = (RightHand.CFrame * CFrame.new(-1.5,0,-3))
local Middle = ((Start + (End.Position - Start.Position)/2) * CFrame.new(3,0,0)).Position
local NewAttack = rs.ArmAttack:Clone()
NewAttack.Position = RightHand.Position
NewAttack.Anchored = false
local weld = Instance.new("WeldConstraint")
weld.Parent = RightHand
weld.Part0 = RightHand
weld.Part1 = NewAttack
NewAttack.Parent = workspace
task.spawn(function()
local new = Bezier.new(Start.Position,Middle,End.Position)
for i = 1,28 do
local t = (i-1) / (28 - 1)
local Position = new:CalculatePositionAt(t)
local Derivative = new:CalculateDerivativeAt(t)
NewAttack.CFrame = CFrame.new(Position, Position + Derivative)
task.wait()
end
end)
i want it to basically move with the player while it’s being casted or sumn