LVB: Difference between revisions
Owen-Splat (talk | contribs) (Add documentation for LVB files) |
(No difference)
|
Revision as of 15:57, 26 January 2023
LVB is a custom format used to store level data in Link's Awakening. This includes things such as the rooms IDs, a list of tagPlayerStart actors, and more. This format is still in the process of being reverse engineered and so this page is currently incomplete.
Note that many properties in these files define measurements in 3D space (X, Y, Z). X is horizontal across the screen, Y is perpendicular to the ground (the axis on which gravity acts), and Z is vertical across the screen.
Format
LVB files are in a FixedHash format
Entries Section
There are 8 entries in most LVB files.
Node Section
This is a FixedHashed child. Not yet understood.
Area Section
This is a FixedHashed child. Not yet understood.
Zone Section
This is a FixedHashed child. The first 4 bytes in each entry here are the room IDs
tagPlayerStart Section
This is a FixedHashed child. There is an entry for every tagPlayerStart actor, with the entry name being the room.
Offset | Type | Description |
---|---|---|
0x0 | float[3] | Co-ordinates as [X, Y, Z]. One in-game "tile" is 1.5 units.
The co-ordinate system spans entire maps and is not specific to each room. [0, 0, 0] is the very top left corner of the map, at the elevation of the main floor plane of the map. Each room is 10x8 tiles, so they span 15 units along the X axis and 12 along the Z axis. |
staticObject Section
This is a FixedHashed child. Not yet understood.
Condition Section
Not yet understood.
Config Section
Holds 7 bytes of data. The last 5 bytes always seem to be x00\x00\x00\x00\xff. Only the first 2 bytes seem to change, and there does appear to be a pattern with room types.
Version Section
Holds 3 bytes of data, which seem to always be 0x100182. Given the name, it's probably just a version marker and has no functional purpose.