Player = game.Players.LocalPlayer
Mouse = Player:GetMouse()
Mouse.Button1Down:Connect(function(Key)
print(Mouse.Hit.Position)
local Position = (Mouse.Hit.Position - game.Players.LocalPlayer.Character.Torso.Position).magnitude
local Bullet = Instance.new("Part")
Bullet.Anchored = true
Bullet.CanCollide = false
Bullet.Material = Enum.Material.Neon
Bullet.BrickColor = BrickColor.new("Wheat")
Bullet.CFrame = CFrame.new(game.Players.LocalPlayer.Character.Head.CFrame.Position)
Bullet.Size = Vector3.new(0.2,0.2,Position)
Bullet.Parent = workspace
Bullet.Orientation = game.Players.LocalPlayer.Character.Head.Orientation
end)
The bullet spawn inside the player, each long each way. I tried with ray but it just errors. Help?

2 comments
Here is a helpful tutorial for that! https://developer.roblox.com/articles/Making-a-ray-casting-laser-gun-in-Roblox
In this case, Ray Casting may be what you're looking for.