Is Config File or Json File better for saving games?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By jujumumu

When I search up online how to save games using Godot. Tutorials pop up using Json files and Config files. Which one is better. Or what are the pros and cons of using each. Thanks!

:bust_in_silhouette: Reply From: jgodfrey

JSON has always served my needs well. It’s simple and reliable. That said, there are other choices. Here’s a pretty good overview of what’s available:

https://forum.godotengine.org/21370/what-are-various-ways-that-i-can-store-data

JSON is alright unless you’re loading dictionaries, vector2/3s or transforms. JSON will just return the data in a huge string rather than the actual type, config on the other hand can return exactly what you put in it.

Magso | 2020-02-28 08:40