Difference between revisions of "Sonic Adventure 2/Level Data Formats"
From Sonic Retro
MainMemory (talk | contribs) m (→COL Format) |
MainMemory (talk | contribs) m (→COL Format) |
||
Line 71: | Line 71: | ||
| Surface Flags (see below) | | Surface Flags (see below) | ||
|} | |} | ||
+ | |||
+ | Note: non-solid models use the Chunk Model ("SA2 format"), while solid models use the Basic Model ("SA1 format"). | ||
===Surface Flags=== | ===Surface Flags=== | ||
These flags are not entirely figured out yet, but here's what is known for sure:<br /> | These flags are not entirely figured out yet, but here's what is known for sure:<br /> | ||
− | + | 0x00000001 = Solid<br /> | |
− | 0x00000002 = Water (overrides solid flag, makes surface transparent)<br /> | + | <!--0x00000002 = Water (overrides solid flag, makes surface transparent)<br /> |
0x00000004 = No Friction<br /> | 0x00000004 = No Friction<br /> | ||
0x00000008 = No Acceleration<br /> | 0x00000008 = No Acceleration<br /> |
Revision as of 11:04, 18 October 2012
SCHG: Sonic Adventure 2 | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
Dreamcast GameCube PC | ||||||||||||
|
LandTable header format
This struct defines the number of models and animations in the level, the location of the corresponding lists, and the texture list used. The name comes from the label in the DLL Export table of various DLLs in the PC version of Sonic Adventure DX.
Offset | Type | Description |
---|---|---|
0 | Short | COL Count |
2 | Short | Anim Count? |
4 | Int? | Unknown |
8 | Int? | Unknown |
C | Float | Unknown, usually 3000 |
10 | Pointer | COL List |
14 | Pointer? | Anim List? |
18 | Pointer | Texture file name. Optional.
If not null, a PVM with this name will be loaded to the address pointed to by the texture list pointer. |
1C | Pointer | Texture List |
COL Format
The name COL is an antiquated misnomer, but for lack of a better name, it stuck. This data struct is a reference for loading a level model. It's 0x20 bytes long and works as follows:
Offset | Type | Description |
---|---|---|
0 | Float[3] | Center of collision sphere |
C | Float | Radius of collision sphere |
10 | Pointer | Model (OBJECT Struct) |
14 | 8 Bytes | Padding? |
1C | Int | Surface Flags (see below) |
Note: non-solid models use the Chunk Model ("SA2 format"), while solid models use the Basic Model ("SA1 format").
Surface Flags
These flags are not entirely figured out yet, but here's what is known for sure:
0x00000001 = Solid
0x80000000 = Visible