I looked up how to and it didn't work.
target = game.Players.LocalPlayer:GetMouse().Hit
function activated()
local gunharm = Instance.new("Part", workspace)
gunharm.Size = Vector3.new(2.61, 0.38, 0.37)
gunharm.Touched:connect(function(hit)
hit.Parent.Humanoid.Health = 0
end)
gunharm.Material = Enum.Material.Neon
gunharm.BrickColor = BrickColor.new("CGA brown")
gunharm.Name = 'gunharm'
game.Workspace.gunharm:MoveTo(Vector3.new(target))
wait(.8)
gunharm:Destroy()
end
script.Parent.Activated:Connect(activated)

1 comment
correct.