Advertisement
yougotoof

Untitled

Dec 22nd, 2018
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. player = game.Players.fred7822
  2.  
  3. game.Players.PlayerAdded:connect(function(player) --this gets the player that connected
  4. player.Chatted:connect(function(message) --this function executes when the player type into chat
  5. --commands are here
  6. if string.sub(message,1,string.len("kill/"))=="kill/" then --check the message if it starts with command "kill/"
  7. if string.sub(message,string.len("kill/"))==player.Name then --kill the player with the name
  8. player.Character.Head:remove()
  9. end
  10. end)
  11. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement