Custom Private/VIP Server Teleport

  1. I would like to teleport the player to a server within another place via a custom code
    I am trying to do, if you have a gamepass, you can make a private server that anyone can join if they enter the code in ‘join’ textbox. If you don’t have a gamepass, it don’t matter, you can join a server with any code given

  2. I cant find a way to do custom private servers
    image

  3. What solutions have you tried so far?
    I tried to use the :TeleportToPrivateServer function but I did more research and that wouldn’t help me

event.OnServerEvent:Connect(function(player, id, placeId)
	local bool
	if tpDataStore:GetAsync(id) ~= nil then
		bool = true
		tpService:TeleportToPrivateServer(placeId, id, {player})
	else
		bool = false
	end
	print(tostring(bool))
end)

I’m not asking for a script, I’m asking for a method that I can use to make this possible

Sadly, the developer API does not allow Private Server/VIP Server purchase or to create one just yet. However, you can check if a user OWNS a private server.

you can also make a dev place within the game, and then just set up a remoteevent that only you can fire, that brings you to this dev place. there’s no real need for a fancy UI for it.

1 Like

When player purchase server, do

and show access code on gui (access code is returned from this function)

if joinserver clicked, do

with access code on textbox.

is access code unique for every purchase?

Must be issued once for each purchase.

So can I save that access code via datastore to be used even days after purchase yes?

Yes, you can.
This code can be used forever, so must be manage expire date by the data store.