Changes

Jump to navigation Jump to search

FF7/Field Module/DAT/Tile Map

571 bytes added, 13:44, 27 May 2010
no edit summary
==Background Tile Map== --[[User:Cyberman|Cyberman]] 17:17, 27 Nov 2006 (CST) & --[[User:Myst6re|Myst6re]] 06:44, 27 May 2010 (EDT)The background tile map information on the PSX is actually stored in 2 files. The graphic tiles are in a MIM file with the same name as the DAT file. Both are needed to view the background data completely. This section covers just the Tile Map information and not how to decode the MIM data. The Tile Map consists of 4 5 subsections. The header for the tile map consists of 4 offsets which are relative to the begining of the section. The first section always starts at offset 0x0010, it is not in the header.
{| border="0" cellspacing="1" cellpadding="3" style="background: rgb(0,0,0)" align="center"
|style="background:rgb(255,255,255)" | 0x0000
|style="background:rgb(255,255,255)" | DWORD
|style="background:rgb(255,255,255)" | Object Meta Data1st layer Information (Section 2)
|-
|style="background:rgb(255,255,255)" | 0x0004
|style="background:rgb(255,255,255)" | DWORD
|style="background:rgb(255,255,255)" | 1st layer InformationTexture Page Data (Section 3)
|-
|style="background:rgb(255,255,255)" | 0x0008
|style="background:rgb(255,255,255)" | DWORD
|style="background:rgb(255,255,255)" | Texture Page DataSprite Layer Information (Section 4)
|-
|style="background:rgb(255,255,255)" | 0x000C
|style="background:rgb(255,255,255)" | DWORD
|style="background:rgb(255,255,255)" | Sprite 3th Layer Information(Section 5)
|}
===Section 1===
A list of data structures (size == 12 6 or 2 bytes). The first UINT16 indicates layer or not a layer.
struct {
UINT16 Type;
UINT32 ZZ1; UINT32 ZZ2UINT16 TilePos;
UINT16 TileCount;
} Section1LayerChange;
UINT8 TexPageSourceX;
UINT8 TexPageSourceY;
UINT16 TileDataTileClutData;
} Layer1Tile;
Destination X and Y are signed, this is used for the walkmesh information and the center of the background field.
unsigned ClutNumber;
unsigned ZZ2:6;
} TileDataTileClutData;
===Section 3===
UINT16 TileClutData;
UINT16 SpriteTP_Blend;
UINT8 UINT16 Group; // 4 12 lsb bits only UINT8 LayerParameter; UINT8 State;
} SpriteTile;
Destination X and Y are signed, this is used for the walkmesh information and the center of the background field.
Sprite Texture Page and Blending Mode data
{
unsigned ZZ:97; unsigned deph:2;
unsigned blending_mode:2;
unsigned page_y:1;
unsigned page_x:4;
} SpriteTP_Blend;
 
Parameter structure
{
unsigned blending:1; // MSB
unsigned param_id:7; // LSB
} Parameter;
 
===Section 5===
This section looks like section 4, it is used for additional layers.
struct {
INT16 DestinationX;
INT16 DestinationY;
UINT8 TexPageSourceX;
UINT8 TexPageSourceY;
UINT16 TileClutData;
UINT16 SpriteTP_Blend;
} SpriteTile2;
Anonymous user

Navigation menu