This documents the `unk_02054BD0.c` file, which is in charge of loading
the terrain attributes from the land data NARC for some map load modes,
separately from the land data manager.
Signed-off-by: Kuruyia <github@kuruyia.net>
This identifies the generic pointer declared in the field system struct
used by map with dynamic features to store their own data about the
state of those features.
Signed-off-by: Kuruyia <github@kuruyia.net>
This documents the `unk_02054D00.c` file, which is in charge of managing
height, collision and tile behavior between the terrain and the
player/map objects.
Signed-off-by: Kuruyia <github@kuruyia.net>
This documents the `ov5_021EF250.c` file, which is in charge of managing
terrain features whose height can change.
Examples include the water floor of Pastoria Gym, and the various lift
platforms in the game (in Iron Island, the Pokémon League...).
Signed-off-by: Kuruyia <github@kuruyia.net>
This documents the `ov5_021E779C.c` file, which is in charge of loading
map data from the `land_data.narc` archive, dynamically load and unload
maps as the player moves, and render the map base models and their
props.
Also, for the viewer's pleasure, it includes a ton of Distortion
World-specific functions.
This also documents the `ov5_021EEAC8.c` file, which is in charge of
managing buffer allocation for the map base model and BDHC data.
Signed-off-by: Kuruyia <github@kuruyia.net>
This documents the `ov5_021D521C.c` file, which is in charge of managing
lighting according to the currently loaded map area and the current
wall-clock time.
Signed-off-by: Kuruyia <github@kuruyia.net>
This documents the `ov5_021D5878.c` file, which manages a data structure
containing various attributes used when rendering 3D models.
Those attributes directly map to polygon attributes/parameters that are
exposed by the NDS 3D hardware.
Signed-off-by: Kuruyia <github@kuruyia.net>
This documents the `ov5_021D37AC.c` file, which is in charge of managing
the animations on map props.
The map prop animation code is actually split into two separate
managers:
* The `MapPropAnimationManager`, which is in charge of loading animation
data from the two related NARC files, and managing long-running
animations (e.g. Valley Windworks windmills, Fuego Ironworks furnace,
Veilstone Game Corner lights...)
* The `MapPropOneShotAnimationManager`, which is in charge of loading
and playing "one shot" animations (e.g. any door opening/closing, the
Pokémon Center stairs...)
Signed-off-by: Kuruyia <github@kuruyia.net>
This documents the `ov5_021EF75C.c` file, which is in charge of loading
various "area data" NARCs that, in the end, contain the textures of
maps, the textures and models of map props, and lighting information.
Also, renamed `MapProp.id` to `MapProp.modelID` for more clarity
(especially when interacting with the new area data functions).
Signed-off-by: Kuruyia <github@kuruyia.net>
This mainly documents the `ov5_021E15F4.c` file, which is in charge of
reading map props from the land data NARC, managing them, and rendering
them.
A "map prop" is defined here as a 3D model that is separate from the map
3D model, and that can be positioned, rotated, and scaled independently.
For instance, they are usually used to place buildings on the various
maps.
Signed-off-by: Kuruyia <github@kuruyia.net>
Documents honey_tree. Mostly. There are some functions related to the overworld tree shaking animation that I didn't document, but it's at least contextually obvious what the end result is.
Also might have a bit of roamer stuff, idk, this commit was sitting for 2 weeks