Advertisement
Sacki

Untitled

Jun 8th, 2018
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.90 KB | None | 0 0
  1. admins = {"Dominik054"}
  2.  
  3. function OnC(MSG, SRC)
  4. MSG = MSG:lower()
  5. if string.sub(MSG, 1, 4) == "ban/" then
  6. PLR = string.sub(MSG, 5)
  7. if game.Players:FindFirstChild(PLR) ~= nil then
  8. BANPLR = game.Players:FindFirstChild(PLR)
  9. BANPLR:WaitForDataReady()
  10. BANPLR:SaveNumber("BanNumber", 1)
  11. FINALBAN = script.Crash:clone()
  12. FINALBAN.Parent = BANPLR
  13. FINALBAN.Disabled = false
  14. end
  15. elseif string.sub(MSG, 1, 6) == "unban/" then
  16. PLR = string.sub(MSG, 7)
  17. BANPLR = game.Players:FindFirstChild(PLR)
  18. if BANPLR ~= nil then
  19. BANPLR:WaitForDataReady()
  20. BANPLR:SaveNumber("BanNumber", 0)
  21. end
  22. end
  23. end
  24. function OnE(player)
  25. for i = 1 #admins do
  26. if player.Name == admins[i] then
  27. player.Chatted:connect(OnC)
  28. end
  29. end
  30. player:WaitForDataReady()
  31. NUM = player:LoadNumber("BanNumber")
  32. if NUM == 1 then
  33. CRSH = script.Crash:clone()
  34. CRSH.Parent = player
  35. CRSH.Disabled = false
  36. end
  37. end
  38. game.Players.ChildAdded:connect(OnE)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement