-
Notifications
You must be signed in to change notification settings - Fork 2
res
aspadm edited this page Oct 13, 2018
·
2 revisions
Resource archive
File contain one header:
struct header
{
uint magic; // 3C E2 9C 01
uint table_size; // files count
uint table_offset;
uint names_size;
};
On the header.table_offset
lay filetable:
struct file_info
{
uint next_index;
uint file_size;
uint file_offset;
time_t last_change_time; // 4 bytes Unix timestamp
ushort name_length;
uint name_offset; // in `names` array
};
struct file_info files_info[header.table_size];
After filetable lay packed name chars:
char names[header.names_size];
Other filespace is files data, which can be accessed by file's offset.