THE PROBLEM: The guns projectile does not go where the mouse cursor is looking, I have researched this for a good few hours and have no clue what to do, if someone could point me in the right direction. (I don't need the gun to rotate with the player I just want the projectile to shoot from the mouses location)
HOW THE GUN WORKS It takes a projectile from a folder in workspace and clones it, the projectile has code to move itself forward and also damage players on impact. currently I am setting the clones position to the position of a part attached to the gun tool currently for testing purposes.
SCRIPT
Gun firing script:
local tool = script.Parent
local handle = tool:WaitForChild('Handle')
local FirePort = script.Parent.Handle.Real_Fire_Part
local ammo = game.ReplicatedStorage.Hyper_Ammo_Sniper
tool.Equipped:Connect(function()
tool.Equip.Playing = true
wait(2)
tool.Equip.Playing = false
end)
tool.Activated:Connect(function()
if ammo.Value > 0 then
print("phase1")
local bullet = game.Workspace.Projectiles.Hyper_Sniper_bullet:Clone()
bullet.Parent = game.Workspace
bullet.Anchored = true
bullet.Position = script.Parent.Handle.Real_Fire_Part.Position
bullet.Orientation = FirePort.Orientation
tool.Fire.Playing = true
ammo.Value = ammo.Value - 1
print("phase2")
end
end)
Please help i've got no clue what to do here.

2 comments
i know your never going to read this but on line 7 you could have done tool.Equip:Play() and get rid of lines 8 and nine but only if the sound is 2 seconds long if it is not don't change a thing buddy
also i need to know how to script a bullet i use bodyposition but it gets weird if the thing goes 1000 so either an inaccurate bullet or a slow bullet