Delikatne zmiany w strukturze PAK. signed char zamiast short

This commit is contained in:
yanczi 2025-12-12 10:12:22 +01:00
parent b4f6d3a85a
commit a84a69cbd6
12 changed files with 330 additions and 73 deletions

View file

@ -25,13 +25,14 @@
#define EXTENSION "pak"
#define SIGNATURE "XPAK"
#define SIGNATURE_KEY_FILE 1497713496 // XKEY
#define SIGNATURE_KEY_FILE "XKEY"
#define VERSION 300
#define VERSION 0x03
// WielkoϾ pojedynczego bloku strumienia
#define CHUNK_STREAM_512KB 524288 // 512KB
#define CHUNK_STREAM_16MB 16777216 // 16MB
#define CHUNK_STREAM_256MB 268435456 // 256MB
enum StoreMethod
{
@ -42,39 +43,39 @@ enum StoreMethod
COMPRESSxENCRYPT = 3
};
#define FILE_FLAG_RAW 0x00
#define FILE_FLAG_COMPRESS 0x01
#define FILE_FLAG_ENCRYPT 0x02
#define FILE_FLAG_ZIPENC 0x03
#define FILE_FLAG_CHUNK 0x04
//Prgoram title
#define PROGRAM_TITLE "eXtendet PAK"
#define PROGRAM_VERSION "v1.3"
#define PROGRAM_VERSION "v0.4"
#define PROGRAM_AUTHOR "Yanczi"
#define PROGRAM_COMPILING "16 November 2025"
#define PROGRAM_COMPILING "12 December 2025"
#define PROGRAM_LICENSE "GNU LGPL v3"
//Limity
#define MAX_FILE_SIZE 2147483648 // 2GB
#define MAX_FILE_SIZE 8589934592 // 8GB
#define MAX_PAK_SIZE 8796093022208 // 8TB
// Metody zapisania pliku
#define RAW_FILE 0
#define ZIP_FILE 1
#define CRYPT_FILE 2
#define CRYPT_ZIP 3
struct CargoHead
{
std::string signature;
int16_t version;
int8_t version;
uint32_t files;
uint64_t table;
};
struct FilesTable
{
int16_t nameLen;
uint8_t nameLen;
std::string nameFile;
uint64_t hashName;
uint64_t offset;
uint64_t size;
uint64_t crc;
int16_t flag;
int8_t flag;
};