mirror of
https://github.com/WerWolv/ImHex-Patterns.git
synced 2026-03-27 23:37:04 -05:00
patterns: Added Minecraft LCE ARC file format (#307)
* Create arc.hexpat * add test file * mention arc * abide by contributing.md * use virtual filesystem * brainfart * ifdefs to fix github actions moment #2
This commit is contained in:
26
patterns/arc.hexpat
Normal file
26
patterns/arc.hexpat
Normal file
@@ -0,0 +1,26 @@
|
||||
#pragma author DexrnZacAttack
|
||||
#pragma description Minecraft LCE ARC File
|
||||
#pragma endian big
|
||||
|
||||
import std.string;
|
||||
#ifdef __IMHEX__
|
||||
import hex.core;
|
||||
#endif
|
||||
|
||||
struct Table {
|
||||
u16 nameSize;
|
||||
char fileName[nameSize];
|
||||
u32 offset;
|
||||
u32 size;
|
||||
u8 file[size] @ offset;
|
||||
#ifdef __IMHEX__
|
||||
hex::core::add_virtual_file(fileName, file);
|
||||
#endif
|
||||
} [[name(std::string::to_string(fileName))]];
|
||||
|
||||
struct ARC {
|
||||
u32 count;
|
||||
Table table[count];
|
||||
};
|
||||
|
||||
ARC arc @ 0x00;
|
||||
Reference in New Issue
Block a user