It worked for lower numbers like numbers in Quintillion(Qn) and below, but it stopped updating the value after it got so high. I've tried for the past 20 mins to fix it and I can't think of any more ways to try.
local Stat = "Money" local PlayerCount = 30 local DataStore = game:GetService("DataStoreService"):GetOrderedDataStore("Leaderboard_"..Stat) local Pages = DataStore:GetSortedAsync(false,PlayerCount) local Data = Pages:GetCurrentPage() game.Players.PlayerRemoving:Connect(function(Player) if Player:FindFirstChild("Stats") then DataStore:UpdateAsync(Player.UserId, function(oldValue) return Player.Stats[Stat].Value end) end end)