Advertisement
Jaden11

Chat Commands I made ROBLOX

Dec 27th, 2014
528
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.24 KB | None | 0 0
  1. local admins = {"TheVr3millionCoder"}
  2. function tableContains(t, value)
  3. for _, v in pairs(t) do
  4. if v == value then
  5. return true
  6. end
  7. end
  8. return false
  9. end
  10.  
  11. function onChatted(message, player)
  12. if message == "reset" and tableContains(admins, player.Name) then
  13. player.Character:BreakJoints()
  14. end
  15. end
  16.  
  17. game.Players.PlayerAdded:connect(function(player)
  18. player.Chatted:connect(function(message) onChatted(message, player) end)
  19. end)
  20.  
  21.  
  22. function tableCotains(t, vaule)
  23. for _, v in pairs(t) do
  24. if v == false then
  25. return true
  26.  
  27. end
  28. end
  29. return false
  30. end
  31.  
  32. function onChatted(message, player)
  33. if message == "kill" and tableContains(admins, player.Name) then
  34. player.Character.Humanoid.Health = 0
  35. end
  36. end
  37.  
  38. game.Players.PlayerAdded:connect(function(player)
  39. player.Chatted:connect(function(message) onChatted(message, player) end)
  40. end)
  41.  
  42. function tableContains(t, vaule)
  43. for _, v in pairs(t) do
  44. if v == false then
  45. return true
  46.  
  47. end
  48. end
  49. return false
  50. end
  51.  
  52. function onChatted(message, player)
  53. if message == "noob" and tableContains(admins, player.Name) then
  54. player.Chatted:connect(function(message) onChatted(message, player) end)
  55. end
  56. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement