I want to make a script that detect if the person owns the server (Private Server) I want to make it so they have the power to kick/ban people from their server.
COMMUNITY QUESTION
What are the variables to detect servers?
1 answer
If you are going to allow the VIP server owner to run kick/ban commands, then do Player.Chatted events. As @Coder_1 said, you can use plr.UserId == game.PrivateServerOwnerId to detect the owner.
A second, more friendlier approach, is to make a GUI that is given to private server owners.
This discussion is preserved as it was. New answers, comments, and votes are closed.

1 comment
Try This and if it works i would love for you to upvote me!
game.Players.PlayerAdded:Connect(function(plr) -- activated on player join if plr.UserId == game.PrivateServerOwnerId then -- is the player the vip server owner? --They stay! else plr:Kick() -- They don't own it! end end)