Cannot store Dictionary in data store?
Asked by
4 years ago Edited 4 years ago
So I made a placement system and you can change its color, material etc. But the only thing that doesnt work is saving the build. here is my script:
03 | for i, inst in pairs (workspace:GetChildren()) do |
04 | if inst.Name = = "BuiltBlock" then |
05 | local position = inst.Position |
06 | local material = inst.Material |
07 | local color = inst.BrickColor |
08 | local size = inst.Size |
09 | partTable [ i ] = { Position = position, Material = material, Color = color, Size = size } |
13 | local success, err = pcall ( function () |
14 | BuildsDataStore:SetAsync(player.UserId, partTable) |
So when i try to save it, it prints:
104: Cannot store Dictionary in data store. Data stores can only accept valid UTF-8 characters.
Please help!!
Edit: Ok, so I found a way to save the data. But, it saves all the values as one? What is happening here?