How to tase player on click without tool

Is their a way I would be able to make something that would be like a taser but the player does not hold a tool?

I know how to make a taser, but I want to know how I might be able to make a script that would allow players to click other players without holding a tool, but it would need a cooldown. Would I just be able to modify the script to make it work?

Here is the post I used to make the taser.

Any help would be appreciated!

Is this even possible?

1 Like

do this(script in srvrscriptsrvice):

game.Players.PlayerAdded:Connect(function(player)
    player.CharacterAdded:Wait()
    local cd = Instance.new("ClickDetector", player.Character)
    cd.MouseClick:Connect(function()
        --tase code
    end
end)
1 Like

Cool, thanks, fo the help. I have been trying to figure it out for a little, because it was going to be the main part of my game.

1 Like

yes hello! you would probably be able to start by using the players mouse click event on a local script in startercharacterscripts , and mouse.target