Here is my script, I don't know what is up.
local Player = game.Players.LocalPlayer
local Character = Player.Character
local KeyBind = "u"
local Mouse = Player:GetMouse()
function FollowMouse()
local Target = script.Target:Clone()
Target.Parent = Character
Target.Position.X = Vector3.new(Mouse.X,Target.Position.Y,Target.Position.Z)
end
Mouse.KeyDown:Connect(function(Key)
if Key == KeyBind then
FollowMouse()
end
end)
(Fixed) By redoing the variable to Mouse.hit.p instead of Mouse.x it fixed it!

1 comment
I already fixed it. I had to define mouse.hit.p not mouse.x.