Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How do i Data Save a model?

What's the workaround saving a model? for instance a car that has properties in it like color, size and when i spawn i can access the car again and spawn it in the game?

1 answer

✓ Accepted answer

Put all the properties data in a table like

carData = {Color = "Red", Size = 20} -- example

and then save the datas with data store service

Put the base of the car with default properties on ReplicatedStorage or something

so when you load the game just load the data, clone the car into workspace, and apply the properties from the loaded table

Edit : Missing words -You need JSON service which convert table to string and vice versa to save table with data store btw

1 comment

0

-1 for saying "You need JSON service which convert table to string and vice versa to save table with data store btw". You do NOT need to encode, Roblox actually already does this, so you're overengineering/reinventing the wheel. Also, that service is HttpService.

This discussion is preserved as it was. New answers, comments, and votes are closed.