I’ve never seen in a game the idea of saving data that relies on a group of players, would this be because it’s not possible using Roblox datastores?
I’ve recently found a method that incorporates a duos leaderboard, however I am scapping this as it would be difficult to track the status of the partnership live. But if I were to create a group datastore and make it appear on a global leaderboard using OrderedDataStores, what method of saving would I need to use in order to have a global leaderboard of (let’s say) the concurrent power level of each individual within that group. I assume that the key of the group would be all of the players user ID together that is separated by a character such as a colon, but the problem is updating the value itself when the players are not in the same game.
Or in fact is this not effectively possible on Roblox?
If my understanding of what you’re trying to do is correct, couldn’t you potentially use the MessagingService to communicate between the servers and figure out the data of each person that share the same group? Let’s say you have 7 people that are all in the same group. You could then ping all of the servers using MessagingService and have the sent message be the name of that 7 person group. Each server would then iterate through its players, see if any of them are in that group, collect all the data it needs from those players, and then send out its own “answer” ping. The server that pinged the rest would then wait for this “answer” ping that includes the playing group members and their data that you wanted.
The MessagingService allows game servers in the same game to communicate with each other in real time (< 1 second) using topics.
It sounds like it would be plenty fast enough to do this as well. If you set the update speed on your global leaderboard to be pretty low, I’m sure all the pings wouldn’t be that intensive on the server. You’d have to try it out though.