Best way to transmit data to a reserved server?

So I have this game setting thing, where the host of a lobby can select what type of game they want to play.

I planned on just relying on the PrivateServerId property, but it turns out it’s not the same in the place players teleport to, so that screws up my DataStore idea.

How else could I go about doing this? I read something about GetJoinData, but from what I’ve seen it looks like a really stupid implementation for sending server-sided data over to a new server.

Any help appreciated, thanks.

You can send data to the teleportData parameter whenever teleporting a player to a reserved server.

https://developer.roblox.com/en-us/api-reference/function/TeleportService/TeleportToPrivateServer
The 5th parameter.

You can then receive that data on the reserved server with the following function:

https://developer.roblox.com/en-us/api-reference/function/TeleportService/GetLocalPlayerTeleportData

1 Like