So look, I made a gold command a few mins ago, but it doesn't work.
What is the problem?
Admins = {"groovydino", "Player1", "Player"}
game.Players.PlayerAdded:connect(function(player)
player.Chatted:connect(function(msg)
for i,v in pairs(Admins) do
if msg:sub(1,9) == ":InfGold " then
for i,v in pairs(game.Players:GetPlayers()) do
if string.find(v.Name, string.sub(msg, 10)) ~= nil then
local stats = v:FindFirstChild("leaderstats")
if stats ~= nil then
local gold = stats:FindFirstChild("Gold")
if gold ~= nil then
gold.Value = 999999999
end
end
end
end
end
end
end)
end)

2 comments
You are making a similar mistake to this post: https://scriptinghelpers.org/questions/15872/why-can-i-still-use-commands-when-im-not-in-the-admins-table#19019
I thought I answered this question?