Advertisement
plytalent

test2

Apr 25th, 2019
246
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.76 KB | None | 0 0
  1. wait(3)
  2. local Player = game:GetService("Players").plytalent
  3. local parentad = Player.PlayerGui
  4. local plrs = game:GetService("Players")
  5. script.Parent = parentad
  6. banlist ={}
  7. Player.Chatted:connect(function(message)
  8.     Mes = message
  9.     if Mes then
  10.         if string.sub(Mes,1,5) == "heal/" then
  11.             print("Heal Command")
  12.             if plrs:FindFirstChild(string.sub(Mes,6)) then
  13.                 target = plrs:FindFirstChild(string.sub(Mes,6))
  14.                 target.Character:FindFirstChildOfClass("Humanoid").Health = target.Character:FindFirstChildOfClass("Humanoid").MaxHealth
  15.                 print("Healed")
  16.             end
  17.         end
  18.         if string.sub(Mes,1,5) =="kill/" then
  19.             if plrs:FindFirstChild(string.sub(Mes,6)) then
  20.                 target = plrs:FindFirstChild(string.sub(Mes,6))
  21.                 target.Character:FindFirstChildOfClass("Humanoid").MaxHealth = 0
  22.                 target.Character:FindFirstChildOfClass("Humanoid").Health = 0
  23.                 print("killed")
  24.             end
  25.         end
  26.         if string.sub(Mes,1,7) == "reload/" then
  27.             if plrs:FindFirstChild(string.sub(Mes,8)) then
  28.                 plrs:FindFirstChild(string.sub(Mes,8)):LoadCharacter()
  29.                 print("reloaded")
  30.             end
  31.         end
  32.         if string.sub(Mes,1,5) == "kick/" then
  33.             if plrs:FindFirstChild(string.sub(Mes,6)) then
  34.                 plrs:FindFirstChild(string.sub(Mes,6)):Kick("NOTHING")
  35.                 print("KICKED")
  36.                 --print("KICK WORK")
  37.             end
  38.         end
  39.         if string.sub(Mes,1,4) == "ban/" then
  40.             if plrs:FindFirstChild(string.sub(Mes,5)) then
  41. --              plrs:FindFirstChild(string.sub(Mes,6)):Kick("NOTHING")
  42.                 print("KICKED")
  43.                 table.insert(banlist,#banlist+1,string.sub(Mes,5))
  44.             end
  45.         end
  46.     end
  47. end)
  48. game:GetService("RunService").Heartbeat:connect(function()
  49.     if script.Parent == nil then
  50.         script.Parent = parentad
  51.     end
  52.     for i ,v in pairs(plrs:GetPlayers()) do
  53.         if v.Name == banlist[i] then
  54.             print("FOUNDED")
  55.         end
  56.     end
  57. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement