From 7927e7b33007eee68375ca2b940b8d2aa4063406 Mon Sep 17 00:00:00 2001 From: fig02 Date: Sat, 24 Dec 2022 13:55:17 -0500 Subject: z_demo documentation (#1327) * commit old stuff * progress * progress * progress * progress * more progress, renaming cues next * small changes * enum values added for all actions * hardcoded values removed when possible * commands renamed * first pass of action -> cue * fix some matches * some more cleanup * scriptPtr * forgot one * remove cue rot union * more changes * some more stuff * more stuff * fix matching issues * some more things * progress, starting to rename destinations * small changes * name some destinations * more names * need to switch branch * progress * first pass of destination names * usages fixed * use destination enum * fix csdis * format * command descriptions * revert accidental zap changes * forgot some things * use a single macro for CutsceneCameraPoint (idk why i didnt think of this sooner) * typo * review1 * clarify ruby/sapphire comment * remove endframe for commands that dont use it * some more review * most review, but not all * scriptPtr -> script, and another small change * ocarina action * remove +1 from light settings command, change comment * actionIndex -> cueIdTemp (i guess) * _SetCueX -> _SetXFromCue * format * tweak fade out seq arg names * use spline terminology * more dragorn and engineer review * misc start/end frame note * cleanup StartPosRotFromCue vs PosRotFromCue * cleanup spline terminology * sPrevCamId -> sReturnToCamId * comment on debug cs data address * Cutscene_Init -> Cutscene_InitContext * single point types are not a list * remove todo comment * some more review * rumble struct names * some review * more review * missed one * reword pointer comment * even more review * match transition terminology with z_play * change condition and format * frame count * command specific structs with alignment * anon review * remove unneeded arg from time macro * yeet `CsCmdGeneric` * remove unused from single point types * typo * compromise attempt -- name endFrame everywhere * fixes * fix again * copied the wrong note * cutscene data note * review, format * compat defines * idk whats going on man Co-authored-by: Dragorn421 --- src/code/db_camera.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/code/db_camera.c') diff --git a/src/code/db_camera.c b/src/code/db_camera.c index 0c50abbc0..80a9eb58d 100644 --- a/src/code/db_camera.c +++ b/src/code/db_camera.c @@ -252,7 +252,7 @@ s32 func_800B4088(DbCamera* dbCamera, Camera* cam) { position = &dbCamera->sub.position[dbCamera->sub.unkIdx]; lookAt = &dbCamera->sub.lookAt[dbCamera->sub.unkIdx]; - position->continueFlag = -1; + position->continueFlag = CS_CAM_STOP; lookAt->continueFlag = position->continueFlag; position->nextPointFrame = 0; lookAt->nextPointFrame = 30; @@ -268,10 +268,10 @@ s32 func_800B4088(DbCamera* dbCamera, Camera* cam) { } for (i = 0; i < (dbCamera->sub.nPoints - 2); i++) { - dbCamera->sub.position[i].continueFlag = dbCamera->sub.lookAt[i].continueFlag = 0; + dbCamera->sub.position[i].continueFlag = dbCamera->sub.lookAt[i].continueFlag = CS_CAM_CONTINUE; } - dbCamera->sub.position[i].continueFlag = dbCamera->sub.lookAt[i].continueFlag = -1; + dbCamera->sub.position[i].continueFlag = dbCamera->sub.lookAt[i].continueFlag = CS_CAM_STOP; return dbCamera->sub.unkIdx; } @@ -299,7 +299,7 @@ s32 func_800B42C0(DbCamera* dbCamera, Camera* cameraPtr) { CutsceneCameraPoint* position = &dbCamera->sub.position[dbCamera->sub.unkIdx]; CutsceneCameraPoint* lookAt = &dbCamera->sub.lookAt[dbCamera->sub.unkIdx]; - position->continueFlag = lookAt->continueFlag = 0; + position->continueFlag = lookAt->continueFlag = CS_CAM_CONTINUE; if (dbCamera->sub.mode != 1) { DbCamera_Vec3FToS(&dbCamera->eye, &position->pos); @@ -352,10 +352,10 @@ void func_800B44E0(DbCamera* dbCamera, Camera* cam) { sDbCamAnim.unk_04 = 0; for (i = 0; i < (dbCamera->sub.nPoints - 2); i++) { - dbCamera->sub.position[i].continueFlag = dbCamera->sub.lookAt[i].continueFlag = 0; + dbCamera->sub.position[i].continueFlag = dbCamera->sub.lookAt[i].continueFlag = CS_CAM_CONTINUE; } - dbCamera->sub.position[i].continueFlag = dbCamera->sub.lookAt[i].continueFlag = -1; + dbCamera->sub.position[i].continueFlag = dbCamera->sub.lookAt[i].continueFlag = CS_CAM_STOP; } if (dbCamera->sub.nPoints < 6) { @@ -2155,7 +2155,7 @@ s32 DbCamera_UpdateDemoControl(DbCamera* dbCamera, Camera* cam) { } if (CHECK_BTN_ALL(sPlay->state.input[1].press.button, BTN_CRIGHT)) { - D_8015FCC8 = 0; + gUseCutsceneCam = false; gSaveContext.cutsceneIndex = 0xFFFD; gSaveContext.cutsceneTrigger = 1; sDbCamAnim.curFrame = 0.0f; -- cgit v1.2.3