Here is the script i am trying to write.
local Humanoid = script.Parent.Humanoid
function PwntX_X()
local tag = Humanoid:findFirstChild("creator")
if tag ~= nil then
if tag.Value ~= nil then
local Leaderstats = tag.Value:findFirstChild("leaderstats")
if Leaderstats ~= nil then
Leaderstats.Robux.Value = Leaderstats.Robux.Value + math.random(1,5)
wait(0.1)
script:remove()
end
end
end
end
Humanoid.Died:connect(PwntX_X)
Does anyone know why it is not working??? Please leave an answer ;)

1 comment
Also assuming this script is in The player's Character, which is highly unlikely