I'm having trouble getting my XML file to import. Granted it is unreasonably large, but I'm curious just how much I need to cut things down. It kind of seems like it is just timing out, so I'm wondering if being on a faster internet connection would make a difference.
How big is it? Off the top of my head it's 2MB but I need to double check.
I already decided to rework things because it was ridiculously huge (15MB). I figure that could take a few minutes for someone with mediocre internet to download. I think 2MB is probably a good limit given the current state of the internet. I think the simplified version I've come up with will be less than 1 MB in size. I'll post again once I have the final numbers.
LOL, 15 MB!!!! Can the Native/Flash Players even handle that?
I don't know. It took about 2 hours for my python script to run and generate it.
It might sound like overkill, but from a users perspective, the more complex map would actually be simpler, because I can use the extra factories to give more information about how the map works. Now I have to simplify some of that, so it will be a bit less intuitive what is going on.
Ozyman wrote:I already decided to rework things because it was ridiculously huge (15MB). I figure that could take a few minutes for someone with mediocre internet to download. I think 2MB is probably a good limit given the current state of the internet. I think the simplified version I've come up with will be less than 1 MB in size. I'll post again once I have the final numbers.
Random inflammatory opinion, XML is ridiculously huge. If you're dealing with a scripting language, JSON gives you equivalent expressive power in much more compact form. (Faster to process as well.) If you're dealing with a compiled language, well, there is a reason that Google uses protobufs internally. (Within Google, XML only exists for talking to people outside of Google who have worse toolchains.) Apache Thrift is a similar idea.
Of course for most problems, even XML is "good enough". But I don't expect people to stop coming up with new formats any time soon. Personally I'm rather excited about http://kentonv.github.io/capnproto/.
I basically agree. JSON is also much easier to read than XML IMO. I'm not familiar with protobufs, Apache Thrift, & capnproto, but they all look interesting.
The big advantage to XML is its history. Much easier to find libraries, editor support, etc. And as you said, it's usually 'good enough'.
If you're really stuck I can tweak upwards... poss to 4MB but 15MB is a bit excessive ;)
tom wrote:If you're really stuck I can tweak upwards... poss to 4MB but 15MB is a bit excessive ;)
Thanks Tom. I think I can make this work. I'll let you know if I want some help.