Is there no way to securly send information server to server when teleporting?

Currently the only way I know of is to use GetLocalPlayerTeleportData, but as the name implies it is locally done, meaning any information could be spoofed as in order to pass the information, I need to fire an event Client → Server which means that information is not trustworthy.

Unless I’m missing something there is no way to verify that information so it’s as good as useless, Thanks in advance!

Another function called :GetTeleportData is available to server.

1 Like

How exactly would I use it? I had enough trouble getting the local one to work, it doesn’t seem to have much documentation on it.

Yes that’s what I linked but it shows how to retrieve information using :GetLocalPlayerTeleportData().

1 Like

I just tried that and got nil, I’m guessing I’m just doing it wrong.

Server 1

TeleportService:Teleport(Game_ID, Player, game.PlaceId)

Server 2 (Receiving Information)

game.Players.PlayerAdded:Connect(function(Player)
	local TeleportData = Player:GetJoinData()
	
	if TeleportData then
		print(TeleportData[1])
	else
		print("No Data")
	end
end)

It prints nil, i tried just doing print(TeleportData) and that gave me gibberish, so I’m guessing im misunderstanding how to retrieve the information passed over.

You’ll have to do Player:GetJoinData().TeleportData

1 Like

That did the job, Though it did error “tried to index number with number” but then started to work, so… Either way this is massively helpful thank you.

game.Players.PlayerAdded:Connect(function(Player)
	local TeleportData = Player:GetJoinData().TeleportData
	
	if TeleportData then
		print(TeleportData)
	else
		print("No Data")
	end
end)

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.