mirror of
https://github.com/zeldaret/oot.git
synced 2025-08-22 06:52:03 +00:00
Small Skin system documentation pass (#1017)
* some docs * rename a bunch of callbacks * more cleanup * format * last cleanup * some updates * more docs * done i think * name flag and format * name unused variable * comments * revert unwanted change * z64skin.h * format * Address review * Rename PostLimbDraw callbacks to PostDraw and some PR addressing * add true/false for setTranslation * ahhhh * remove "you" Co-authored-by: fig02 <fig02srl@gmail.com>
This commit is contained in:
parent
e5ecdfd559
commit
9fec455805
21 changed files with 442 additions and 345 deletions
|
@ -45,8 +45,6 @@ void EnfHG_Damage(EnfHG* this, GlobalContext* globalCtx);
|
|||
void EnfHG_Retreat(EnfHG* this, GlobalContext* globalCtx);
|
||||
void EnfHG_Done(EnfHG* this, GlobalContext* globalCtx);
|
||||
|
||||
void EnfHG_Noop(Actor* thisx, GlobalContext* globalCtx, PSkinAwb* skin);
|
||||
|
||||
const ActorInit En_fHG_InitVars = {
|
||||
ACTOR_EN_FHG,
|
||||
ACTORCAT_BG,
|
||||
|
@ -82,7 +80,7 @@ void EnfHG_Init(Actor* thisx, GlobalContext* globalCtx2) {
|
|||
this->actor.speedXZ = 0.0f;
|
||||
this->actor.focus.pos = this->actor.world.pos;
|
||||
this->actor.focus.pos.y += 70.0f;
|
||||
func_800A663C(globalCtx, &this->skin, &gPhantomHorseSkel, &gPhantomHorseRunningAnim);
|
||||
Skin_Init(globalCtx, &this->skin, &gPhantomHorseSkel, &gPhantomHorseRunningAnim);
|
||||
|
||||
if (this->actor.params >= GND_FAKE_BOSS) {
|
||||
EnfHG_SetupApproach(this, globalCtx, this->actor.params - GND_FAKE_BOSS);
|
||||
|
@ -96,7 +94,7 @@ void EnfHG_Destroy(Actor* thisx, GlobalContext* globalCtx) {
|
|||
EnfHG* this = (EnfHG*)thisx;
|
||||
|
||||
osSyncPrintf("F DT1\n");
|
||||
func_800A6888(globalCtx, &this->skin);
|
||||
Skin_Free(globalCtx, &this->skin);
|
||||
osSyncPrintf("F DT2\n");
|
||||
}
|
||||
|
||||
|
@ -708,7 +706,7 @@ void EnfHG_Update(Actor* thisx, GlobalContext* globalCtx) {
|
|||
this->actor.shape.rot.z = (s16)(Math_SinS(this->hitTimer * 0x7000) * 1500.0f) * (this->hitTimer / 20.0f);
|
||||
}
|
||||
|
||||
void EnfHG_Noop(Actor* thisx, GlobalContext* globalCtx, PSkinAwb* skin) {
|
||||
void EnfHG_PostDraw(Actor* thisx, GlobalContext* globalCtx, Skin* skin) {
|
||||
}
|
||||
|
||||
void EnfHG_Draw(Actor* thisx, GlobalContext* globalCtx) {
|
||||
|
@ -724,7 +722,7 @@ void EnfHG_Draw(Actor* thisx, GlobalContext* globalCtx) {
|
|||
: Gfx_SetFog(POLY_OPA_DISP, (u32)this->warpColorFilterR, (u32)this->warpColorFilterG,
|
||||
(u32)this->warpColorFilterB, 0, (s32)this->warpColorFilterUnk1 + 995,
|
||||
(s32)this->warpColorFilterUnk2 + 1000);
|
||||
func_800A6330(&this->actor, globalCtx, &this->skin, EnfHG_Noop, 0x23);
|
||||
func_800A6330(&this->actor, globalCtx, &this->skin, EnfHG_PostDraw, SKIN_TRANSFORM_IS_FHG);
|
||||
POLY_OPA_DISP = Gameplay_SetFog(globalCtx, POLY_OPA_DISP);
|
||||
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_fhg.c", 2480);
|
||||
}
|
||||
|
|
|
@ -58,7 +58,7 @@ typedef struct EnfHG {
|
|||
/* 0x01F8 */ f32 warpColorFilterUnk2;
|
||||
/* 0x01FC */ EnfHGActionFunc actionFunc;
|
||||
/* 0x0200 */ char unk_200[4];
|
||||
/* 0x0204 */ PSkinAwb skin;
|
||||
/* 0x0204 */ Skin skin;
|
||||
} EnfHG; // size = 0x0294
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue