EasyRPG writer file format


#1

EasyRPG editor will import RPG Maker 2000 and 2003 games (LDB, LMU, LMT file formats) but the saving format will not be the same. We need a new format for a better experience.

What kind of file format should be the most appropiate?

Some proposals:

XML using TinyXml: Small C++ XML parser library, minimal (no DTD), converts XML into C++ objects and vice-versa. UTF-8 support, of course (note: wxWidgets have XML support inside, tinyXML would be for the player).

Pros: Easy to read files, widely used and familiar format.
Cons: Maybe slower to parse than binary formats.

Google Protocol Buffers (protobuf). Serialization library thinking on portability and efficiency, RPC.

Pros: Maybe faster, powerful object serialization.
Cons: You need to compile .proto files.

Boost serialize. Like protobuf.

Pros: Like protobuf.
Cons: Big dependence, hard to read without specific software.

Own chunk based extensive format. New format made by hand.

Pros: Fast.
Cons: Hard to design and maintain, hard to read without own software.

I prefer the XML format, the parsing time is not very slow because RPG data is not really extensive for each map and event. What do you think?


#2

I also prefer XML, it’s easy to manually read and edit even without an editor, and it’s widely supported and easy to use. Protobuf could be a good alternative, but still XML is more widely know and there is a bigger community.

Boost dependencies aren’t worth for it’s serialization, specially for the player. And writing our own format would be tiresome and make the project development much slower.


#3

XML would be the best. I hate that XML-Files code is quite bloated but it’s by far the most popular and widely used format.
Have never hear about the other formats to be honest.
And designing a new binary format is crap, everybody goes away from properitary formats to make maintaining easier :wink:


#4

xml for sure.


#5

Ok, I suggest RapidXML instead of TinyXML for player: C++ style, very fast and low memory footprint.


#6

You should also take a look at pugixml.
It’s also a C++ library (and according to the doc its faster then tinyxml).
And as a bonus it has XPath-Support. Imo this is much better then iterating over the DOM ^^.


#7

Yes, pugixml is nice, is like rapidxml and easier to use, not as lightweight but if the lib size does not matter (xpath code of the lib is a bit bigger) I prefer pugixml instead of rapidxml :slight_smile:


#8

What about .ini files? Wouldn’t those be easier to parse than XML (and also smaller)?


#9

.ini is nice but if you want to add nested data with some hierarchy you need ugly solutions.

By the way, binary (lcf) and xml writer is done now.


#10

Nice talking to someone who knows what their talking about when it comes to .inis. :slight_smile:


#11

for example, if you want to configure map hierarchy with nesting you need to put some parent values, and it’s hard to know which is the parent. With XML the hiearchy is more visual, the nested code is self informative. In fact, currently maptree xml writer does this.