How would I go about creating a secure and reliable global leaderboard system?

I am aware of OrderedDataStores, but I am just asking how to make them reliable and secure and update well.

I have this leaderboard setup that I am working with. There is an all-time, and a monthly board.

I am asking a couple of things:

  1. How would I make it so that, every month, monthly stores are wiped, and I won’t have to do it manually or have every server trying to wipe it?
  2. How would I make it so that the stores don’t get overwhelmed when updates? DataStore seems to get overwhelmed pretty quickly, so I am not sure if a player’s kills should be updated + applied to the leaderboard every time they get a kill, every time they leave, etc.

I have never made a system for this before, so I am just asking on how to handle this.

1 Like

I just made myself one today for the first time, so you may also look into other replies as im not that experienced in that topic!

  1. To automatically wipe your leaderboards every month or so, you may use Os.date and when the server starts or so, you detect once if the specifiq date is reached or not.

  2. You can do a loop, so that the leaderboard is only updating like 5-10 Minutes. However, you have to store the kill a player made or do it like in my first sentence and save them in a variable and save all kills every 5-10 Minutes but that will be more work and CAN cause problems.

  3. To the title point security: You just have to handle the Kill Detect, as the Leaderboard Update on the Server and youll be fine. However, you also may not send any important RemoteEvents without checking its plr (RemoteEvents in general are NOT Exploit safe but until now, ByFron is doing a good job…)