Raynegard game assets: Difference between revisions
From Raynegard Wiki
Jump to navigationJump to search
Add overview of the BIN and SSF asset container formats (via update-page on MediaWiki MCP Server) |
No edit summary |
||
| (One intermediate revision by one other user not shown) | |||
| Line 1: | Line 1: | ||
Raynegard's game data is distributed as many small files packed into a | Raynegard's game data is distributed as many small files packed into a custom .bin container/archive format. The client unpacks these at startup (or on demand) to load its text, images, sprites, maps, NPC/item data, and sound. | ||
*[[BIN files]] — the game's general-purpose archive format. Assets of a given category (text, sprites, maps, NPC data, etc.) are bundled in matched pairs of files: a small header file (e.g. <code>textdatah.bin</code>) and the packed data file (<code>textdata.bin</code>). The header is just a flat list of <code>(offset, size)</code> entries, one per packed file, with no padding or alignment between entries. Some archives ("directory-type") also store a self-referential file-name list as entry 0, so files can be looked up by name instead of index; others are accessed purely by numeric index. Contents are sometimes obfuscated with a simple repeating XOR cipher (key byte + increment, resetting per file) rather than real encryption. At startup the client loads about a dozen of these paired archives — <code>bitmapdata</code>, <code>cockpitdata</code>, <code>etcimage</code>, <code>mapdata</code>, <code>npcdata</code>, <code>palette</code>, <code>pattern</code>, <code>point</code>, <code>sedata</code>, <code>seqence</code>, <code>sprite</code>, <code>textdata</code>, <code>texture</code> — together covering nearly every non-executable asset category in the game. | *[[BIN files]] — the game's general-purpose archive format. Assets of a given category (text, sprites, maps, NPC data, etc.) are bundled in matched pairs of files: a small header file (e.g. <code>textdatah.bin</code>) and the packed data file (<code>textdata.bin</code>). The header is just a flat list of <code>(offset, size)</code> entries, one per packed file, with no padding or alignment between entries. Some archives ("directory-type") also store a self-referential file-name list as entry 0, so files can be looked up by name instead of index; others are accessed purely by numeric index. Contents are sometimes obfuscated with a simple repeating XOR cipher (key byte + increment, resetting per file) rather than real encryption. At startup the client loads about a dozen of these paired archives — <code>bitmapdata</code>, <code>cockpitdata</code>, <code>etcimage</code>, <code>mapdata</code>, <code>npcdata</code>, <code>palette</code>, <code>pattern</code>, <code>point</code>, <code>sedata</code>, <code>seqence</code>, <code>sprite</code>, <code>textdata</code>, <code>texture</code> — together covering nearly every non-executable asset category in the game. | ||
*[[SSF files]] — Raynegard's custom compressed audio format, | *[[SSF files]] — Raynegard's custom compressed audio format. Unlike the BIN archives, an <code>.ssf</code> file is not a container — each one holds a single sound effect or music track. It has a small header (channel count, sample rate, loop flag/loop point) followed by audio data encoded with a custom ADPCM-style compression scheme. Decoding walks the file block by block, reconstructing 16-bit PCM samples from packed nibbles and a small set of fixed prediction coefficients, so it can be converted losslessly-in-practice to a standard <code>.wav</code> for playback outside the game. | ||
Latest revision as of 12:53, 2 July 2026
Raynegard's game data is distributed as many small files packed into a custom .bin container/archive format. The client unpacks these at startup (or on demand) to load its text, images, sprites, maps, NPC/item data, and sound.
- BIN files — the game's general-purpose archive format. Assets of a given category (text, sprites, maps, NPC data, etc.) are bundled in matched pairs of files: a small header file (e.g.
textdatah.bin) and the packed data file (textdata.bin). The header is just a flat list of(offset, size)entries, one per packed file, with no padding or alignment between entries. Some archives ("directory-type") also store a self-referential file-name list as entry 0, so files can be looked up by name instead of index; others are accessed purely by numeric index. Contents are sometimes obfuscated with a simple repeating XOR cipher (key byte + increment, resetting per file) rather than real encryption. At startup the client loads about a dozen of these paired archives —bitmapdata,cockpitdata,etcimage,mapdata,npcdata,palette,pattern,point,sedata,seqence,sprite,textdata,texture— together covering nearly every non-executable asset category in the game. - SSF files — Raynegard's custom compressed audio format. Unlike the BIN archives, an
.ssffile is not a container — each one holds a single sound effect or music track. It has a small header (channel count, sample rate, loop flag/loop point) followed by audio data encoded with a custom ADPCM-style compression scheme. Decoding walks the file block by block, reconstructing 16-bit PCM samples from packed nibbles and a small set of fixed prediction coefficients, so it can be converted losslessly-in-practice to a standard.wavfor playback outside the game.