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/code_8006C3A0.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'src/code/code_8006C3A0.c') diff --git a/src/code/code_8006C3A0.c b/src/code/code_8006C3A0.c index 8943d8b93..0057128e2 100644 --- a/src/code/code_8006C3A0.c +++ b/src/code/code_8006C3A0.c @@ -1,33 +1,33 @@ #include "global.h" -void Flags_UnsetAllEnv(PlayState* play) { +void CutsceneFlags_UnsetAll(PlayState* play) { u8 i; - for (i = 0; i < ARRAY_COUNT(play->envFlags); i++) { - play->envFlags[i] = 0; + for (i = 0; i < ARRAY_COUNT(play->cutsceneFlags); i++) { + play->cutsceneFlags[i] = 0; } } -void Flags_SetEnv(PlayState* play, s16 flag) { +void CutsceneFlags_Set(PlayState* play, s16 flag) { s16 index = flag / 16; s16 bit = flag % 16; s16 mask = 1 << bit; - play->envFlags[index] |= mask; + play->cutsceneFlags[index] |= mask; } -void Flags_UnsetEnv(PlayState* play, s16 flag) { +void CutsceneFlags_Unset(PlayState* play, s16 flag) { s16 index = flag / 16; s16 bit = flag % 16; s16 mask = (1 << bit) ^ 0xFFFF; - play->envFlags[index] &= mask; + play->cutsceneFlags[index] &= mask; } -s32 Flags_GetEnv(PlayState* play, s16 flag) { +s32 CutsceneFlags_Get(PlayState* play, s16 flag) { s16 index = flag / 16; s16 bit = flag % 16; s16 mask = 1 << bit; - return play->envFlags[index] & mask; + return play->cutsceneFlags[index] & mask; } -- cgit v1.2.3