How to make a "Robux Spent" leaderboard?

Hello,
I recently wanted to make a Leaderboard about how much Robux did people spend in my game, it looks like that:
image
The problem is that I don’t really know how to do that…
Can someone help me please?

3 Likes

You could either store the amount of Robux they spend in the datastore by taking the cost of the product they’re purchasing and adding it to the value already in the datastore.

Or you would just check which products they already own and add the total cost of that up and set it as the value of Robux Spent. I don’t recommend this way because if you adjust your prices it makes the player seem like they spent more than they actually did.

Another thing I would recommend is making this optional. Personally speaking the amount of Robux I spend in a game is nobody’s business. Adding something like this to a game is kinda like a donations leaderboard. It’s pretty unethical.

6 Likes

You could make a datastore and make it so it adds a value whenever you buy something new in the game.

3 Likes

Oh okay thanks! Should I use OrderedDataStore?

You use OrderedDataStore for the leaderboard data and for the “Robux Spent” value, you use a normal datastore.

1 Like

I actually want to be the only person who can see this information…

could you use a table/dictionary to store the gamepass/product values?