Code
					
				
				
					
						 Issues
						
							35
						
					
				
				
				
					
						 Pull requests
						
							11
						
					
				
				
					
						 Projects
						
							1
						
					
				
				
					
						 Releases
						
							3
						
					
				
				
					
						 Packages
						
							1
						
					
				
				
					
						 Wiki
					
				
				
				
					
						 Activity
					
				
				
				
		
	Var Dump: 
 Mailing List
				
				
			dumpVar: only available in dev mode
						
							Page:
							File Type - Bundle Database
						
						
					
					
							Pages
							
							
								Building the source code
							
								Building your first mod
							
								Bundle Patcher Architecture
							
								CLI Reference
							
								Debugging with Ghidra on Linux
							
								File Type - Bundle Database
							
								File Type - Bundle
							
								File Type - Material
							
								File Type - Package
							
								File Type - Strings
							
								File Type - Texture
							
								File Type - Wwise Bank
							
								File Type - Wwise Event
							
								File Type - Wwise Stream
							
								File Type Status
							
								Home
							
								Installing mods with DTMM
							
								Migrating from loose files
							
								Murmur hashes and dictionaries
							
								Obtaining the Oodle library
							
								Register DTMM as handler for Nexus downloads
							
								Reverse Engineering - Getting Started
							
								Reverse Engineering - Sound
							
								Reverse Engineering - Textures
							
								WIP DDSImage::load
							
								dtmt.cfg Reference
							
						
					No results
				
					2 
					File Type - Bundle Database
					
				
						
						Lucas Schwiderski edited this page 2024-07-12 13:10:51 +02:00 
					
				010Editor Template:
uint32 format <format=hex>;
uint32 num_entries;
typedef struct {
    uint32 version;
    Assert(version == 0x4);
    uint32 len_name;
    char name[len_name];
    uint32 len_stream;
    char stream[len_stream];
    byte platform_specific; // boolean
    // byte buffer[20] <bgcolor=0x3399ff>;
    byte buffer[20];
    local int is_0 = true;
    local int i = 0;
    for (i = 0; i < 15; i++) {
        if (buffer[i] != 0) {
            is_0 = false;
        }
    }
    if (!is_0) {
        Warning("Unknown 20-byte buffer is not 0");
    }
    uint64 file_time; // win32 FILETIME
} File;
typedef struct {
    uint64 hash <format=hex>;
    uint32 num_files;
    File files[num_files] <optimize=false>;
} Entry;
Entry entries[num_entries] <optimize=false>;
uint32 num_hashes;
typedef struct {
    uint64 bundle <format=hex>;
    uint64 resource_hash <format=hex>;
} ResourceHash;
ResourceHash hashes[num_hashes];
if (format <= 5) {
    return;
}
uint32 num_contents;
typedef struct {
    uint64 extension <format=hex>;
    uint64 name <format=hex>;
} Filename;
typedef struct {
    uint64 hash <format=hex>;
    uint32 num_files;
    Filename files[num_files];
} BundleContents;
BundleContents contents[num_contents] <optimize=false>;
Algorithm to calculate resource hashes by WhiteGoat:
uint64_t calc_hash(const std::vector<uint64_t>& list) {
    const uint64_t m = 0xc6a4a7935bd1e995ULL;
    const int r = 47;
    uint64_t k = 0;
    for (auto&& name : list) {
        uint64_t h = name;
        k *= m;
        k ^= k >> r;
        k *= m;
        
        h ^= k;
        k = m * h;
    }
    return k;
}
			Wiki
Building the source code
Obtaining the Oodle library
DTMM
Installing mods
Register DTMM as handler for Nexus downloads
DTMT
CLI Reference
Building your first mod
Migrating from loose files
dtmt.cfg Reference
Murmur hashes and dictionaries
Reverse Engineering
Getting Started
Sound
Textures
File Types
Status
Bundle
Bundle Database
Texture
Material
Strings
Package
Wwise Event
Wwise Stream
Wwise Bank