EvilEngine/LODT: Difference between revisions

From Heavy Iron Modding
Battlepedia>Seil
No edit summary
(Created page with "{{AssetInfobox |subtitle=LOD Table |type=Binary |games=Battle for Bikini Bottom<br>The SpongeBob SquarePants Movie<br>The Incredibles<br>Rise of the Underminer}} A '''LOD...")
(No difference)

Revision as of 20:10, 28 March 2021

LODT
LOD Table
TypeBinary
Games usedThe Incredibles

A LOD table defines how models should look based on their distances from the in-game camera. A model can have up to 4 levels of detail, each level being a separate version of the model, spaced at increasing distances from the camera. Once the maximum distance is reached, the model starts fading out of view.

Format

The asset data starts with an int which defines the amount of entries in the LOD table, then the entries themselves. Each entry has the following format:

Offset Type Description
0x00 AssetID (Model) Model
0x04 float Max Distance from the camera before it starts fading out.
0x08 AssetID (Model) LOD1 Model (optional)
0x0C AssetID (Model) LOD2 Model (optional)
0x10 AssetID (Model) LOD3 Model (optional)
0x14 float LOD1 Distance from camera
0x18 float LOD2 Distance from camera
0x1C float LOD3 Distance from camera