1
\$\begingroup\$

We are looking to add an archiving system to our game, where the assets (textures, scripts, sounds, etc.) will be located and directly accessed from memory. The main requirements are:

  • Files must not be compressed

  • Archive must have an internal folder structure

  • Individual files must be accessed directly from the archive without the need to extract them to the hard disk

  • If an external API is used, it must be able to run on Windows, Mac and Linux ; optimally, it should be redistributable free of charge

Our game engine is in C#, and we are looking for a managed solution (i.e. no PhysicsFS). What could be our options in this case?

Could it make sense to implement the whole thing by ourselves, using FileStream?

\$\endgroup\$

1 Answer 1

1
\$\begingroup\$

You can use Zlib .NET

\$\endgroup\$
5
  • \$\begingroup\$ I forgot to write that the files should not be compressed. \$\endgroup\$
    – Fueled
    Commented Jul 11, 2011 at 19:12
  • 1
    \$\begingroup\$ @fueled A read of the specification page of Zlib might enlightening for you. Though it compress assets but, the decompressing overhead is very low. \$\endgroup\$ Commented Jul 11, 2011 at 19:45
  • \$\begingroup\$ I was hoping for more answers, but in any way, I will accept yours, since it's a valid option. For the record, we ended up programming our own archiving system, which required a couple hours of effort and involved coding with FileStream and byte arrays. \$\endgroup\$
    – Fueled
    Commented Jul 19, 2011 at 19:34
  • \$\begingroup\$ @fueled Is there anything you didn't like with Zlib? \$\endgroup\$ Commented Jul 19, 2011 at 19:48
  • \$\begingroup\$ I did not get to study its capacities in depth, because soon after posting this question, our team leader decided we should implement our own, that it would be good practice, and so on. Thanks for suggesting it, though. \$\endgroup\$
    – Fueled
    Commented Jul 20, 2011 at 6:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .