I’m making a game with my friend. Now there is a question about levels. First version was built with XML. There is a few reasons I don’t like it: too much data and there were some problems with parser we used. We are using Boost so I decided to look at json-parser.
The structure is much smaller and optimized. What do you think, isn’t this too radical to change from powerful xml to simple json? Would it be enough of json-structure power to organize big game-level with a lot of extra-data and attributes?
I use JSON a lot in webapps written in python – there are really good decoders for both XMLand JSON. There really isn’t a lot of difference except XML takes a little more space, but is more readable. JSON looks almost like a Python dictionary already, so that makes sense. Probably the main reason why JSON is more common on the web is that JSON-RPC is pretty good whereas XML-RPC is poorly thought of and SOAP is too heavy.
So it depends if you can find a good JSON decoder or not, which is fast enough for your needs. I don’t know boost or work in C/C++ very often.