snowparks
|
  |
| Joined: 10 Apr 2017 |
| Total Posts: 64 |
|
|
| 09 Jul 2017 11:55 PM |
When trying to save multiple instances using tables of properties, is it necessary to use JSONEncoding?
|
|
|
| Report Abuse |
|
|
snowparks
|
  |
| Joined: 10 Apr 2017 |
| Total Posts: 64 |
|
| |
|
OAuth2
|
  |
| Joined: 27 Nov 2016 |
| Total Posts: 751 |
|
| |
|
|
| 10 Jul 2017 12:17 AM |
| Nope, pretty sure JSON is normally just used for reading/sending web responses/requests. |
|
|
| Report Abuse |
|
|
OAuth2
|
  |
| Joined: 27 Nov 2016 |
| Total Posts: 751 |
|
|
| 10 Jul 2017 12:27 AM |
@Willie You can still convert a table into JSON and back using Encode/Decode. Encoding turns it into a string = savable in the datastore. |
|
|
| Report Abuse |
|
|
GGGGG14
|
  |
| Joined: 29 Jan 2012 |
| Total Posts: 25344 |
|
|
| 10 Jul 2017 01:29 AM |
It's not necessary at all.
DataStore:SetAsync("FruitsData", {Banana=1; Mango=2; Pear=3; Apple=false; Papaya="delicious"}) |
|
|
| Report Abuse |
|
|
|
| 10 Jul 2017 01:35 AM |
Doesn't it automatically convert it to json
|
|
|
| Report Abuse |
|
|
OAuth2
|
  |
| Joined: 27 Nov 2016 |
| Total Posts: 751 |
|
|
| 11 Jul 2017 08:50 AM |
@GG
I guess that's a way to do it. I saw "tables of properties" and automatically assumed Position, Size, CFrame, Surface, Material, etc. (Which I think you can save into a JSON to save to the DataStore) |
|
|
| Report Abuse |
|
|