local Mods = {"Danielp533"}

function Kick(msg)
    for _,plrs in pairs(game.Players:GetChildren()) do 
        if msg == ":kick " .. plrs then 
            game.StarterGui.ScreenGui.You_Was_Kicked.Visible==true and game.Players[plrs]:kick--when you get kicked a gui that says you was kicked appears on the screen..then it kicks you..i made the gui
end
end
end


game.Players.PlayerAdded:Connect(function(plr)
    for _,Admin in pairs(Mods) do 
        if plr.Name == Mods then
            plr.Chatted:Connect(Kick)
        end
    end
end)
function Mute(msg)
    for _,plrs in pairs(game.Players:GetChildren()) do 
        if msg == ":mute " .. plrs then 
            game.Players[plrs]:local Mute = script:FindFirstChild("Mute"):clone() - Clones the script that mutes him
 if Mute then -- Checks if the mute script is there
	            local PlayerGui = plr:WaitForChild("PlayerGui")
	            Mute.Parent = PlayerGui
	            Mute.Disabled = false
	        end

        end
    end
end

game.Players.PlayerAdded:Connect(function(plr)
    for _,Admin in pairs(Mods) do
        if plr.Name == Mods then 
            plr.Chatted:Connect(Mute)
        end
    end
end)
function Speed(msg)
    for _,plrs in pairs(game.Players:GetChildren()) do 
        if msg == ":speed " .. plrs..50 then 
            game.Players[plrs].LocalPlayer.Character.Humanoid.Walkspeed=50
else if msg == ":speed " .. plrs..25 then
game.Players[plrs].LocalPlayer.Character.Humanoid.Walkspeed=25
else if msg == ":speed " .. plrs..35 then
game.Players[plrs].LocalPlayer.Character.Humanoid.Walkspeed=35
end
game.Players.PlayerAdded:Connect(function(plr)
    for _,Admin in pairs(Mods) do
        if plr.Name == Mods then 
            plr.Chatted:Connect(Speed)

function Ban(msg)
    for _,plrs in pairs(game.Players:GetChildren()) do 
        if msg == ":ban " .. plrs then 
       game.StarterGui.ScreenGui.You_Was_Banned.Visible=true
        m=1
      while m=1
            game.Players[plrs]:kick--the while loop is so they can never join back to same server since m is always 1
game.Players[plrs]:kick--a backup just in case
game.Players.PlayerAdded:Connect(function(plr)
    for _,Mods in pairs(Mods) do
        if plr.Name == Mods then 
            plr.Chatted:Connect(Ban)

1 comment

0

Modify your script so that it detects the msg being put into the chat. It is not defined that way but it should be.