How to save a players data in a new place

im trying to be able to send a players data to a new place in the same game

basically lets say a player has 5 dollars in the start place i want it to be able to be sent to a new place and if the player leaves the game in the new place it saves there data still i know how to send the data to a new place but i dont know how ot save it if they leave the game in the new place

please help ty

1 Like

For saving player’s data you will need to use DataStores.

The same way you would receive and sent the data in your start place

Use TeleportData feature of TeleportService and GetJoinData() to get the data in a new place.
To save the data from the new place, you should use DataStores.

You can read more about this + piece of script here

The first part is useless because you can get the data as you would do in the start place because DataStores are shared. So @SenkoRogue you don’t need to do anything specific just do it how you do in the start place

Of course they are shared within one universe but why would you use DataStores when you can send the necessary data to the target place using TeleportOptions instead of performing GetAsync?

Because exploiters can spoof the data as you would need the function GetLocalPlayerTeleportData() to get the data passed from the main place and if those are stats then you would need to send it to the server which would save the modified one. So unless the data you are sending is not important then do not use that method. Else I agree that method would be better