zlib && directories...

Started by
0 comments, last by iaretony 20 years ago
I''m trying to build a "Resource Manager" for my game... My basic idea is this: I will build a tree of directories that contain ALL of the resources for my game (graphics, sounds, config files)... The game will refer to a resource with it''s full path from the root of the tree... I will use winzip to zip the tree up into one zip file... The game will, at startup, using zlib, decompress the "resource" file... I get everything up till this point! But what have I just done? I decompressed a directory to memory? How can I use a directory in memory? Does this even make sense? Is it even possible? Tony
Advertisement
The directory structure and file names are stored in the ZIP-file, so when you need a certain file in a certain directory, just search the ZIP-file for that directory and file and decompress it.

I have a simple ZIP-file reader for C++ on my site. Take a look at it if you like and see how I did it. Clicky.

This topic is closed to new replies.

Advertisement