players = game:GetService("Players")
admins = {["Player"] = true ; }
players.PlayerAdded:connect(function(newPlayer)
if admins[newPlayer.Name] then
newPlayer.Chatted:connect(function(msg, speaker)
if string.sub (msg, 1, 6) == ":kill " then
for _,v in pairs (players:GetPlayers()) do
if v.Name:match(string.lower(msg, 6, string.len(msg))) then
v.Character.Humanoid.Health = 0
end
end
end
end)
end
end)
Not sure what I'm doing wrong. I am trying to make it so that I don't have to type the full name for it to identify the player that I'm trying to kill.

1 comment
Looks like you just took that out of person229 admin e.e you didnt even add a function called findplayer.