BNK Wildfire: Difference between revisions

From XentaxWiki
Jump to navigation Jump to search
No edit summary
imported>WATTO
Line 9: Line 9:


<tt><b>
<tt><b>
byte {X}&nbsp;&nbsp;&nbsp;&nbsp; - File Data <br>  
<font color="blue"> ''' // FILE DATA ''' </font> <br>
: <font color="blue"> ''' // for each file ''' </font> <br>
:: byte {X}&nbsp;&nbsp;&nbsp;&nbsp; - File Data <br>  
<br>
<br>
<font color="blue"> ''' // Directory ''' </font> <br>  
<font color="blue"> ''' // DIRECTORY ''' </font> <br>  
: <font color="blue"> ''' // for each file ''' </font> <br>  
: <font color="blue"> ''' // for each file ''' </font> <br>  
:: char {32}&nbsp;&nbsp;&nbsp; - Filename <font color="purple">(null terminated, then filled with junk)</font> <br>  
:: char {32}&nbsp;&nbsp;&nbsp; - Filename <font color="purple">(null terminated, filled with junk)</font> <br>  
:: uint32 {4}&nbsp;&nbsp; - Length of the data to EOF from current file's start <br>  
:: uint32 {4}&nbsp;&nbsp; - File Offset relative to the end of the archive. (ie FileOffset=ArchiveSize-ThisField) <br>  
:: uint32 {4}&nbsp;&nbsp; - File Length <br>  
:: uint32 {4}&nbsp;&nbsp; - File Length <br>  
:: uint32 {4}&nbsp;&nbsp; - '' <font color="red">Unknown</font> '' <br>
:: uint32 {4}&nbsp;&nbsp; - <font color="red"> '' Unknown '' </font> <br>  
:: uint32 {4}&nbsp;&nbsp; - '' <font color="red">Unknown</font> '' <br>
:: uint32 {4}&nbsp;&nbsp; - <font color="red"> '' Unknown '' </font> <br>  
<br>
char {8}&nbsp;&nbsp;&nbsp;&nbsp; - Footer <font color="purple">(Wildfire)</font> <br>
uint32 {4}&nbsp;&nbsp; - null <br>
uint16 {2}&nbsp;&nbsp; - '' <font color="red">Version? <font color="purple">(1)</font></font> '' <br>
uint32 {4}&nbsp;&nbsp; - Number of files <br>
<br>
<br>
<br>
<font color="blue"> ''' // ARCHIVE FOOTER ''' </font> <br>
: char {8}&nbsp;&nbsp;&nbsp;&nbsp; - Header <font color="purple">(Wildfire)</font> <br>
: uint32 {4}&nbsp;&nbsp; - null <br>
: uint16 {2}&nbsp;&nbsp; - Version <font color="purple">(1)</font> <br>
: uint32 {4}&nbsp;&nbsp; - Number Of Files <br>
</b></tt>
</b></tt>



Revision as of 08:04, 20 December 2005

BNK

  • Format Type : Archive
  • Endian Order : Little Endian
  • Date Posted : Dec. 5, 2005


Format Specifications

// FILE DATA

// for each file
byte {X}     - File Data


// DIRECTORY

// for each file
char {32}    - Filename (null terminated, filled with junk)
uint32 {4}   - File Offset relative to the end of the archive. (ie FileOffset=ArchiveSize-ThisField)
uint32 {4}   - File Length
uint32 {4}   - Unknown
uint32 {4}   - Unknown


// ARCHIVE FOOTER

char {8}     - Header (Wildfire)
uint32 {4}   - null
uint16 {2}   - Version (1)
uint32 {4}   - Number Of Files

MultiEx BMS Script

GoTo EOF 0 ;
SavePos TOFF 0 ;
Set TEMP Long TOFF ;
Math TEMP -= 3 ;
GoTo TEMP 0 ;
Get FILENUM Long 0 ;
Set FILENUMX Long FILENUM ;
Math FILENUMX *= 48 ;
Math FILENUMX += 17 ;
Set TEMP Long TOFF ;
Math TEMP -= FILENUMX ;
GoTo TEMP 0 ;
For X = 1 To FILENUM ;
GetDString FNAME 32 0 ;
Get TEMP Long 0 ;
Set FOFFSET Long TOFF ;
Math FOFFSET -= TEMP ;
Math FOFFSET += 1 ;
Get FSIZE Long 0 ;
Get FOOBAR Long 0 ;
Get FOOBAR Long 0 ;
Log FNAME FOFFSET FSIZE 0 0 ;
Next X ;

Supported by Programs