mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-04 15:04:31 +00:00
Doc dodongo's cavern stuff (#1019)
* Document `func_80033480` more * More doc in `BgDdanKd` * WIP Document BgDodoago The dodongo skull light-eyes-with-bomb puzzle Some TODOs, jank/legacy code which I'm unsure if it achieves something significant * Finish documenting BgDodoago * `BgDodoago_WaitExplosives_` -> `BgDodoago_WaitExplosives` * Run formatter * `dlistBuffer` -> `displayListHead`
This commit is contained in:
parent
037c1dcad6
commit
05b2cbfc60
8 changed files with 178 additions and 149 deletions
|
@ -3159,7 +3159,8 @@ void Actor_SpawnFloorDustRing(GlobalContext* globalCtx, Actor* actor, Vec3f* pos
|
|||
}
|
||||
}
|
||||
|
||||
void func_80033480(GlobalContext* globalCtx, Vec3f* arg1, f32 arg2, s32 arg3, s16 arg4, s16 scaleStep, u8 arg6) {
|
||||
void func_80033480(GlobalContext* globalCtx, Vec3f* posBase, f32 randRangeDiameter, s32 amountMinusOne, s16 scaleBase,
|
||||
s16 scaleStep, u8 arg6) {
|
||||
Vec3f pos;
|
||||
Vec3f velocity = { 0.0f, 0.0f, 0.0f };
|
||||
Vec3f accel = { 0.0f, 0.3f, 0.0f };
|
||||
|
@ -3167,12 +3168,12 @@ void func_80033480(GlobalContext* globalCtx, Vec3f* arg1, f32 arg2, s32 arg3, s1
|
|||
u32 var2;
|
||||
s32 i;
|
||||
|
||||
for (i = arg3; i >= 0; i--) {
|
||||
pos.x = arg1->x + ((Rand_ZeroOne() - 0.5f) * arg2);
|
||||
pos.y = arg1->y + ((Rand_ZeroOne() - 0.5f) * arg2);
|
||||
pos.z = arg1->z + ((Rand_ZeroOne() - 0.5f) * arg2);
|
||||
for (i = amountMinusOne; i >= 0; i--) {
|
||||
pos.x = posBase->x + ((Rand_ZeroOne() - 0.5f) * randRangeDiameter);
|
||||
pos.y = posBase->y + ((Rand_ZeroOne() - 0.5f) * randRangeDiameter);
|
||||
pos.z = posBase->z + ((Rand_ZeroOne() - 0.5f) * randRangeDiameter);
|
||||
|
||||
scale = (s16)((Rand_ZeroOne() * arg4) * 0.2f) + arg4;
|
||||
scale = (s16)((Rand_ZeroOne() * scaleBase) * 0.2f) + scaleBase;
|
||||
var2 = arg6;
|
||||
|
||||
if (var2 != 0) {
|
||||
|
|
|
@ -21,6 +21,8 @@
|
|||
#include "scenes/indoors/miharigoya/miharigoya_scene.h"
|
||||
#include "scenes/dungeons/ice_doukutu/ice_doukutu_scene.h"
|
||||
|
||||
#include "overlays/actors/ovl_Bg_Dodoago/z_bg_dodoago.h"
|
||||
|
||||
#define ENTRANCE(scene, spawn, continueBgm, displayTitleCard, fadeIn, fadeOut) \
|
||||
{ \
|
||||
scene, spawn, \
|
||||
|
@ -1025,11 +1027,11 @@ void* sDCLavaFloorTextures[] = {
|
|||
gDCLavaFloor5Tex, gDCLavaFloor6Tex, gDCLavaFloor7Tex, gDCLavaFloor8Tex,
|
||||
};
|
||||
|
||||
// Scene Draw Config 20
|
||||
// Scene Draw Config 20 - Dodongo's Cavern
|
||||
void func_80099878(GlobalContext* globalCtx) {
|
||||
u32 gameplayFrames;
|
||||
s32 pad;
|
||||
Gfx* displayListHead = Graph_Alloc(globalCtx->state.gfxCtx, 6 * sizeof(Gfx));
|
||||
Gfx* displayListHead = Graph_Alloc(globalCtx->state.gfxCtx, 2 * sizeof(Gfx[3]));
|
||||
|
||||
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_scene_table.c", 4905);
|
||||
|
||||
|
@ -1053,11 +1055,12 @@ void func_80099878(GlobalContext* globalCtx) {
|
|||
|
||||
gSPSegment(POLY_OPA_DISP++, 0x0B, displayListHead);
|
||||
gDPPipeSync(displayListHead++);
|
||||
gDPSetEnvColor(displayListHead++, 255, 255, 255, globalCtx->roomCtx.unk_74[0]);
|
||||
gDPSetEnvColor(displayListHead++, 255, 255, 255, globalCtx->roomCtx.unk_74[BGDODOAGO_EYE_LEFT]);
|
||||
gSPEndDisplayList(displayListHead++);
|
||||
|
||||
gSPSegment(POLY_OPA_DISP++, 0x0C, displayListHead);
|
||||
gDPPipeSync(displayListHead++);
|
||||
gDPSetEnvColor(displayListHead++, 255, 255, 255, globalCtx->roomCtx.unk_74[1]);
|
||||
gDPSetEnvColor(displayListHead++, 255, 255, 255, globalCtx->roomCtx.unk_74[BGDODOAGO_EYE_RIGHT]);
|
||||
gSPEndDisplayList(displayListHead);
|
||||
|
||||
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_scene_table.c", 4956);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue