Hey! So I’ve been working on a build system! I have been trying to figure how I can save multiple plots like Bloxburg how you can choose a build to save out of the ones you have! I had a few ideas:
Could I make a new key for each plot save and when the player selects a plot they load the key for that plot.
Could I make a different dictionary for each plot save.
If anyone has any better ideas or could help me figure how to do it best please comment below!
local playerData = {
["Plot1"] = {
PlotName = "WhateverTheySaveItAs",
PlotObjects = {} -- contains the serialised data of saved objects in the plot
},
["Plot2"] = {
PlotName = "WhateverTheySaveItAs2",
PlotObjects = {} -- contains the serialised data of saved objects in the plot
}
--etc...
}
Yes, you can can simply just do something like this:
local playerData = {
PlotCount = 2,
["Plots"] = {
["Plot1"] = {
PlotName = "WhateverTheySaveItAs",
PlotObjects = {} -- contains the serialised data of saved objects in the plot
},
["Plot2"] = {
PlotName = "WhateverTheySaveItAs2",
PlotObjects = {} -- contains the serialised data of saved objects in the plot
}
--etc...
}
}
Sorry for the formatting, but with the addition of PlotCount, you can simply do