PAT file: Difference between revisions

From NeoGeo Development Wiki
Jump to navigation Jump to search
m (2 revisions: Import from wikkii)
Line 11: Line 11:


*Patch address (in bytes, all the $0000~$FFFF range seems to work)
*Patch address (in bytes, all the $0000~$FFFF range seems to work)
*First data word, written to address (/2) ?
 
*Second data word, written to address+2 (/2)-1 ?
*First data word is (/2), byteswapped and written to address
*Third optional data word, written to address+5 (/2) ?
*Second data word is (/2)-1, byteswapped written to address+2
*Fourth optional data word, written to address+7 (/2)-1 ?
*Third (optional) data word is (/2), byteswapped and written to address+4
*Fourth (optional) data word is (/2)-1, byteswapped written to address+6
 
If third data word is 0x0000 both the third and forth patches are skipped.


[[Category:CD systems]]
[[Category:CD systems]]

Revision as of 09:05, 4 November 2012

PAT files contain structured data to patch already loaded Z80 code. They're used to replace sound samples addresses originally loaded from Z80 files when different PCM files are used.

  • Maximum file size: ?
  • Type code: 5
  • Loadable in: Z80 RAM
  • Banks: 1

Format

Blocks of 5, 16bit values:

  • Patch address (in bytes, all the $0000~$FFFF range seems to work)
  • First data word is (/2), byteswapped and written to address
  • Second data word is (/2)-1, byteswapped written to address+2
  • Third (optional) data word is (/2), byteswapped and written to address+4
  • Fourth (optional) data word is (/2)-1, byteswapped written to address+6

If third data word is 0x0000 both the third and forth patches are skipped.