mirror of
https://github.com/zeldaret/oot.git
synced 2025-08-15 03:20:35 +00:00
Document SkelCurve system (#1192)
* Rename and document SkelCurve * AVOID_UB in DemoTreLgt_OverrideLimbDraw * Rename code_8006C510 * Objdump flags in the makefile * Move CC_CHECK above compilation * Review 1 * Review 2 * Review 3 * Review Add doxygen comments to file head use angle macro, improve bug comment, make arguments of SkelCurve_Draw more consistent, Change this temp to pad in MagicWind
This commit is contained in:
parent
0584b3d288
commit
0e51a51fb1
15 changed files with 342 additions and 213 deletions
|
@ -2043,7 +2043,7 @@ void DemoEffect_DrawGetItem(Actor* thisx, GlobalContext* globalCtx) {
|
|||
/**
|
||||
* Callback for the SkelCurve system to draw the animated limbs.
|
||||
*/
|
||||
s32 DemoEffect_DrawTimewarpLimbs(GlobalContext* globalCtx, SkelAnimeCurve* skelCuve, s32 limbIndex, void* thisx) {
|
||||
s32 DemoEffect_OverrideLimbDrawTimeWarp(GlobalContext* globalCtx, SkelCurve* skelCurve, s32 limbIndex, void* thisx) {
|
||||
s32 pad;
|
||||
DemoEffect* this = (DemoEffect*)thisx;
|
||||
u32 frames = globalCtx->gameplayFrames;
|
||||
|
@ -2058,13 +2058,13 @@ s32 DemoEffect_DrawTimewarpLimbs(GlobalContext* globalCtx, SkelAnimeCurve* skelC
|
|||
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_demo_effect.c", 3172);
|
||||
|
||||
if (limbIndex == 0) {
|
||||
LimbTransform* transform = &skelCuve->transforms[0];
|
||||
s16* transform = skelCurve->jointTable[0];
|
||||
|
||||
transform->scale.y = 1024;
|
||||
transform->scale.z = transform->scale.x = 1024;
|
||||
transform[2] = transform[0] = 1024;
|
||||
transform[1] = 1024;
|
||||
}
|
||||
|
||||
return 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -2079,9 +2079,11 @@ void DemoEffect_DrawTimeWarp(Actor* thisx, GlobalContext* globalCtx) {
|
|||
Flags_GetEnv(globalCtx, 1) || gSaveContext.sceneSetupIndex >= 4 ||
|
||||
gSaveContext.entranceIndex == ENTR_TOKINOMA_4) {
|
||||
OPEN_DISPS(gfxCtx, "../z_demo_effect.c", 3201);
|
||||
|
||||
POLY_XLU_DISP = Gfx_CallSetupDL(POLY_XLU_DISP, 25);
|
||||
Matrix_Scale(2.0f, 2.0f, 2.0f, MTXMODE_APPLY);
|
||||
SkelCurve_Draw(thisx, globalCtx, &this->skelCurve, DemoEffect_DrawTimewarpLimbs, NULL, 1, this);
|
||||
SkelCurve_Draw(&this->actor, globalCtx, &this->skelCurve, DemoEffect_OverrideLimbDrawTimeWarp, NULL, 1, &this->actor);
|
||||
|
||||
CLOSE_DISPS(gfxCtx, "../z_demo_effect.c", 3216);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -78,7 +78,7 @@ typedef struct {
|
|||
|
||||
typedef struct DemoEffect {
|
||||
/* 0x0000 */ Actor actor;
|
||||
/* 0x014C */ SkelAnimeCurve skelCurve;
|
||||
/* 0x014C */ SkelCurve skelCurve;
|
||||
/* 0x016C */ u8 initObjectBankIndex;
|
||||
/* 0x0170 */ Gfx* jewelDisplayList;
|
||||
/* 0x0174 */ Gfx* jewelHolderDisplayList;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue