Skip to content
View in the app

A better way to browse. Learn more.

ResHax

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Help us keep the site running.
Zero Tolerance for Disrespect

(PC) Death end re:Quest 2 .DAT files

Featured Replies

Solved by h3x3r

  • GabryTheSniper changed the title to (PC) Death end re:Quest 2 .DAT files
  • Supporter
//------------------------------------------------
//--- 010 Editor v10.0.2 Binary Template
//
//  File: OrochiDAT.bt
//  Authors: SeleDreams
//  Version: 0.2
//  Purpose: Analyzing Silicon Studio's Orochi / Mizuchi Engine data archiving format
//  Category: Archive
//  File Mask: GxArchivedFile???.dat
//  ID Bytes: 47 44 41 54
//  History: 
//   0.2   2020-05-08 SeleDreams: Implemented a feature allowing to see the file formats
//   0.1   2020-05-06 SeleDreams: Initial Release
//------------------------------------------------

typedef struct{
        uint Offset;
        uint Length;
 } GDATFileDef;


typedef struct {
    char MAGIC[4];
    int FileCount;
    GDATFileDef File_Definitions[FileCount];
} GDATHeader;


typedef struct{
        char MAGIC[4];
        byte Data[File.Header.File_Definitions[i].Length - 4];
} GDATFile<read=DisplayFileType>;

/** 
*  - This structure is an array containing all the files in the order of their definition.
*  - I've added it this way to avoid a mess where all the files are listed at the root of the inspector.
**/
typedef struct{
    local int i = 0;
    for (i = 0; i < File.Header.FileCount; i++){
        Printf("Added %d files to the array...\n",i+1);
        FSeek(File.Header.File_Definitions[i].Offset);
        GDATFile file;
    }
} GDATFiles;


typedef struct {
    GDATHeader Header;
    GDATFiles Files;
} GDAT <read=DisplayFileCount>;


string DisplayFileCount(GDAT &input){
    string s;
    SPrintf(s,"%d Files",input.Header.FileCount);
    return s;
}

string DisplayFileType(GDATFile &input){
    string s;
    local char reversed[4];
    local int i;
    for (i = 3; i > -1; i--)
    {
        reversed[3-i] = input.MAGIC[i];
    }
    if (reversed[1] == '\0'){
        SPrintf(s,"Unknown File");
    }
    else{
    SPrintf(s,"%s File",reversed);
    }
    return s;
}

GDAT File;
Printf("%d Files were found in this GDAT file\n", File.Header.FileCount);




 

  • Author
2 hours ago, h3x3r said:
//------------------------------------------------
//--- 010 Editor v10.0.2 Binary Template
//
//  File: OrochiDAT.bt
//  Authors: SeleDreams
//  Version: 0.2
//  Purpose: Analyzing Silicon Studio's Orochi / Mizuchi Engine data archiving format
//  Category: Archive
//  File Mask: GxArchivedFile???.dat
//  ID Bytes: 47 44 41 54
//  History: 
//   0.2   2020-05-08 SeleDreams: Implemented a feature allowing to see the file formats
//   0.1   2020-05-06 SeleDreams: Initial Release
//------------------------------------------------

typedef struct{
        uint Offset;
        uint Length;
 } GDATFileDef;


typedef struct {
    char MAGIC[4];
    int FileCount;
    GDATFileDef File_Definitions[FileCount];
} GDATHeader;


typedef struct{
        char MAGIC[4];
        byte Data[File.Header.File_Definitions[i].Length - 4];
} GDATFile<read=DisplayFileType>;

/** 
*  - This structure is an array containing all the files in the order of their definition.
*  - I've added it this way to avoid a mess where all the files are listed at the root of the inspector.
**/
typedef struct{
    local int i = 0;
    for (i = 0; i < File.Header.FileCount; i++){
        Printf("Added %d files to the array...\n",i+1);
        FSeek(File.Header.File_Definitions[i].Offset);
        GDATFile file;
    }
} GDATFiles;


typedef struct {
    GDATHeader Header;
    GDATFiles Files;
} GDAT <read=DisplayFileCount>;


string DisplayFileCount(GDAT &input){
    string s;
    SPrintf(s,"%d Files",input.Header.FileCount);
    return s;
}

string DisplayFileType(GDATFile &input){
    string s;
    local char reversed[4];
    local int i;
    for (i = 3; i > -1; i--)
    {
        reversed[3-i] = input.MAGIC[i];
    }
    if (reversed[1] == '\0'){
        SPrintf(s,"Unknown File");
    }
    else{
    SPrintf(s,"%s File",reversed);
    }
    return s;
}

GDAT File;
Printf("%d Files were found in this GDAT file\n", File.Header.FileCount);




 

Do i have to use 010 Editor to run it?

Edited by GabryTheSniper

  • Supporter
  • Solution

Yes, but you can also rewrite it to the bms form.

Well he we go. But not sure how to reverse extension order for example "xet" > "tex" so extensions will be in reversed order. Nothing cardial...

Also no file names either. I bind offset as a file name.

############################################
#     Death end re:Quest 2 *.DAT files     #
############################################

get BaseFileName basename

idstring "GDAT"
get Files uint32

for i = 0 < Files
	get Offset uint32
	get RawSize uint32
	savepos EndTable
	
	goto Offset
	savepos ExtOffset
	get ExtCheck byte
	if ExtCheck == 0
		getdstring Extension 0x3
	else
		goto ExtOffset
		getdstring Extension 0x4
	endif
	getdstring Dummy 0x7C
	endian big
	getdstring CompressionSign 0x4
	get Size uint32
	get ZSize uint32
	get Unknown uint32
	endian little
	savepos Offset
	string Name p "%s/%u.%s" BaseFileName Offset Extension
	clog Name Offset ZSize Size
	goto EndTable
next i

 

Edited by h3x3r

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.