I’ve been attempting to make a queue system for a game in which if the total amount of players in a server goes over 50 players, new players must wait in a queue to get in. The problem occurs when I try to tally all the players for every server.
currently, I try to contact the datastore every 60 seconds to add/update the server info to global list of servers. When I update the population from a specific server, it will only show the specific server and no other servers as results, almost like the datastore is not spread across all servers (which it should be according to documentation). Apon running code on studio however, only one specific server will end up showing up and not the others. This does not change if you refresh.
I’ve tried using every type of datastore including ordereddatastore but got the same results. This is not my code as far as I know, as I’ve rewrote it 4 times now.
Found the issue, took me 8 hours to figure out what was going on. Completely irrelevant to datastores, it was cuased by how math.random works >:C