I have been looking around the internet for a while now trying to find a way to save objects on somebodies base, but i don't know how to or where to start. I just got finished making the base game yesterday and now it works, but i have no idea how to save your base or your cash in leaderstats. Please help!
I have the same problem but I may have the solution. You could put every object inside of ServerStorage and put a value such as a Vector3 Value inside of each object. I would put a StringValue inside of each object as well. You can store the position and rotation in these values. The String value is used to check if the item has been purchased or not.
Here is an example of checking if the object has been purchased:
local serverStorage = game:GetService("ServerStorage") if serverStorage.Object.StringValue.Value == "Purchased" then -- if the player has data load it serverStorage.Object:Clone().Parent = location game.location:WaitForChild("Object").Position = game.location.Object.Position.Value -- Same goes for rotation else -- Creates a new key for the player end
This is not a whole script just an idea. As far as storing the data just look up a Data Store tutorial. I will not be giving a script on that because there are lots of resources on that topic.