I’m currently in the process of creating a large scale update for my game, The Final Stand 2 The Final Stand 2 [6.8] Technician's Gadgets 3! - Roblox, which was planned to include different difficulties and game modes by creating multiple instances of the base game and assigning them a corresponding variable. I was then planning on using teleport service to teleport players to these instances from a Menu place which would allow players to select the difficulty and game mode they wish to play. Sadly, I’ve come to the realization that such a feature would impossible, or at the very least highly impractical, with the current universe APIs for a number of different reasons:
Firstly there’s no functionality to automatically matchmake players into a specific instance group or even have instance groups without the usage of DataStoreService, which isn’t designed to handle frequent updates or requests. Other games can get away with this somewhat as their servers are set to handle much larger quantities of players compared to The Final Stand 2’s playercount of 6 per server. But even with that said, other games on the platform that rely on DataStoreService to achieve similar functionality with large servers, take several minutes to update their server lists due to the restrictions. The most optimized Data Store system I could come up with that wouldn’t become throttled with server updates would include a unique Data Store for every different difficulty/gamemode with a linear key index for the servers whose values would include a table of various server information such as the server access code, current playcount and current night. The issue here is that I will have to wait close to a second every time I wish to fetch or update the list of servers due to the Data Store restrictions, and I couldn’t just have all the servers in a single key as that would run into throttling and data overriding issues. Even assuming there was functionality to batch request data from a Data Store so that data such as large server lists could be accessed in a reasonable amount of time, there still wouldn’t be any functionality to getting the local player’s ping to a server or even just getting the active server’s location, meaning players from Australia are very likely to get thrown into servers with people from the United States and suffer large latency issues as a result, which leads to less enjoyable end user experiences. On top of that the only way to tag an instance as being of a specific type (such as difficulty) would be to utilize the teleport data parameter of TeleportToPrivateServer, and have it get set by the server when the first player joins, which can be called locally and thus is open to abuse by malicious users.
So to summarize the issues:
- Data Stores can’t handle batch requests
- No way to ping a server to get its latency for match making
- No way to assign tags to servers without the usage of a teleporting player carrying the data which can be controlled by the client and thus abused
Proposed Solutions
- Allow for batch key fetch requests to a Data Store
- Add API for reserve servers to get pinged by a local player and return the latency. This should allow for several hundred servers to get pinged within a small amount of time.
- Allow for reserved servers to be created with a given an integer or string as a tag AND/OR make TeleportService server sided AND/OR allow for reserved servers to fetch their own access code
Alternatively a new service such as “UniverseService” could be created to better manage server instances and cut out the current Data Store requirements entirely.
This has been posted in Web Features as opposed to Client Features as the majority of the workload would be on the Web Team as opposed to the Client Team. Please move this to Client Features if I am mistaken in this regard.