I already have a gui , kick button and frame. The frame composed of someone typing the name in a box, and under it there is a reason for why kicking. I put this in the gui, but it is noit working, any help?
local frame = script.Parent.Frame
local kickbutton = script.Parent.KickButton
frame.kickbutton.MouseButton1Click(function()
if game.players:FindFirstChild(frame.player.Text)then
game.ReplicatedStorage.KickPlayer:FireServer(frame.player.text, frame.Reason.Text)
end
end)

2 comments
Checking it out..
Should be like this ? local frame = script.Parent.Frame local kickbutton = script.Parent.KickButton local text = script.Parent.Frame["Player-Box"] local Reason = script.Parent.Frame["Reason-Box"] frame.kickbutton.MouseButton1Click(function() if game.players:FindFirstChild(frame.player.Text)then game.ReplicatedStorage.KickPlayer:FireServer(frame.player.text, frame.Reason.Text)