mirror of
https://github.com/zeldaret/oot.git
synced 2025-08-21 06:21:16 +00:00
Document Hud Mode (#1323)
* begin interface alpha docs * more progress/docs * First draft of docs done * cleanup * Consistency * Display -> Mode * Remaining display -> mode * Better docs * Small touchups * Small Update * Apply discord discussion * small fix * More discussions * PR Suggestions * Roman PR Suggestions * better comments * PR Suggestions * another suggestion * discord discussions * cleanup comments * more discord/pr suggestions
This commit is contained in:
parent
9bdf6ded2f
commit
9c35716fe2
28 changed files with 387 additions and 324 deletions
|
@ -391,7 +391,7 @@ void BgDyYoseizo_GreetPlayer_NoReward(BgDyYoseizo* this, PlayState* play) {
|
|||
|
||||
if ((this->dialogState == Message_GetState(&play->msgCtx)) && Message_ShouldAdvance(play)) {
|
||||
Message_CloseTextbox(play);
|
||||
Interface_ChangeAlpha(5);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_A_HEARTS_MAGIC_FORCE);
|
||||
this->actionFunc = BgDyYoseizo_SetupHealPlayer_NoReward;
|
||||
}
|
||||
|
||||
|
@ -712,7 +712,7 @@ void BgDyYoseizo_Give_Reward(BgDyYoseizo* this, PlayState* play) {
|
|||
gSaveContext.isMagicAcquired = true;
|
||||
gSaveContext.magicFillTarget = MAGIC_NORMAL_METER;
|
||||
// magicLevel is already 0, setting isMagicAcquired to true triggers magicCapacity to grow
|
||||
Interface_ChangeAlpha(9);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_HEARTS_MAGIC);
|
||||
break;
|
||||
case FAIRY_UPGRADE_DOUBLE_MAGIC:
|
||||
if (!gSaveContext.isMagicAcquired) {
|
||||
|
@ -722,11 +722,11 @@ void BgDyYoseizo_Give_Reward(BgDyYoseizo* this, PlayState* play) {
|
|||
gSaveContext.magicFillTarget = MAGIC_DOUBLE_METER;
|
||||
// Setting magicLevel to 0 triggers magicCapacity to grow
|
||||
gSaveContext.magicLevel = 0;
|
||||
Interface_ChangeAlpha(9);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_HEARTS_MAGIC);
|
||||
break;
|
||||
case FAIRY_UPGRADE_DOUBLE_DEFENSE:
|
||||
gSaveContext.isDoubleDefenseAcquired = true;
|
||||
Interface_ChangeAlpha(9);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_HEARTS_MAGIC);
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -760,7 +760,7 @@ void BgDyYoseizo_Give_Reward(BgDyYoseizo* this, PlayState* play) {
|
|||
|
||||
this->itemSpawned = true;
|
||||
gSaveContext.healthAccumulator = 0x140;
|
||||
Interface_ChangeAlpha(9);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_HEARTS_MAGIC);
|
||||
gSaveContext.itemGetInf[ITEMGETINF_18_19_1A_INDEX] |= sItemGetFlags[actionIndex];
|
||||
Item_Give(play, sItemIds[actionIndex]);
|
||||
}
|
||||
|
|
|
@ -785,7 +785,7 @@ void BossGanon_IntroCutscene(BossGanon* this, PlayState* play) {
|
|||
|
||||
if (this->csTimer == 20) {
|
||||
func_8002DF54(play, &this->actor, 0x17);
|
||||
Interface_ChangeAlpha(11); // show hearts only
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_HEARTS);
|
||||
}
|
||||
|
||||
if (this->csTimer == 25) {
|
||||
|
@ -793,7 +793,7 @@ void BossGanon_IntroCutscene(BossGanon* this, PlayState* play) {
|
|||
}
|
||||
|
||||
if (this->csTimer == 100) {
|
||||
Interface_ChangeAlpha(1);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_NOTHING);
|
||||
}
|
||||
|
||||
if (this->csTimer == 120) {
|
||||
|
|
|
@ -791,7 +791,7 @@ void BossMo_Tentacle(BossMo* this, PlayState* play) {
|
|||
case MO_TENT_SHAKE:
|
||||
if (this->timers[0] == 138) {
|
||||
Letterbox_SetSizeTarget(0);
|
||||
Interface_ChangeAlpha(0xB);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_HEARTS);
|
||||
}
|
||||
if ((this->timers[0] % 8) == 0) {
|
||||
play->damagePlayer(play, -1);
|
||||
|
|
|
@ -433,7 +433,7 @@ void func_80A79BAC(EnIn* this, PlayState* play, s32 index, u32 transitionType) {
|
|||
play->transitionType = transitionType;
|
||||
play->transitionTrigger = TRANS_TRIGGER_START;
|
||||
func_8002DF54(play, &this->actor, 8);
|
||||
Interface_ChangeAlpha(1);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_NOTHING);
|
||||
if (index == 0) {
|
||||
AREG(6) = 0;
|
||||
}
|
||||
|
@ -471,7 +471,7 @@ void func_80A79C78(EnIn* this, PlayState* play) {
|
|||
player->actor.freezeTimer = 10;
|
||||
this->actor.flags &= ~ACTOR_FLAG_0;
|
||||
Letterbox_SetSizeTarget(32);
|
||||
Interface_ChangeAlpha(2);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_NOTHING_ALT);
|
||||
}
|
||||
|
||||
static s32 D_80A7B998 = 0;
|
||||
|
@ -792,7 +792,7 @@ void func_80A7AA40(EnIn* this, PlayState* play) {
|
|||
this->unk_1FC = 0;
|
||||
play->csCtx.frames = 0;
|
||||
Letterbox_SetSizeTarget(32);
|
||||
Interface_ChangeAlpha(2);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_NOTHING_ALT);
|
||||
this->actionFunc = func_80A7ABD4;
|
||||
}
|
||||
|
||||
|
@ -857,7 +857,7 @@ void func_80A7AE84(EnIn* this, PlayState* play) {
|
|||
Play_ChangeCameraStatus(play, this->returnToCamId, CAM_STAT_ACTIVE);
|
||||
Play_ClearCamera(play, this->subCamId);
|
||||
func_8002DF54(play, &this->actor, 7);
|
||||
Interface_ChangeAlpha(0x32);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_ALL);
|
||||
this->actionFunc = func_80A7AEF0;
|
||||
}
|
||||
|
||||
|
|
|
@ -68,7 +68,7 @@ void EnMag_Init(Actor* thisx, PlayState* play) {
|
|||
this->effectFadeInState = this->effectPrimLodFrac = this->globalState = this->effectAlpha = this->mainAlpha =
|
||||
this->subAlpha = this->copyrightAlpha = 0.0f;
|
||||
|
||||
if (gSaveContext.unk_13E7 != 0) {
|
||||
if (gSaveContext.forceRisingButtonAlphas) {
|
||||
this->mainAlpha = 210;
|
||||
this->subAlpha = 255;
|
||||
this->copyrightAlpha = 255;
|
||||
|
@ -83,7 +83,7 @@ void EnMag_Init(Actor* thisx, PlayState* play) {
|
|||
this->effectEnvColor[1] = 255.0f;
|
||||
this->effectEnvColor[2] = 0;
|
||||
|
||||
gSaveContext.unk_13E7 = 0;
|
||||
gSaveContext.forceRisingButtonAlphas = false;
|
||||
this->globalState = MAG_STATE_DISPLAY;
|
||||
sDelayTimer = 20;
|
||||
gSaveContext.transFadeDuration = 1;
|
||||
|
|
|
@ -654,7 +654,7 @@ void EnOssan_EndInteraction(PlayState* play, EnOssan* this) {
|
|||
play->msgCtx.stateTimer = 4;
|
||||
player->stateFlags2 &= ~PLAYER_STATE2_29;
|
||||
Play_SetViewpoint(play, VIEWPOINT_LOCKED);
|
||||
Interface_ChangeAlpha(50);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_ALL);
|
||||
this->drawCursor = 0;
|
||||
this->stickLeftPrompt.isEnabled = false;
|
||||
this->stickRightPrompt.isEnabled = false;
|
||||
|
@ -1323,7 +1323,7 @@ void EnOssan_GiveItemWithFanfare(PlayState* play, EnOssan* this) {
|
|||
play->msgCtx.stateTimer = 4;
|
||||
player->stateFlags2 &= ~PLAYER_STATE2_29;
|
||||
Play_SetViewpoint(play, VIEWPOINT_LOCKED);
|
||||
Interface_ChangeAlpha(50);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_ALL);
|
||||
this->drawCursor = 0;
|
||||
EnOssan_UpdateCameraDirection(this, play, 0.0f);
|
||||
this->stateFlag = OSSAN_STATE_GIVE_ITEM_FANFARE;
|
||||
|
|
|
@ -181,7 +181,7 @@ void func_80B4B010(EnZl1* this, PlayState* play) {
|
|||
Play_CameraSetAtEye(play, this->subCamId, &subCamAt, &subCamEye);
|
||||
Play_CameraSetFov(play, this->subCamId, 30.0f);
|
||||
Letterbox_SetSizeTarget(32);
|
||||
Interface_ChangeAlpha(2);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_NOTHING_ALT);
|
||||
player->actor.world.pos = playerPos;
|
||||
player->actor.speedXZ = 0.0f;
|
||||
this->unk_1E2 = 0;
|
||||
|
@ -556,7 +556,7 @@ void func_80B4BF2C(EnZl1* this, PlayState* play) {
|
|||
case 6:
|
||||
if (Actor_TextboxIsClosing(&this->actor, play)) {
|
||||
func_8002DF54(play, &this->actor, 7);
|
||||
Interface_ChangeAlpha(50);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_ALL);
|
||||
this->actor.flags &= ~ACTOR_FLAG_8;
|
||||
this->unk_1E2 = 4;
|
||||
}
|
||||
|
|
|
@ -330,7 +330,7 @@ s32 EnZl4_SetupFromLegendCs(EnZl4* this, PlayState* play) {
|
|||
|
||||
EnZl4_SetActiveCamMove(play, 5);
|
||||
Letterbox_SetSizeTarget(32);
|
||||
Interface_ChangeAlpha(2);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_NOTHING_ALT);
|
||||
this->talkTimer2 = 0;
|
||||
return true;
|
||||
}
|
||||
|
@ -1150,7 +1150,7 @@ void EnZl4_Cutscene(EnZl4* this, PlayState* play) {
|
|||
this->mouthExpression = ZL4_MOUTH_SURPRISED;
|
||||
Audio_PlayFanfare(NA_BGM_APPEAR);
|
||||
EnZl4_SetActiveCamDir(play, 0);
|
||||
Interface_ChangeAlpha(2);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_NOTHING_ALT);
|
||||
Letterbox_SetSizeTarget(32);
|
||||
this->talkState = 0;
|
||||
this->csState++;
|
||||
|
@ -1194,7 +1194,7 @@ void EnZl4_Cutscene(EnZl4* this, PlayState* play) {
|
|||
case ZL4_CS_PLAN:
|
||||
if (EnZl4_CsMakePlan(this, play)) {
|
||||
func_8002DF54(play, &this->actor, 7);
|
||||
gSaveContext.unk_13EE = 0x32;
|
||||
gSaveContext.prevHudVisibilityMode = HUD_VISIBILITY_ALL;
|
||||
SET_EVENTCHKINF(EVENTCHKINF_40);
|
||||
this->actionFunc = EnZl4_Idle;
|
||||
}
|
||||
|
|
|
@ -5238,7 +5238,7 @@ void Fishing_UpdateOwner(Actor* thisx, PlayState* play2) {
|
|||
sSubCamAt.y = mainCam->at.y;
|
||||
sSubCamAt.z = mainCam->at.z;
|
||||
D_80B7A6CC = 2;
|
||||
Interface_ChangeAlpha(12);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_A_B_MINIMAP);
|
||||
sSubCamVelFactor = 0.0f;
|
||||
FALLTHROUGH;
|
||||
}
|
||||
|
|
|
@ -165,8 +165,10 @@ void ObjLift_Shake(ObjLift* this, PlayState* play) {
|
|||
ObjLift_SetupFall(this);
|
||||
} else {
|
||||
this->shakeOrientation.x += 10000;
|
||||
this->dyna.actor.world.rot.x = (s16)(Math_SinS(this->shakeOrientation.x) * 300.0f) + this->dyna.actor.home.rot.x;
|
||||
this->dyna.actor.world.rot.z = (s16)(Math_CosS(this->shakeOrientation.x) * 300.0f) + this->dyna.actor.home.rot.z;
|
||||
this->dyna.actor.world.rot.x =
|
||||
(s16)(Math_SinS(this->shakeOrientation.x) * 300.0f) + this->dyna.actor.home.rot.x;
|
||||
this->dyna.actor.world.rot.z =
|
||||
(s16)(Math_CosS(this->shakeOrientation.x) * 300.0f) + this->dyna.actor.home.rot.z;
|
||||
this->dyna.actor.shape.rot.x = this->dyna.actor.world.rot.x;
|
||||
this->dyna.actor.shape.rot.z = this->dyna.actor.world.rot.z;
|
||||
this->shakeOrientation.y += 18000;
|
||||
|
|
|
@ -34,7 +34,7 @@ ActorInit Shot_Sun_InitVars = {
|
|||
};
|
||||
|
||||
typedef enum {
|
||||
/* 0 */ SPAWNER_OUT_OF_RANGE ,
|
||||
/* 0 */ SPAWNER_OUT_OF_RANGE,
|
||||
/* 1 */ SPAWNER_OCARINA_START,
|
||||
/* 2 */ SPAWNER_OCARINA_PLAYING
|
||||
} FairySpawnerState;
|
||||
|
|
|
@ -3106,7 +3106,7 @@ void func_80835DE4(PlayState* play, Player* this, PlayerFunc674 func, s32 flags)
|
|||
void func_80835E44(PlayState* play, s16 camSetting) {
|
||||
if (!Play_CamIsNotFixed(play)) {
|
||||
if (camSetting == CAM_SET_SCENE_TRANSITION) {
|
||||
Interface_ChangeAlpha(2);
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_NOTHING_ALT);
|
||||
}
|
||||
} else {
|
||||
Camera_ChangeSetting(Play_GetCamera(play, CAM_ID_MAIN), camSetting);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue