ReservedServer Duration

So I am making a feature in my SCPF where high ranks can create a reserved server to access their tryout then get people to join via the code which gets posted on the discord.

The only thing is, I have found the servers stay open even when there are 0 players inside, they dont close, is there a duration a ReservedServer can stay open or is their a way to shut a reservedserver down.

Many thanks, I would like to take any and all suggestions!

1 Like

The reason I am asknig this is because I do not want lots of ReservedServers being made and clogging up, is there a way to remove them?

Can you clarify how this is an issue?

If a ReservedServer has 0 players, it’s basically useless as these servers cannot be joined without scripts.

Have you tried removing ReservedServer IDs from your own databases? afaik Roblox doesn’t have an API to let developers see reserved servers.


https://gyazo.com/29ee0aea578c67db0236655268688548

As you can see the logs get posted in our discord, therefore anyone can join this and I do not want this to happpen.

Is there any effects when there is multiple (if not hundreds) of ReservedServers on a game.

A way I can think of doing this is by giving your admins the ability to Delete a server. When this occurs, the server’s ID is logged in a datastore as being deleted. This means that when someone tries to connect with the ID, it checks this datastore.

If the server is flagged as being deleted, you can simply refuse to connect the user.

P.S. you should stop using Gyazo.

Not that I know of.

1 Like

Looking at the docs I don’t think that the code still being valid means that anything is actually running when no one has joined. The docs say this: “Access codes remain valid indefinitely, meaning reserved servers can still be joined if no game server is running (in this case a new game server will be started)”. It isn’t 100% clear but I interpret it to mean that even if the code is valid, there is no server running and therefore there is not really any load.

Correct. If a server has no players, it is closed by Roblox, however if the ReservedServer code is used again, a new server will be created.

Ah, so my problem is the server is not created until the code gets used by the player. so if I do what Elliot says and blacklist the code when they shutdown the server, it theroetically cannot be restarted?

1 Like

That is correct.

Roblox is able to issue as many server instances as they want at virtually no cost. A reserved server is simply a regular server that is taken out of automatic matchmaking and require a special code and function in order to join the server.

A server is not considered alive when 0 players are in the server, but it is when there are players in the server. Any server id and code are infinitely usable, so simply discarding and forgetting about them is sufficient enough to effectively delete them (just as the site does automatically).

You don’t really need to track deletions or blacklist servers, just don’t show the server id or access code publicly. Save it when you require it, otherwise remove it and discard it. You can add a special join menu in your game or similar if you require joining of servers without showing codes publicly. A certain utility called Adonis admin has this kind of private server management feature in it.

If you absolutely need to delete a server though, then you can save data to that specific server via DataStores. If you don’t need any server configurations, you can open up a deleted servers DataStore and use the server id as a key and true as a value. You’ll then require a script in the overall place that confirms if the running server is a reserved server, then fetch its configurations via the DataStore and act based on those values.

4 Likes