Hello, i'm creating a simulator game and i'm wondering if it is possible to save player gui ? Especially one of them, which is important. Of course players can unlock stuff from this gui again, but i would like to save it and load with unlocked stuff.
If you're asking if its possible to save GUIs when someone resets, the answer is yes. There is a property named ResetOnSpawn
that does just that. To enable it, select the GUI you would like to save, and then change the ResetOnSpawn
property to true
.
If you're asking if its possible to save GUIs when someone rejoins, the answer is no. To achieve something like this, you should save data instead of saving the GUI itself. You can save data using Roblox's DataStore
service, which allows you to save strings, ints, numbers, and other various data types such as a table. For this particular example, you can save the data in a table and then load it again. From there, send the data to the player and have the player GUI handle unlocking things.
That may sound confusing, so here's some other wiki articles that could help get you going. If you have any other questions, feel free to contact me on discord joritochip#4657
.
http://wiki.roblox.com/index.php?title=Data_store
http://wiki.roblox.com/index.php?title=Saving_Player_Data
http://wiki.roblox.com/index.php?title=API:Class/ScreenGui/ResetOnSpawn
If I helped you out, please leave an upvote! If I solved your solution, please mark my reply as the post's solution. This allows future visitors to see the correct solution. Thanks!