You know what means from the title

anyway here the code

when the count down gets to 0 it stops the code from counting lower than 0 that's why enable = nil, I don't want to change anything of the code I want how to make the player get kicked?

local player = game.Players.LocalPlayer
enable = true


script.Parent.MouseLeave:Connect(function()
	repeat wait() until script.Parent.Text == "0"
	if script.Parent.Text == "0" then
		while script.Parent.MouseMoved do
			enable = nil
			    script.Parent.Text = ("0")
			player:Kick("Count down ended")
		end
	end
end)


3 comments

0

I don't think you can kick a player using LocalScripts.

0

Then what do i use?

0

You can kick yourself using localscripts but you cant kick other players for that you need to use a script