Changes

Jump to navigation Jump to search

FF7/Field Module

82 bytes added, 02:46, 13 July 2019
no edit summary
The Field module loads modular "Field Files". In the PC version, the Field File is a single file with nine sections. In the PSX version, there are three files with the same name but with different extensions that do the same thing. The three files are MIM (Mutiple Image Maps, or the backgrounds), DAT (Field Script Data), and BSX (3D data).
<div class="thumb tright"><div class="thumbinner" style="width: 182px">[[File:Field_BackgroundVRAMField BackgroundVRAM.jpg|[[Image:180px-Field_BackgroundVRAM.jpg]]]]<div class="thumbcaption"><div class="magnify">[[File:Field_BackgroundVRAMField BackgroundVRAM.jpg|[[Image:magnify-clip.png]]]]</div>Snapshot of the PSX's VRAM demonstrating the background field files in various stages of assembly.</div></div></div>
The backgrounds are actually 16x16 blocks that are loaded into VRAM and then assembled into the video buffer every frame. The system allows for layers to obscure the 3D entities using a simple painter's algorithm.
=== PSX DAT Format ===
The PSX script is contained in the DAT file, it is compressed with [[FF7/LZS_format|LZS compression]]. The first 4 bytes of the compressed DAT file is the length of the compressed data starting at address 0x4.
The header for the DAT file (after it is decompressed), is 28 bytes in size (they are used in the PSX, it's a list of 7 long word values which point to locations in PSX RAM). So for each of these sections are addressable by taking the first memory location subtracting it and adding 28.
There are 7 sections each coresponding corresponding to the first 7 memory locations at the begining beginning of the file.
{| class="wikitable"

Navigation menu