this is my code (it's in a server script)
ammount = 10
timedelay = 5
currencyname = "EXP"
while true do
wait(timedelay)
for i,v in pairs(game.Players:GetPlayers()) do
if v:FindFirstChild("leaderstats") and v then
v.leaderstats[currencyname].Value = v.leaderstats[currencyname].Value + ammount
end
end
end
I need the while loop to stop when you have 50000 EXP
if you know what do do please tell me in the comments
thanks

1 comment
You want it to stop for all player or just that player who has the max xp?