ID:78609
 
Keywords: byond, gamesize
Every once in a while, I browse the Members blogs here to find interesting reads. Sometimes I find hidden gems (nice posts that go unnoticed), and sometimes I find a turd pretending to be a diamond:

The turd in question here is this one, and since I'm banned from SilkWizard's blog, I may as well take up this topic here proper.

However, this isn't about how stupid someone is or isn't. Whats the right thing to be doing, with assets in BYOND?

What sort of file formats should I be using?


For sound: OGG, MIDI, MP3 or properly compressed WAV files depending on the sound in question. Obviously, only compress to the point where there is no audible difference - If you start to experience sound quality loss, then step back up in file size until you don't. Many games use MP3 for longer sounds and compressed WAV for shorter sounds. Bad sound is very noticable, so if theres something you don't want to compress its most likely here.

For graphics: This will vary quite a bit if we're talking outside of BYOND, but in the case of BYOND you should be using PNG's and potentially JPEG files. Obviously, again, only compress to the point where there is no visible difference. This will depend largely on your artistic vision for the game - Palette reduction is better done as an initial choice before assets are drawn, rather than compression.

Is there lossless compression for PNGs?


Short answer: Yes. PNGOut.

Here is a tutorial for PNGOut. The command-line version is free, most of the default options for various values are completely fine.

Short list of the above


1) Compress your PNGs with a lossless compression tool, if possible.
2) Use proper formats for the job at hand (PNG, MP3, OGG, MIDI, compressed WAV)
3) Don't compress or reduce something if it looks worse or sounds worse. Ever.

Now, looking at the Games folder on this computer, here are a few figures:

Barkley Shut Up and Jam Gaiden:
Sound assets: 48.11MB (3MB of Voices, rest MP3s and a few compressed WAV's for sound effects)

Graphical assets: 5.63MB

A note on the graphical assets: Those are only backdrops / backgrounds / tile screens. The characters don't seem to be there, so I'm going to assume they're somewhere I haven't found them or bundled inside the game or something else.

Depths of Peril
Total assets size: 88.1MB

Depths of Peril bundles its assets into zipfiles, and I'm not much into looking inside them all and figuring out how much is sound and how much is graphics.

Galaxy Online
Total assets size: About 90MB

These are all games that have comparable graphics/sound to what BYOND is intended, and all 3 of these games could reliably be re-created in BYOND, with the exception of Galaxy Online, at least if it is to support thousands of simultaneous players as it does.

If you're not developing a game for web play, you don't need to go crazy optimizing a darn thing. People are downloading games regularly that take up in excess of 500-1000MB for smaller games - If your game is 3MB compressed and 6MB uncompressed and the difference in sound/visual quality is noticable, then you shouldn't be compressing at all. You're in such a low ballpark that it doesn't matter. Compress and optimize because its a good habbit to be doing, but not to the point where it has an effect on your intended game vision.

So, taking a look at SilkWizard's 2MB hardcap I really can't do anything except boggle at why you would set such a ridiculously low cap. I agree with Foomer's assessment that doing so only encourages worse-looking, worse-sounding games. If you have other techniques or ideas on how to reduce game size without resorting to reducing the quality of your game, then go ahead and mention them and I'll edit them in. If I'm incorrect somewhere, please point it out =)
Yea+1
Any idea if PNGOut works on DMIs? (Does it have to be used on each frame individually before importing?)
Good post.
ACWraith wrote:
Any idea if PNGOut works on DMIs? (Does it have to be used on each frame individually before importing?)

Actually I don't, I've only used it in other situations outside of BYOND. But as long as it doesn't mess with the comments field of a PNG, which it shouldn't, you should be fine. As you probably know, a DMI is just a PNG with some info in the comments field and a specific layout for each frame; assuming PNGOut is only concerned with image optimizations nothing should be destroyed / tampered with. If you find out, do tell - I can test it when I get back from work, but thats in about 14 hours.
2mb? Bugger that for a joke. The reason "it's only BYOND" doesn't fly with me. Screw that. I'll take up however many MB I damn well need. If people have a problem, they can cancel the download and bugger off to another game.
The save for web feature on adobe usually does the trick for cutting file size with minimal quality difference.

But yeah it does not really matter to much...
as usual, silkwizard is leeching entertainment from his own stupidity. and everybody is feeding him more.
In somewhat relevant news, Chatters source is 5MB large.
Just so you know I used JPG format for the star backdrop in Solar Conquest. Using PNG there would have been a bad idea, so JPG format does have some uses.
Foomer wrote:
Just so you know I used JPG format for the star backdrop in Solar Conquest. Using PNG there would have been a bad idea, so JPG format does have some uses.

True; I wasn't entirely sure how BYOND handled JPEG files, so I left that out; edited initial post to include JPG's.
Just FYI, as of 448 BYOND saves DMIs using a more compressed, palette-based PNG when possible (included resources will have to be resaved from DM to take advantage of this). This can result in a pretty substantial reduction. I don't think it makes a heck of a lot of difference unless your game uses hundreds of DMIs though (the trading-card games come to mind).
Silk is too busy throwing around insults to be worth listening to. Personally I'd suggest you axe the commentary here starting from DarkView's comment, and avoid having that debate soil your post.
Good post Alathon.

One thing to note... Most software projects in my industry can be described as 1) proof of concept/boiler plate, 2) customer demonstration, or 3) optimized production. You'll end up finding that core code for production or demonstrations comes from early proof of concept work. I imagine that the development cycle for games on BYOND follow a somewhat similar path.

Feature and scope creep would be the main issues I'd want to highlight. Software project should have portability, debuggability, and easy software management in the forefront.

As a side note, I had a coworker at my old company who prided and talked about size efficiency in code. He had a laundry list of two- and three-character scripts that he would run from his UNIX prompt... quite efficient. However, he tended not to make any feature _better_. As a result, when the performance reviews were in, his projects came in far below expectations and his contract was not renewed.

Arbitrarily capping executable size is not only incorrect, but is a harmful philosophy to your career if you dare to accept it.
You danish homoseuxal, we should probably talk on MSN some time.
Foomer wrote:
Personally I'd suggest you axe the commentary here starting from DarkView's comment, and avoid having that debate soil your post.

Done.
Stephen001 wrote:
You danish homoseuxal, we should probably talk on MSN some time.

That would require you to be on MSN in the first place ^^ But yes, yes we should!
Silk was just trying to grab attention for a self promoting post with hyperbole. Thanks for the helpful post with actual information!