1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-20 22:11:16 +00:00

Document Sub-Cameras (#989)

* Copying SubCam Changes from PR 908, made it to the end of bosses

* Finish copying over PR

* format

* More cleanup

* clean-up

* PR Suggestions, Clean-Up, Improvement in CS

* Remove substructs from fd/fd2

* format

* Improve fishing

* minor fix

* Make CutsceneCameraDir more general

* `sActiveCamMove` -> `sCamMove`

* Fix conflict with object kankyo

* Add CAM_ID_MAIN to object_kankyo

* Improve cam cutscenes further

* Revert cutscene cmd names (better for a separate PR)

* At -> LookAt in the context of Cutscenes

* Missed naming in diving game

* Format

* Fill in Ganon2 Names (now that it's matching)

* format

* `sActiveCamId` -> `sReturnToCamId`

* activeCamId -> returnToCamId

* Discord Discussions

* FIRST

* Move macro to bottom, comments

* More suggestions

* PR suggestion, cleanup comment

* Oops

* add comments

* Adjust comment

* Change edge-case

* whoops

Co-authored-by: fig02 <fig02srl@gmail.com>
This commit is contained in:
engineer124 2022-05-13 04:35:31 +10:00 committed by GitHub
parent 92aef346f2
commit bf56c94f0f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
143 changed files with 2778 additions and 2768 deletions

View file

@ -420,7 +420,7 @@ void func_80A3F0E4(EnGo* this) {
s32 EnGo_IsCameraModified(EnGo* this, GlobalContext* globalCtx) {
f32 xyzDistSq;
s16 yawDiff = this->actor.yawTowardsPlayer - this->actor.shape.rot.y;
Camera* camera = globalCtx->cameraPtrs[MAIN_CAM];
Camera* mainCam = globalCtx->cameraPtrs[CAM_ID_MAIN];
if (fabsf(yawDiff) > 10920.0f) {
return 0;
@ -428,13 +428,13 @@ s32 EnGo_IsCameraModified(EnGo* this, GlobalContext* globalCtx) {
xyzDistSq = (this->actor.scale.x / 0.01f) * 10000.0f;
if ((this->actor.params & 0xF0) == 0x90) {
Camera_ChangeSetting(camera, CAM_SET_DIRECTED_YAW);
Camera_ChangeSetting(mainCam, CAM_SET_DIRECTED_YAW);
xyzDistSq *= 4.8f;
}
if (fabsf(this->actor.xyzDistToPlayerSq) > xyzDistSq) {
if (camera->setting == CAM_SET_DIRECTED_YAW) {
Camera_ChangeSetting(camera, CAM_SET_NORMAL0);
if (mainCam->setting == CAM_SET_DIRECTED_YAW) {
Camera_ChangeSetting(mainCam, CAM_SET_NORMAL0);
}
return 0;
} else {
@ -774,7 +774,7 @@ void EnGo_CurledUp(EnGo* this, GlobalContext* globalCtx) {
EnGo_SetupAction(this, EnGo_WakeUp);
if ((this->actor.params & 0xF0) == 0x90) {
OnePointCutscene_Init(globalCtx, 4200, -99, &this->actor, MAIN_CAM);
OnePointCutscene_Init(globalCtx, 4200, -99, &this->actor, CAM_ID_MAIN);
}
}
}
@ -866,7 +866,7 @@ void EnGo_BiggoronActionFunc(EnGo* this, GlobalContext* globalCtx) {
EnGo_SetupAction(this, EnGo_Eyedrops);
globalCtx->msgCtx.msgMode = MSGMODE_PAUSED;
gSaveContext.timer2State = 0;
OnePointCutscene_Init(globalCtx, 4190, -99, &this->actor, MAIN_CAM);
OnePointCutscene_Init(globalCtx, 4190, -99, &this->actor, CAM_ID_MAIN);
} else {
this->unk_1E0.unk_00 = 0;
EnGo_SetupAction(this, EnGo_GetItem);