SkelAnime "Skeleton" Documentation Pass (#497)

* Darkmeiro decompilation

Bg_Gnd_Darkmeiro decompiled, matched, and documented.

* give this a shot

* fix conflict

* one more try

* could be useful

* whoops

* ZAP2 stuff

* ZAP why

* ZAP again

* spooky scary skeletons

* there's a skeleton inside of you

* formatting

* types

* a matched function even

* undo change

* lol anime

* ok how did I forget the .s

* array fix

* would you like to ride the bone train?

* stuff

* more renames

* renames and cleanup

* names suck

* idea

* using void** for now

* stuff

* look more type fixes

Co-authored-by: fig <fig02srl@gmail.com>
This commit is contained in:
petrie911
2020-12-01 21:19:56 -06:00
committed by GitHub
parent 629d1c8968
commit 4876610c75
268 changed files with 1941 additions and 2045 deletions
+8 -8
View File
@@ -3794,8 +3794,8 @@ Gfx* func_80034B54(GraphicsContext* gfxCtx) {
return displayList;
}
void func_80034BA0(GlobalContext* globalCtx, SkelAnime* skelAnime, OverrideLimbDraw2 overrideLimbDraw,
PostLimbDraw2 postLimbDraw, Actor* actor, s16 alpha) {
void func_80034BA0(GlobalContext* globalCtx, SkelAnime* skelAnime, OverrideLimbDraw overrideLimbDraw,
PostLimbDraw postLimbDraw, Actor* actor, s16 alpha) {
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_actor.c", 8831);
func_80093D18(globalCtx->state.gfxCtx);
@@ -3805,14 +3805,14 @@ void func_80034BA0(GlobalContext* globalCtx, SkelAnime* skelAnime, OverrideLimbD
gDPPipeSync(POLY_OPA_DISP++);
gSPSegment(POLY_OPA_DISP++, 0x0C, func_80034B28(globalCtx->state.gfxCtx));
POLY_OPA_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
overrideLimbDraw, postLimbDraw, actor, POLY_OPA_DISP);
POLY_OPA_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
overrideLimbDraw, postLimbDraw, actor, POLY_OPA_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_actor.c", 8860);
}
void func_80034CC4(GlobalContext* globalCtx, SkelAnime* skelAnime, OverrideLimbDraw2 overrideLimbDraw,
PostLimbDraw2 postLimbDraw, Actor* actor, s16 alpha) {
void func_80034CC4(GlobalContext* globalCtx, SkelAnime* skelAnime, OverrideLimbDraw overrideLimbDraw,
PostLimbDraw postLimbDraw, Actor* actor, s16 alpha) {
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_actor.c", 8876);
func_80093D84(globalCtx->state.gfxCtx);
@@ -3821,8 +3821,8 @@ void func_80034CC4(GlobalContext* globalCtx, SkelAnime* skelAnime, OverrideLimbD
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, alpha);
gSPSegment(POLY_XLU_DISP++, 0x0C, func_80034B54(globalCtx->state.gfxCtx));
POLY_XLU_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
overrideLimbDraw, postLimbDraw, actor, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
overrideLimbDraw, postLimbDraw, actor, POLY_XLU_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_actor.c", 8904);
}
+1 -1
View File
@@ -417,7 +417,7 @@ u32 func_80041F10(u32 a0, u32 a1, u32 a2) {
#pragma GLOBAL_ASM("asm/non_matchings/code/z_bgcheck/func_800420E4.s")
u32 func_80042108(u32 a0, u32 a1, u32 a2) {
s32 func_80042108(CollisionContext* a0, CollisionPoly* a1, u32 a2) {
u32 result;
s32 var1;
+7 -7
View File
@@ -99,7 +99,7 @@ s32 SkelCurve_Update(GlobalContext* globalCtx, SkelAnimeCurve* skelCurve) {
}
void SkelCurve_DrawLimb(GlobalContext* globalCtx, s32 limbIndex, SkelAnimeCurve* skelCurve,
OverrideCurveLimbDraw overrideLimbDraw, PostCurveLimbDraw postLimbDraw, s32 lod, Actor* actor) {
OverrideCurveLimbDraw overrideLimbDraw, PostCurveLimbDraw postLimbDraw, s32 lod, void* data) {
SkelCurveLimb* limb = SEGMENTED_TO_VIRTUAL(skelCurve->limbList[limbIndex]);
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_fcurve_data_skelanime.c", 279);
@@ -107,7 +107,7 @@ void SkelCurve_DrawLimb(GlobalContext* globalCtx, s32 limbIndex, SkelAnimeCurve*
Matrix_Push();
if (overrideLimbDraw == NULL ||
(overrideLimbDraw != NULL && overrideLimbDraw(globalCtx, skelCurve, limbIndex, actor))) {
(overrideLimbDraw != NULL && overrideLimbDraw(globalCtx, skelCurve, limbIndex, data))) {
Vec3f scale;
Vec3s rot;
Vec3f pos;
@@ -161,25 +161,25 @@ void SkelCurve_DrawLimb(GlobalContext* globalCtx, s32 limbIndex, SkelAnimeCurve*
}
if (postLimbDraw != NULL) {
postLimbDraw(globalCtx, skelCurve, limbIndex, actor);
postLimbDraw(globalCtx, skelCurve, limbIndex, data);
}
if (limb->firstChildIdx != LIMB_DONE) {
SkelCurve_DrawLimb(globalCtx, limb->firstChildIdx, skelCurve, overrideLimbDraw, postLimbDraw, lod, actor);
SkelCurve_DrawLimb(globalCtx, limb->firstChildIdx, skelCurve, overrideLimbDraw, postLimbDraw, lod, data);
}
Matrix_Pull();
if (limb->nextLimbIdx != LIMB_DONE) {
SkelCurve_DrawLimb(globalCtx, limb->nextLimbIdx, skelCurve, overrideLimbDraw, postLimbDraw, lod, actor);
SkelCurve_DrawLimb(globalCtx, limb->nextLimbIdx, skelCurve, overrideLimbDraw, postLimbDraw, lod, data);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_fcurve_data_skelanime.c", 371);
}
void SkelCurve_Draw(Actor* actor, GlobalContext* globalCtx, SkelAnimeCurve* skelCurve,
OverrideCurveLimbDraw overrideLimbDraw, PostCurveLimbDraw postLimbDraw, s32 lod, Actor* actor2) {
OverrideCurveLimbDraw overrideLimbDraw, PostCurveLimbDraw postLimbDraw, s32 lod, void* data) {
if (skelCurve->transforms != NULL) {
SkelCurve_DrawLimb(globalCtx, 0, skelCurve, overrideLimbDraw, postLimbDraw, lod, actor2);
SkelCurve_DrawLimb(globalCtx, 0, skelCurve, overrideLimbDraw, postLimbDraw, lod, data);
}
}
+27 -27
View File
@@ -10,7 +10,7 @@ typedef struct {
/* 0x04 */ Vec3f pos;
} BowStringData; // size = 0x10
SkeletonHeader* gPlayerSkelHeaders[] = { 0x060377F4, 0x0602CF6C };
FlexSkeletonHeader* gPlayerSkelHeaders[] = { 0x060377F4, 0x0602CF6C };
s16 sBootData[PLAYER_BOOTS_MAX][17] = {
{ 200, 1000, 300, 700, 550, 270, 600, 350, 800, 600, -100, 600, 590, 750, 125, 200, 130 },
@@ -625,9 +625,9 @@ Gfx* sBootDListGroups[][2] = {
{ 0x06025BA8, 0x06025DB0 },
};
void func_8008F470(GlobalContext* globalCtx, Skeleton* skeleton, Vec3s* limbDrawTable, s32 dListCount, s32 lod,
s32 tunic, s32 boots, s32 face, OverrideLimbDraw overrideLimbDraw, PostLimbDraw postLimbDraw,
void* arg) {
void func_8008F470(GlobalContext* globalCtx, void** skeleton, Vec3s* limbDrawTable, s32 dListCount, s32 lod, s32 tunic,
s32 boots, s32 face, OverrideLimbDrawOpa overrideLimbDraw, PostLimbDrawOpa postLimbDraw,
void* data) {
Color_RGB8* color;
s32 eyeIndex = (limbDrawTable[22].x & 0xF) - 1;
s32 mouthIndex = (limbDrawTable[22].x >> 4) - 1;
@@ -651,7 +651,7 @@ void func_8008F470(GlobalContext* globalCtx, Skeleton* skeleton, Vec3s* limbDraw
sDListsLodOffset = lod * 2;
SkelAnime_LodDrawSV(globalCtx, skeleton, limbDrawTable, dListCount, overrideLimbDraw, postLimbDraw, arg, lod);
SkelAnime_DrawFlexLod(globalCtx, skeleton, limbDrawTable, dListCount, overrideLimbDraw, postLimbDraw, data, lod);
if ((overrideLimbDraw != func_800902F0) && (overrideLimbDraw != func_80090440) && (gSaveContext.gameMode != 3)) {
if (LINK_IS_ADULT) {
@@ -792,8 +792,8 @@ void func_8008F87C(GlobalContext* globalCtx, Player* this, SkelAnime* skelAnime,
}
}
s32 func_8008FCC8(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* actor) {
Player* this = (Player*)actor;
s32 func_8008FCC8(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
Player* this = (Player*)thisx;
if (limbIndex == PLAYER_LIMB_ROOT) {
D_80160014 = this->leftHandType;
@@ -858,10 +858,10 @@ s32 func_8008FCC8(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* p
return 0;
}
s32 func_80090014(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* actor) {
Player* this = (Player*)actor;
s32 func_80090014(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
Player* this = (Player*)thisx;
if (func_8008FCC8(globalCtx, limbIndex, dList, pos, rot, actor) == 0) {
if (!func_8008FCC8(globalCtx, limbIndex, dList, pos, rot, thisx)) {
if (limbIndex == PLAYER_LIMB_L_HAND) {
Gfx** dLists = this->leftHandDLists;
@@ -910,10 +910,10 @@ s32 func_80090014(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* p
return 0;
}
s32 func_800902F0(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* actor) {
Player* this = (Player*)actor;
s32 func_800902F0(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
Player* this = (Player*)thisx;
if (func_8008FCC8(globalCtx, limbIndex, dList, pos, rot, actor) == 0) {
if (!func_8008FCC8(globalCtx, limbIndex, dList, pos, rot, thisx)) {
if (this->unk_6AD != 2) {
*dList = NULL;
} else if (limbIndex == PLAYER_LIMB_L_FOREARM) {
@@ -934,8 +934,8 @@ s32 func_800902F0(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* p
return 0;
}
s32 func_80090440(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* actor) {
if (func_8008FCC8(globalCtx, limbIndex, dList, pos, rot, actor) == 0) {
s32 func_80090440(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
if (!func_8008FCC8(globalCtx, limbIndex, dList, pos, rot, thisx)) {
*dList = NULL;
}
@@ -1069,7 +1069,7 @@ void func_80090A28(Player* this, Vec3f* vecs) {
void func_80090AFC(GlobalContext* globalCtx, Player* this, f32 arg2) {
static Vec3f D_801260C8 = { -500.0f, -100.0f, 0.0f };
f32 sp9C;
CollisionPoly* sp9C;
f32 sp98;
Vec3f sp8C;
Vec3f sp80;
@@ -1085,7 +1085,7 @@ void func_80090AFC(GlobalContext* globalCtx, Player* this, f32 arg2) {
if (1) {}
if (func_8003E188(&globalCtx->colCtx, &sp8C, &sp80, &sp74, &sp9C, 1, 1, 1, 1, &sp98) != 0) {
if (func_8003E188(&globalCtx->colCtx, &sp8C, &sp80, &sp74, &sp9C, 1, 1, 1, 1, &sp98)) {
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_player_lib.c", 2572);
OVERLAY_DISP = Gfx_CallSetupDL(OVERLAY_DISP, 0x07);
@@ -1152,8 +1152,8 @@ Vec3f D_801261E0[] = {
{ 200.0f, 200.0f, 0.0f },
};
void func_80090D20(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* actor) {
Player* this = (Player*)actor;
void func_80090D20(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
Player* this = (Player*)thisx;
if (*dList != NULL) {
Matrix_MultVec3f(&D_8012602C, D_80160000);
@@ -1367,7 +1367,7 @@ u32 func_80091738(GlobalContext* globalCtx, u8* segment, SkelAnime* skelAnime) {
gSegments[4] = VIRTUAL_TO_PHYSICAL(segment + 0x3800);
gSegments[6] = VIRTUAL_TO_PHYSICAL(segment + 0x8800);
SkelAnime_InitLinkAnimetion(globalCtx, skelAnime, gPlayerSkelHeaders[(void)0, gSaveContext.linkAge], &D_04003238, 9,
SkelAnime_InitLinkAnimation(globalCtx, skelAnime, gPlayerSkelHeaders[(void)0, gSaveContext.linkAge], &D_04003238, 9,
ptr, ptr, PLAYER_LIMB_MAX);
return size + 0x8890;
@@ -1415,9 +1415,9 @@ s32 func_80091880(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* p
return 0;
}
void func_80091A24(GlobalContext* globalCtx, void* seg04, void* seg06, struct_80091A24_arg3* arg3, Vec3f* pos,
Vec3s* rot, f32 scale, s32 sword, s32 tunic, s32 shield, s32 boots, s32 width, s32 height,
Vec3f* eye, Vec3f* at, f32 fovy, void* img1, void* img2) {
void func_80091A24(GlobalContext* globalCtx, void* seg04, void* seg06, SkelAnime* arg3, Vec3f* pos, Vec3s* rot,
f32 scale, s32 sword, s32 tunic, s32 shield, s32 boots, s32 width, s32 height, Vec3f* eye, Vec3f* at,
f32 fovy, void* img1, void* img2) {
static Vp viewport = { 128, 224, 511, 0, 128, 224, 511, 0 };
static Lights1 lights1 = gdSPDefLights1(80, 80, 80, 255, 255, 255, 84, 84, 172);
static Vec3f lightDir = { 89.8f, 0.0f, 89.8f };
@@ -1509,7 +1509,7 @@ void func_80091A24(GlobalContext* globalCtx, void* seg04, void* seg06, struct_80
gSPSegment(POLY_OPA_DISP++, 0x0C, gCullBackDList);
func_8008F470(globalCtx, arg3->skeleton, arg3->limbDrawTable, arg3->dListCount, 0, tunic, boots, 0, func_80091880,
func_8008F470(globalCtx, arg3->skeleton, arg3->limbDrawTbl, arg3->dListCount, 0, tunic, boots, 0, func_80091880,
NULL, &sp12C);
gSPEndDisplayList(POLY_OPA_DISP++);
@@ -1521,8 +1521,8 @@ void func_80091A24(GlobalContext* globalCtx, void* seg04, void* seg06, struct_80
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_player_lib.c", 3288);
}
void func_8009214C(GlobalContext* globalCtx, u8* segment, struct_80091A24_arg3* arg2, Vec3f* pos, Vec3s* rot, f32 scale,
s32 sword, s32 tunic, s32 shield, s32 boots) {
void func_8009214C(GlobalContext* globalCtx, u8* segment, SkelAnime* arg2, Vec3f* pos, Vec3s* rot, f32 scale, s32 sword,
s32 tunic, s32 shield, s32 boots) {
static Vec3f eye = { 0.0f, 0.0f, -400.0f };
static Vec3f at = { 0.0f, 0.0f, 0.0f };
Vec3s* destTable;
@@ -1549,7 +1549,7 @@ void func_8009214C(GlobalContext* globalCtx, u8* segment, struct_80091A24_arg3*
}
srcTable = SEGMENTED_TO_VIRTUAL(srcTable);
destTable = arg2->limbDrawTable;
destTable = arg2->limbDrawTbl;
for (i = 0; i < arg2->limbCount; i++) {
*destTable++ = *srcTable++;
}
+484 -529
View File
File diff suppressed because it is too large Load Diff
+6 -8
View File
@@ -53,7 +53,7 @@ const ActorInit Demo_Go_InitVars = {
extern AnimationHeader D_060029A8;
extern AnimationHeader D_06004930;
extern UNK_TYPE D_0600E680;
extern SkeletonHeader D_0600FEF0;
extern FlexSkeletonHeader D_0600FEF0;
UNK_TYPE func_8097C870(DemoGo* this) {
s32 ret;
@@ -245,8 +245,7 @@ void func_8097CEEC(DemoGo* this, GlobalContext* globalCtx) {
void func_8097CF20(DemoGo* this, GlobalContext* globalCtx, UNK_TYPE arg2) {
AnimationHeader* animation = &D_060029A8;
if (arg2 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, animation, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&animation->genericHeader), 0, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, animation, 1.0f, 0.0f, SkelAnime_GetFrameCount(animation), 0, -8.0f);
this->action = 5;
this->unk_19C = 0.0f;
}
@@ -319,9 +318,8 @@ void DemoGo_Init(Actor* thisx, GlobalContext* globalCtx) {
AnimationHeader* animation = &D_06004930;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 30.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0600FEF0, NULL, NULL, NULL, 0);
SkelAnime_ChangeAnim(&this->skelAnime, animation, 1.0f, 0.0f, SkelAnime_GetFrameCount(&animation->genericHeader), 2,
0.0f);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0600FEF0, NULL, NULL, NULL, 0);
SkelAnime_ChangeAnim(&this->skelAnime, animation, 1.0f, 0.0f, SkelAnime_GetFrameCount(animation), 2, 0.0f);
this->action = 0;
}
@@ -341,8 +339,8 @@ void func_8097D29C(DemoGo* this, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(srcSegment8));
gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(srcSegment9));
SkelAnime_DrawSV(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount, NULL, NULL,
&this->actor);
SkelAnime_DrawFlexOpa(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount, NULL, NULL,
this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_demo_go.c", 746);
}
+33 -44
View File
@@ -101,7 +101,7 @@ extern AnimationHeader D_06000AFC;
extern Gfx D_0600EDE8[];
extern AnimationHeader D_060014E4;
extern AnimationHeader D_06001868;
extern SkeletonHeader D_0600F788;
extern FlexSkeletonHeader D_0600F788;
extern AnimationHeader D_0600FB10;
extern AnimationHeader D_060101C8;
extern AnimationHeader D_06010EE0;
@@ -281,8 +281,8 @@ void func_80985200(DemoIm* this, GlobalContext* globalCtx, s32 actionIdx) {
}
}
void func_80985280(DemoIm* this, AnimationHeader* animationHeader, u8 arg2, f32 transitionRate, s32 arg4) {
f32 frameCount = SkelAnime_GetFrameCount(&animationHeader->genericHeader);
void func_80985280(DemoIm* this, AnimationHeader* animHeaderSeg, u8 arg2, f32 transitionRate, s32 arg4) {
f32 frameCount = SkelAnime_GetFrameCount(animHeaderSeg);
f32 playbackSpeed;
f32 unk0;
f32 fc;
@@ -297,7 +297,7 @@ void func_80985280(DemoIm* this, AnimationHeader* animationHeader, u8 arg2, f32
playbackSpeed = -1.0f;
}
SkelAnime_ChangeAnim(&this->skelAnime, animationHeader, playbackSpeed, unk0, fc, arg2, transitionRate);
SkelAnime_ChangeAnim(&this->skelAnime, animHeaderSeg, playbackSpeed, unk0, fc, arg2, transitionRate);
}
void func_80985310(DemoIm* this, GlobalContext* globalCtx) {
@@ -345,8 +345,7 @@ void func_8098544C(DemoIm* this, GlobalContext* globalCtx) {
void func_809854DC(DemoIm* this, GlobalContext* globalCtx) {
if ((globalCtx->csCtx.state != 0) && (globalCtx->csCtx.npcActions[5] != NULL) &&
(globalCtx->csCtx.npcActions[5]->action == 2)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001868, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06001868.genericHeader), 0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001868, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06001868), 0, 0.0f);
this->action = 2;
this->drawConfig = 1;
func_80985358(this, globalCtx);
@@ -363,16 +362,14 @@ void func_8098557C(DemoIm* this) {
void func_809855A8(DemoIm* this, GlobalContext* globalCtx) {
if ((globalCtx->csCtx.state != 0) && (globalCtx->csCtx.npcActions[5] != NULL) &&
(globalCtx->csCtx.npcActions[5]->action == 3)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000710, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06000710.genericHeader), 2, 4.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000710, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06000710), 2, 4.0f);
this->action = 4;
}
}
void func_80985640(DemoIm* this, s32 arg1) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000AFC, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06000AFC.genericHeader), 0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000AFC, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06000AFC), 0, 0.0f);
this->action = 5;
}
}
@@ -446,8 +443,7 @@ void func_809858C8(DemoIm* this, GlobalContext* globalCtx) {
void func_80985948(DemoIm* this, GlobalContext* globalCtx) {
if (func_809850E8(this, globalCtx, 4, 5)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06011C08, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06011C08.genericHeader), 2, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06011C08, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06011C08), 2, 0.0f);
this->action = 8;
this->drawConfig = 2;
this->unk_26C = 0;
@@ -486,8 +482,7 @@ void func_809859E0(DemoIm* this, GlobalContext* globalCtx) {
void func_80985B34(DemoIm* this, GlobalContext* globalCtx) {
if (func_80985134(this, globalCtx, 4, 5)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06012218, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06012218.genericHeader), 2, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06012218, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06012218), 2, -8.0f);
this->action = 8;
this->drawConfig = 2;
this->unk_268 = kREG(5) + 10.0f;
@@ -536,8 +531,8 @@ void func_80985CE8(DemoIm* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->unk_26C);
gSPSegment(POLY_XLU_DISP++, 0x0C, &D_80116280[0]);
POLY_XLU_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
NULL, NULL, NULL, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
NULL, NULL, NULL, POLY_XLU_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_demo_im_inKenjyanomaDemo02.c", 308);
}
@@ -557,7 +552,7 @@ void func_80985EAC(DemoIm* this, GlobalContext* globalCtx) {
}
void func_80985EF4(DemoIm* this) {
if (!func_800A56C8(&this->skelAnime, SkelAnime_GetFrameCount(&D_0601182C.genericHeader) - 1.0f)) {
if (!func_800A56C8(&this->skelAnime, SkelAnime_GetFrameCount(&D_0601182C) - 1.0f)) {
func_80985060(this);
}
}
@@ -568,8 +563,7 @@ void func_80985F54(DemoIm* this) {
}
void func_80985F64(DemoIm* this, GlobalContext* globalCtx) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001868, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06001868.genericHeader),
0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001868, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06001868), 0, 0.0f);
func_80985180(this, globalCtx, 5);
this->action = 11;
this->drawConfig = 1;
@@ -577,13 +571,12 @@ void func_80985F64(DemoIm* this, GlobalContext* globalCtx) {
void func_80985FE8(DemoIm* this, s32 arg1) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0601182C, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_0601182C.genericHeader), 0, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0601182C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0601182C), 0, -8.0f);
}
}
void func_8098604C(DemoIm* this) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06010EE0.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06010EE0);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06010EE0, 1.0f, 0.0f, frameCount, 2, -8.0f);
this->action = 12;
@@ -598,15 +591,13 @@ void func_809860C8(DemoIm* this) {
void func_809860DC(DemoIm* this, s32 arg1) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001868, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06001868.genericHeader), 0, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001868, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06001868), 0, -8.0f);
this->unk_2D0 = 0;
}
}
void func_80986148(DemoIm* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06010EE0, -1.0f, SkelAnime_GetFrameCount(&D_06010EE0.genericHeader), 0.0f,
2, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06010EE0, -1.0f, SkelAnime_GetFrameCount(&D_06010EE0), 0.0f, 2, -8.0f);
this->action = 14;
this->drawConfig = 1;
}
@@ -625,7 +616,7 @@ void func_809861C4(DemoIm* this, GlobalContext* globalCtx) {
break;
case 7:
SkelAnime_ChangeAnim(&this->skelAnime, &D_0601182C, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_0601182C.genericHeader), 0, -8.0f);
SkelAnime_GetFrameCount(&D_0601182C), 0, -8.0f);
this->action = 12;
break;
default:
@@ -759,16 +750,14 @@ void func_80986700(DemoIm* this) {
}
void func_80986710(DemoIm* this, GlobalContext* globalCtx) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001868, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06001868.genericHeader),
0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001868, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06001868), 0, 0.0f);
func_80985180(this, globalCtx, 5);
this->action = 16;
this->drawConfig = 1;
}
void func_80986794(DemoIm* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060014E4, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060014E4.genericHeader),
2, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060014E4, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060014E4), 2, -8.0f);
this->action = 17;
this->drawConfig = 1;
}
@@ -1106,8 +1095,8 @@ void DemoIm_Init(Actor* thisx, GlobalContext* globalCtx) {
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 30.0f);
func_80984D00(thisx, globalCtx);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0600F788, NULL, this->limbDrawTable, this->transitionDrawTable,
17);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0600F788, NULL, this->limbDrawTable, this->transitionDrawTable,
17);
thisx->flags &= ~1;
switch (this->actor.params) {
@@ -1135,7 +1124,7 @@ void DemoIm_Destroy(Actor* thisx, GlobalContext* globalCtx) {
func_80984D4C(thisx, globalCtx);
}
s32 func_80987514(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 func_80987514(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
DemoIm* this = THIS;
s32* unk_2D0 = &this->unk_2D0;
@@ -1163,20 +1152,20 @@ s32 func_80987514(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* p
return 0;
}
void func_809875C0(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
s32 pad;
void func_809875C0(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
DemoIm* this = THIS;
if (limbIndex == 0x10) {
Vec3f sp28 = D_809887D8;
Vec3f dest;
Matrix_MultVec3f(&sp28, &dest);
thisx->posRot2.pos.x = dest.x;
thisx->posRot2.pos.y = dest.y;
thisx->posRot2.pos.z = dest.z;
thisx->posRot2.rot.x = thisx->posRot.rot.x;
thisx->posRot2.rot.y = thisx->posRot.rot.y;
thisx->posRot2.rot.z = thisx->posRot.rot.z;
this->actor.posRot2.pos.x = dest.x;
this->actor.posRot2.pos.y = dest.y;
this->actor.posRot2.pos.z = dest.z;
this->actor.posRot2.rot.x = this->actor.posRot.rot.x;
this->actor.posRot2.rot.y = this->actor.posRot.rot.y;
this->actor.posRot2.rot.z = this->actor.posRot.rot.z;
}
}
@@ -1198,8 +1187,8 @@ void func_80987658(DemoIm* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
gSPSegment(POLY_OPA_DISP++, 0x0C, &D_80116280[2]);
SkelAnime_DrawSV(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount, func_80987514,
func_809875C0, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount, func_80987514,
func_809875C0, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_demo_im.c", 925);
}
+18 -20
View File
@@ -89,7 +89,7 @@ void DemoSa_Destroy(Actor* thisx, GlobalContext* globalCtx) {
extern AnimationHeader D_06001334;
extern AnimationHeader D_060021D8;
extern Gfx D_06007B80[];
extern SkeletonHeader D_0600B1A0;
extern FlexSkeletonHeader D_0600B1A0;
extern AnimationHeader D_0600DF80;
extern AnimationHeader D_0600E500;
extern AnimationHeader D_0600F580;
@@ -191,9 +191,9 @@ void func_8098E6EC(DemoSa* this, GlobalContext* globalCtx, s32 actionIdx) {
}
}
void func_8098E76C(DemoSa* this, AnimationHeader* animationHeader, u8 arg2, f32 transitionRate, s32 arg4) {
void func_8098E76C(DemoSa* this, AnimationHeader* animHeaderSeg, u8 arg2, f32 transitionRate, s32 arg4) {
s32 pad[2];
f32 frameCount = SkelAnime_GetFrameCount(&animationHeader->genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(animHeaderSeg);
f32 playbackSpeed;
f32 unk0;
f32 fc;
@@ -208,11 +208,11 @@ void func_8098E76C(DemoSa* this, AnimationHeader* animationHeader, u8 arg2, f32
playbackSpeed = -1.0f;
}
SkelAnime_ChangeAnim(&this->skelAnime, animationHeader, playbackSpeed, unk0, fc, arg2, transitionRate);
SkelAnime_ChangeAnim(&this->skelAnime, animHeaderSeg, playbackSpeed, unk0, fc, arg2, transitionRate);
}
void func_8098E7FC(DemoSa* this, GlobalContext* globalCtx) {
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0600B1A0, &D_060021D8, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0600B1A0, &D_060021D8, NULL, NULL, 0);
this->actor.shape.unk_08 = -10000.0f;
func_8098E508(this, 1);
func_8098E51C(this, 0);
@@ -282,8 +282,8 @@ void func_8098EA68(DemoSa* this, GlobalContext* globalCtx) {
if (globalCtx->csCtx.state != 0) {
npcAction = globalCtx->csCtx.npcActions[4];
if ((npcAction != NULL) && (npcAction->action == 3)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600DF80.genericHeader, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_0600DF80.genericHeader), 2, -4.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600DF80, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600DF80), 2,
-4.0f);
this->action = 4;
}
}
@@ -291,8 +291,7 @@ void func_8098EA68(DemoSa* this, GlobalContext* globalCtx) {
void func_8098EB00(DemoSa* this, s32 arg1) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600E500, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_0600E500.genericHeader), 0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600E500, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600E500), 0, 0.0f);
this->action = 5;
}
}
@@ -348,9 +347,9 @@ void func_8098ECCC(DemoSa* this, GlobalContext* globalCtx) {
void func_8098ECF4(DemoSa* this, GlobalContext* globalCtx) {
s32 pad[2];
SkelAnime* skelAnime = &this->skelAnime;
f32 frameCount = SkelAnime_GetFrameCount(&D_06001334.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06001334);
SkelAnime_InitSV(globalCtx, skelAnime, &D_0600B1A0, NULL, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, skelAnime, &D_0600B1A0, NULL, NULL, NULL, 0);
SkelAnime_ChangeAnim(skelAnime, &D_06001334, 1.0f, 0.0f, frameCount, 2, 0.0f);
this->action = 7;
this->actor.shape.unk_14 = 0;
@@ -469,14 +468,14 @@ void func_8098F1C0(DemoSa* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->alpha);
gSPSegment(POLY_XLU_DISP++, 0x0C, D_80116280);
POLY_XLU_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
NULL, NULL, NULL, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
NULL, NULL, NULL, POLY_XLU_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_demo_sa_inKenjyanomaDemo02.c", 325);
}
void func_8098F390(DemoSa* this, GlobalContext* globalCtx) {
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0600B1A0, &D_060021D8, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0600B1A0, &D_060021D8, NULL, NULL, 0);
this->action = 10;
this->drawConfig = 1;
}
@@ -488,7 +487,7 @@ void func_8098F3F0(DemoSa* this, GlobalContext* globalCtx) {
}
void func_8098F420(DemoSa* this, GlobalContext* globalCtx) {
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0600B1A0, &D_0600FFD4, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0600B1A0, &D_0600FFD4, NULL, NULL, 0);
this->action = 11;
this->drawConfig = 0;
this->actor.shape.unk_14 = 0;
@@ -604,7 +603,7 @@ void func_8098F7FC(DemoSa* this, GlobalContext* globalCtx) {
void func_8098F83C(DemoSa* this, GlobalContext* globalCtx) {
Vec3f* thisPos = &this->actor.posRot.pos;
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0600B1A0, &D_0601113C, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0600B1A0, &D_0601113C, NULL, NULL, 0);
Actor_SpawnAsChild(&globalCtx->actorCtx, &this->actor, globalCtx, ACTOR_EN_ELF, thisPos->x, thisPos->y, thisPos->z,
0, 0, 0, FAIRY_KOKIRI);
this->action = 16;
@@ -776,8 +775,7 @@ void DemoSa_Init(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 DemoSa_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
s32 DemoSa_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
DemoSa* this = THIS;
if ((limbIndex == 15) && (this->unk_1B0 != 0)) {
@@ -808,8 +806,8 @@ void func_8098FEB4(DemoSa* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
gSPSegment(POLY_OPA_DISP++, 0x0C, &D_80116280[2]);
SkelAnime_DrawSV(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
DemoSa_OverrideLimbDraw, NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
DemoSa_OverrideLimbDraw, NULL, &this->actor);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_demo_sa.c", 626);
}
+16 -19
View File
@@ -27,7 +27,7 @@ void func_809B0994(EnAni* this, GlobalContext* globalCtx);
void func_809B0A28(EnAni* this, GlobalContext* globalCtx);
void func_809B0A6C(EnAni* this, GlobalContext* globalCtx);
extern SkeletonHeader D_060000F0;
extern FlexSkeletonHeader D_060000F0;
extern AnimationHeader D_060067B8;
extern AnimationHeader D_060070F0;
extern AnimationHeader D_060076EC;
@@ -73,8 +73,8 @@ void EnAni_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_ProcessInitChain(&this->actor, sInitChain);
ActorShape_Init(&this->actor.shape, -2800.0f, ActorShadow_DrawFunc_Circle, 36.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060000F0, &D_060076EC, this->limbDrawTable,
this->transitionDrawTable, 0x10);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060000F0, &D_060076EC, this->limbDrawTable,
this->transitionDrawTable, 0x10);
SkelAnime_ChangeAnimDefaultStop(&this->skelAnime, &D_060076EC);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
@@ -208,30 +208,25 @@ void func_809B0988(EnAni* this, GlobalContext* globalCtx) {
}
void func_809B0994(EnAni* this, GlobalContext* globalCtx) {
GenericAnimationHeader* objSegFrameCount = &D_060070F0.genericHeader;
AnimationHeader* objSegChangeAnime = &D_060070F0;
if (globalCtx->csCtx.npcActions[0]->action == 4) {
SkelAnime_ChangeAnim(&this->skelAnime, objSegChangeAnime, 1.0f, 0.0f, SkelAnime_GetFrameCount(objSegFrameCount),
2, -4.0f);
this->unk_2AA += 1;
SkelAnime_ChangeAnim(&this->skelAnime, &D_060070F0, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060070F0), 2, -4.0f);
this->unk_2AA++;
this->actor.shape.shadowDrawFunc = ActorShadow_DrawFunc_Circle;
}
}
void func_809B0A28(EnAni* this, GlobalContext* globalCtx) {
if (SkelAnime_FrameUpdateMatrix(&this->skelAnime) != 0) {
this->unk_2AA += 1;
if (SkelAnime_FrameUpdateMatrix(&this->skelAnime)) {
this->unk_2AA++;
}
}
void func_809B0A6C(EnAni* this, GlobalContext* globalCtx) {
if (SkelAnime_FrameUpdateMatrix(&this->skelAnime) != 0) {
if (SkelAnime_FrameUpdateMatrix(&this->skelAnime)) {
this->skelAnime.animCurrentFrame = 0.0f;
}
if (globalCtx->csCtx.npcActions[0]->action == 2) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060067B8, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_060067B8.genericHeader), 2, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060067B8, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060067B8), 2, 0.0f);
this->actor.shape.shadowDrawFunc = NULL;
this->unk_2AA++;
}
@@ -295,7 +290,7 @@ void EnAni_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnAni_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnAni_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnAni* this = THIS;
if (limbIndex == 15) {
@@ -305,9 +300,11 @@ s32 EnAni_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnAni_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnAni_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnAni* this = THIS;
if (limbIndex == 15) {
Matrix_MultVec3f(&sMultVec, &thisx->posRot2.pos);
Matrix_MultVec3f(&sMultVec, &this->actor.posRot2.pos);
}
}
@@ -321,8 +318,8 @@ void EnAni_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_809B0F80[this->unk_2AC]));
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnAni_OverrideLimbDraw, EnAni_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnAni_OverrideLimbDraw, EnAni_PostLimbDraw, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ani.c", 736);
}
@@ -21,7 +21,7 @@ void func_809B5C18(EnAttackNiw* this, GlobalContext* globalCtx);
void func_809B59B0(EnAttackNiw* this, GlobalContext* globalCtx);
extern AnimationHeader D_060000E8;
extern SkeletonHeader D_06002530;
extern FlexSkeletonHeader D_06002530;
const ActorInit En_Attack_Niw_InitVars = {
ACTOR_EN_ATTACK_NIW,
@@ -47,8 +47,8 @@ void EnAttackNiw_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_ProcessInitChain(&this->actor, sInitChain);
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 25.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06002530, &D_060000E8, this->limbDrawTable,
this->transitionDrawTable, 16);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06002530, &D_060000E8, this->limbDrawTable,
this->transitionDrawTable, 16);
if (this->actor.params < 0) {
this->actor.params = 0;
}
@@ -376,7 +376,7 @@ void EnAttackNiw_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 func_809B5F98(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 func_809B5F98(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnAttackNiw* this = THIS;
Vec3f sp0 = { 0.0f, 0.0f, 0.0f };
@@ -403,6 +403,6 @@ void EnAttackNiw_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnAttackNiw* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
func_809B5F98, NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
func_809B5F98, NULL, this);
}
+1 -1
View File
@@ -131,5 +131,5 @@ void EnBird_Update(Actor* thisx, GlobalContext* globalCtx) {
void EnBird_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnBird* this = THIS;
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, 0, NULL, NULL);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, NULL, NULL, NULL);
}
+11 -12
View File
@@ -101,15 +101,15 @@ void EnBox_ClipToGround(EnBox* this, GlobalContext* globalCtx) {
void EnBox_Init(Actor* thisx, GlobalContext* globalCtx) {
GlobalContext* globalCtx2 = globalCtx;
EnBox* this = THIS;
AnimationHeader* animHeader;
AnimationHeader* anim;
s32 dynaUnk;
f32 animFrameStart;
f32 animFrameCount;
animFrameStart = 0.0f;
animHeader = D_809CA800[((void)0, gSaveContext.linkAge)];
anim = D_809CA800[((void)0, gSaveContext.linkAge)];
dynaUnk = 0;
animFrameCount = SkelAnime_GetFrameCount(&animHeader->genericHeader);
animFrameCount = SkelAnime_GetFrameCount(anim);
Actor_ProcessInitChain(&this->dyna.actor, sInitChain);
DynaPolyInfo_SetActorMove(&this->dyna, 0);
@@ -180,9 +180,8 @@ void EnBox_Init(Actor* thisx, GlobalContext* globalCtx) {
this->dyna.actor.posRot.rot.y += 0x8000;
this->dyna.actor.initPosRot.rot.z = this->dyna.actor.posRot.rot.z = this->dyna.actor.shape.rot.z = 0;
SkelAnime_Init(globalCtx2, &this->skelanime, &D_060047D8, animHeader, this->limbDrawTable,
this->transitionDrawTable, 5);
SkelAnime_ChangeAnim(&this->skelanime, animHeader, 1.5f, animFrameStart, animFrameCount, 2, 0.0f);
SkelAnime_Init(globalCtx2, &this->skelanime, &D_060047D8, anim, this->limbDrawTable, this->transitionDrawTable, 5);
SkelAnime_ChangeAnim(&this->skelanime, anim, 1.5f, animFrameStart, animFrameCount, 2, 0.0f);
switch (this->type) {
case ENBOX_TYPE_SMALL:
@@ -410,7 +409,7 @@ void EnBox_WaitOpen(EnBox* this, GlobalContext* globalCtx) {
if (this->unk_1F4 != 0) { // unk_1F4 is modified by player code
linkAge = gSaveContext.linkAge;
anim = D_809CA800[(this->unk_1F4 < 0 ? 2 : 0) + linkAge];
frameCount = SkelAnime_GetFrameCount(&anim->genericHeader);
frameCount = SkelAnime_GetFrameCount(anim);
SkelAnime_ChangeAnim(&this->skelanime, anim, 1.5f, 0, frameCount, 2, 0.0f);
EnBox_SetupAction(this, EnBox_Open);
if (this->unk_1F4 > 0) {
@@ -552,7 +551,7 @@ void EnBox_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
void EnBox_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx, Gfx** gfx) {
void EnBox_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx, Gfx** gfx) {
EnBox* this = THIS;
s32 pad;
@@ -645,8 +644,8 @@ void EnBox_Draw(Actor* thisx, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
gSPSegment(POLY_OPA_DISP++, 0x08, EnBox_EmptyDList(globalCtx->state.gfxCtx));
func_80093D18(globalCtx->state.gfxCtx);
POLY_OPA_DISP = SkelAnime_Draw2(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, NULL,
EnBox_PostLimbDraw, &this->dyna.actor, POLY_OPA_DISP);
POLY_OPA_DISP = SkelAnime_Draw(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, NULL,
EnBox_PostLimbDraw, this, POLY_OPA_DISP);
} else if (this->alpha != 0) {
gDPPipeSync(POLY_XLU_DISP++);
func_80093D84(globalCtx->state.gfxCtx);
@@ -656,8 +655,8 @@ void EnBox_Draw(Actor* thisx, GlobalContext* globalCtx) {
} else {
gSPSegment(POLY_XLU_DISP++, 0x08, func_809CA4A0(globalCtx->state.gfxCtx));
}
POLY_XLU_DISP = SkelAnime_Draw2(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, NULL,
EnBox_PostLimbDraw, &this->dyna.actor, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_Draw(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, NULL,
EnBox_PostLimbDraw, this, POLY_XLU_DISP);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_box.c", 1639);
@@ -409,7 +409,7 @@ void EnButte_Draw(Actor* thisx, GlobalContext* globalCtx) {
if (this->drawSkelAnime) {
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, NULL, NULL, NULL);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, NULL, NULL, NULL);
func_800628A4(0, &this->collider);
}
+29 -27
View File
@@ -47,10 +47,10 @@ static ColliderCylinderInit sCylinderInit = {
static Vec3f D_809E010C = { 0.0f, -1300.0f, 1100.0f };
extern AnimationHeader D_060001CC;
extern SkeletonHeader D_06004010;
extern FlexSkeletonHeader D_06004010;
extern AnimationHeader D_06004264;
extern AnimationHeader D_06004348;
extern SkeletonHeader D_06004C30;
extern FlexSkeletonHeader D_06004C30;
extern AnimationHeader D_06004E98;
void func_809DEE00(Vec3f* vec, s16 rotY) {
@@ -102,8 +102,8 @@ void EnCow_Init(Actor* thisx, GlobalContext* globalCtx) {
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 72.0f);
switch (this->actor.params) {
case 0:
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06004010, NULL, this->limbDrawTable,
this->transitionDrawTable, 6);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06004010, NULL, this->limbDrawTable,
this->transitionDrawTable, 6);
SkelAnime_ChangeAnimDefaultRepeat(&this->skelAnime, &D_060001CC);
Collider_InitCylinder(globalCtx, &this->colliders[0]);
Collider_SetCylinder(globalCtx, &this->colliders[0], &this->actor, &sCylinderInit);
@@ -129,8 +129,8 @@ void EnCow_Init(Actor* thisx, GlobalContext* globalCtx) {
DREG(53) = 0;
break;
case 1:
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06004C30, NULL, this->limbDrawTable,
this->transitionDrawTable, 6);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06004C30, NULL, this->limbDrawTable,
this->transitionDrawTable, 6);
SkelAnime_ChangeAnimDefaultRepeat(&this->skelAnime, &D_06004348);
this->actor.update = func_809DFE98;
this->actor.draw = func_809E0070;
@@ -160,12 +160,12 @@ void func_809DF494(EnCow* this, GlobalContext* globalCtx) {
} else {
this->unk_278 = Math_Rand_ZeroFloat(500.0f) + 40.0f;
SkelAnime_ChangeAnim(&this->skelAnime, &D_060001CC, 1.0f, this->skelAnime.animCurrentFrame,
SkelAnime_GetFrameCount(&D_060001CC.genericHeader), 2, 1.0f);
SkelAnime_GetFrameCount(&D_060001CC), 2, 1.0f);
}
if ((this->actor.xzDistFromLink < 150.0f) && (!(this->unk_276 & 2))) {
this->unk_276 |= 2;
if (this->skelAnime.animCurrentSeg == &D_060001CC) {
if (this->skelAnime.animation == &D_060001CC) {
this->unk_278 = 0;
}
}
@@ -276,13 +276,13 @@ void func_809DFA84(EnCow* this, GlobalContext* globalCtx) {
} else {
this->unk_278 = Math_Rand_ZeroFloat(200.0f) + 40.0f;
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004348, 1.0f, this->skelAnime.animCurrentFrame,
SkelAnime_GetFrameCount(&D_06004348.genericHeader), 2, 1.0f);
SkelAnime_GetFrameCount(&D_06004348), 2, 1.0f);
}
if ((this->actor.xzDistFromLink < 150.0f) &&
(ABS((s16)(this->actor.yawTowardsLink - this->actor.shape.rot.y)) >= 0x61A9) && (!(this->unk_276 & 2))) {
this->unk_276 |= 2;
if (this->skelAnime.animCurrentSeg == &D_06004348) {
if (this->skelAnime.animation == &D_06004348) {
this->unk_278 = 0;
}
}
@@ -301,13 +301,13 @@ void EnCow_Update(Actor* thisx, GlobalContext* globalCtx) {
Actor_MoveForward(thisx);
func_8002E4B4(globalCtx, thisx, 0.0f, 0.0f, 0.0f, 4);
if (SkelAnime_FrameUpdateMatrix(&this->skelAnime) != 0) {
if (this->skelAnime.animCurrentSeg == &D_060001CC) {
if (this->skelAnime.animation == &D_060001CC) {
Audio_PlayActorSound2(thisx, NA_SE_EV_COW_CRY);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004264, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06004264.genericHeader), 2, 1.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004264, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06004264), 2,
1.0f);
} else {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060001CC, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_060001CC.genericHeader), 0, 1.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060001CC, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060001CC), 0,
1.0f);
}
}
this->actionFunc(this, globalCtx);
@@ -341,18 +341,18 @@ void func_809DFE98(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
if (SkelAnime_FrameUpdateMatrix(&this->skelAnime) != 0) {
if (this->skelAnime.animCurrentSeg == &D_06004348) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004E98, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06004E98.genericHeader), 2, 1.0f);
if (this->skelAnime.animation == &D_06004348) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004E98, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06004E98), 2,
1.0f);
} else {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004348, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06004348.genericHeader), 0, 1.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004348, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06004348), 0,
1.0f);
}
}
this->actionFunc(this, globalCtx);
}
s32 EnCow_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnCow_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnCow* this = THIS;
if (limbIndex == 2) {
@@ -365,9 +365,11 @@ s32 EnCow_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnCow_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnCow_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnCow* this = THIS;
if (limbIndex == 2) {
Matrix_MultVec3f(&D_809E010C, &thisx->posRot2.pos);
Matrix_MultVec3f(&D_809E010C, &this->actor.posRot2.pos);
}
}
@@ -375,14 +377,14 @@ void EnCow_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnCow* this = THIS;
func_800943C8(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnCow_OverrideLimbDraw, EnCow_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnCow_OverrideLimbDraw, EnCow_PostLimbDraw, this);
}
void func_809E0070(Actor* thisx, GlobalContext* globalCtx) {
EnCow* this = THIS;
func_800943C8(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount, NULL,
NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
NULL, NULL, this);
}
+9 -10
View File
@@ -17,6 +17,9 @@ void EnCrow_Die(EnCrow* this, GlobalContext* globalCtx);
void func_809E1004(EnCrow* this, GlobalContext* globalCtx);
void func_809E0E2C(EnCrow* this, GlobalContext* globalCtx);
extern FlexSkeletonHeader D_060010C0;
extern AnimationHeader D_060000F0;
static Vec3f sZeroVecAccel = { 0.0f, 0.0f, 0.0f };
const ActorInit En_Crow_InitVars = {
@@ -60,15 +63,12 @@ static InitChainEntry sInitChain[] = {
static Vec3f sHeadVec[] = { 2500.0f, 0.0f, 0.0f };
extern SkeletonHeader D_060010C0;
extern AnimationHeader D_060000F0;
void EnCrow_Init(Actor* thisx, GlobalContext* globalCtx) {
EnCrow* this = THIS;
Actor_ProcessInitChain(&this->actor, sInitChain);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060010C0, &D_060000F0, &this->limbDrawTable,
&this->transitionDrawTable, 9);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060010C0, &D_060000F0, &this->limbDrawTable,
&this->transitionDrawTable, 9);
Collider_InitJntSph(globalCtx, &this->collider);
Collider_SetJntSph(globalCtx, &this->collider, &this->actor, &sJntSphInit, &this->colliderItems);
this->collider.list[0].dim.worldSphere.radius = sJntSphInit.list->dim.modelSphere.radius;
@@ -426,8 +426,7 @@ void EnCrow_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnCrow_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
s32 EnCrow_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnCrow* this = THIS;
if (this->actor.colChkInfo.health != 0) {
@@ -440,7 +439,7 @@ s32 EnCrow_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList
return false;
}
void EnCrow_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnCrow_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnCrow* this = THIS;
Vec3f* vec;
@@ -458,6 +457,6 @@ void EnCrow_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnCrow* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnCrow_OverrideLimbDraw, EnCrow_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnCrow_OverrideLimbDraw, EnCrow_PostLimbDraw, this);
}
+7 -7
View File
@@ -75,7 +75,7 @@ static InitChainEntry sInitChain[] = {
ICHAIN_VEC3F_DIV1000(scale, 10, ICHAIN_STOP),
};
extern SkeletonHeader D_06000BD8;
extern FlexSkeletonHeader D_06000BD8;
extern AnimationHeader D_060015B0;
void EnDha_SetupAction(EnDha* this, EnDhaActionFunc actionFunc) {
@@ -87,8 +87,8 @@ void EnDha_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_ProcessInitChain(&this->actor, sInitChain);
this->actor.colChkInfo.damageTable = &sDamageTable;
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06000BD8, &D_060015B0, this->limbDrawTable,
this->transitionDrawTable, 4);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06000BD8, &D_060015B0, this->limbDrawTable,
this->transitionDrawTable, 4);
ActorShape_Init(&this->actor.shape, 0, ActorShadow_DrawFunc_Teardrop, 90.0f);
this->actor.posRot2.pos = this->actor.posRot.pos;
this->actor.posRot2.pos.y += 50.0f;
@@ -343,7 +343,7 @@ void EnDha_Update(Actor* thisx, GlobalContext* globalCtx) {
CollisionCheck_SetOC(globalCtx, colChkCtx, &this->collider);
}
s32 EnDha_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnDha_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnDha* this = THIS;
s32 retVar;
@@ -365,7 +365,7 @@ s32 EnDha_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return retVar;
}
void EnDha_OverridePostDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnDha_OverridePostDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
Vec3f D_809ED764 = { 1100.0f, 0.0f, 0.0f };
Vec3f D_809ED770 = { 0.0f, 0.0f, 0.0f };
@@ -395,6 +395,6 @@ void EnDha_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnDha* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnDha_OverrideLimbDraw, EnDha_OverridePostDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnDha_OverrideLimbDraw, EnDha_OverridePostDraw, this);
}
+7 -7
View File
@@ -120,9 +120,9 @@ DnsAnimInfo D_809F0538[] = {
{ 0x060009A0, 0x02, 0.0f },
};
extern FlexSkeletonHeader D_060041A8;
extern AnimationHeader D_060009A0;
extern SkeletonHeader D_060041A8;
extern GenericAnimationHeader D_06004404;
extern AnimationHeader D_06004404;
void EnDns_Init(Actor* thisx, GlobalContext* globalCtx) {
EnDns* this = THIS;
@@ -141,8 +141,8 @@ void EnDns_Init(Actor* thisx, GlobalContext* globalCtx) {
osSyncPrintf(VT_FGCOL(GREEN) "◆◆◆ 売りナッツ『%s』 ◆◆◆" VT_RST "\n", D_809F0424[this->actor.params],
this->actor.params);
Actor_ProcessInitChain(&this->actor, sInitChain);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060041A8, &D_060009A0, this->limbDrawTable,
this->transitionDrawTable, 18);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060041A8, &D_060009A0, this->limbDrawTable,
this->transitionDrawTable, 18);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder_Set3(globalCtx, &this->collider, &this->actor, &sCylinderInit);
ActorShape_Init(&this->actor.shape, 0.0f, &ActorShadow_DrawFunc_Circle, 35.0f);
@@ -168,7 +168,7 @@ void EnDns_Destroy(Actor* thisx, GlobalContext* globalCtx) {
void EnDns_ChangeAnim(EnDns* this, u8 arg1) {
s16 frameCount;
frameCount = SkelAnime_GetFrameCount(&D_809F0538[arg1].anim->genericHeader);
frameCount = SkelAnime_GetFrameCount(D_809F0538[arg1].anim);
this->unk_2BA = arg1; // Not used anywhere else?
SkelAnime_ChangeAnim(&this->skelAnime, D_809F0538[arg1].anim, 1.0f, 0.0f, (f32)frameCount, D_809F0538[arg1].mode,
D_809F0538[arg1].transitionRate);
@@ -487,6 +487,6 @@ void EnDns_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnDns* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount, 0, 0,
&this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
NULL, NULL, &this->actor);
}
+9 -9
View File
@@ -65,14 +65,14 @@ typedef enum {
/* 0x06 */ DOG_BOW_2,
} DogBehavior;
extern SkeletonHeader D_06007290;
extern FlexSkeletonHeader D_06007290;
extern AnimationHeader D_06001368;
extern AnimationHeader D_06000D78;
extern AnimationHeader D_06000278;
void EnDog_PlayWalkSFX(EnDog* this) {
AnimationHeader* walk = &D_06001368;
if (this->skelAnime.animCurrentSeg == walk) {
if (this->skelAnime.animation == walk) {
if ((this->skelAnime.animCurrentFrame == 1.0f) || (this->skelAnime.animCurrentFrame == 7.0f)) {
Audio_PlayActorSound2(&this->actor, NA_SE_EV_CHIBI_WALK);
}
@@ -81,7 +81,7 @@ void EnDog_PlayWalkSFX(EnDog* this) {
void EnDog_PlayRunSFX(EnDog* this) {
AnimationHeader* run = &D_06000D78;
if (this->skelAnime.animCurrentSeg == run) {
if (this->skelAnime.animation == run) {
if ((this->skelAnime.animCurrentFrame == 2.0f) || (this->skelAnime.animCurrentFrame == 4.0f)) {
Audio_PlayActorSound2(&this->actor, NA_SE_EV_CHIBI_WALK);
}
@@ -90,7 +90,7 @@ void EnDog_PlayRunSFX(EnDog* this) {
void EnDog_PlayBarkSFX(EnDog* this) {
AnimationHeader* bark = &D_06000278;
if (this->skelAnime.animCurrentSeg == bark) {
if (this->skelAnime.animation == bark) {
if ((this->skelAnime.animCurrentFrame == 13.0f) || (this->skelAnime.animCurrentFrame == 19.0f)) {
Audio_PlayActorSound2(&this->actor, NA_SE_EV_SMALL_DOG_BARK);
}
@@ -226,7 +226,7 @@ void EnDog_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 24.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06007290, NULL, &this->unk_1F4, &this->unk_242, 13);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06007290, NULL, &this->unk_1F4, &this->unk_242, 13);
func_80034EC0(&this->skelAnime, sAnimations, 0);
if ((this->actor.params & 0x8000) == 0) {
@@ -441,11 +441,11 @@ void EnDog_Update(Actor* thisx, GlobalContext* globalCtx) {
CollisionCheck_SetOC(globalCtx, &globalCtx->colChkCtx, &this->collider);
}
s32 EnDog_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnDog_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
return 0;
}
void EnDog_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnDog_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
}
void EnDog_Draw(Actor* thisx, GlobalContext* globalCtx) {
@@ -460,8 +460,8 @@ void EnDog_Draw(Actor* thisx, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, colors[this->actor.params & 0xF].r, colors[this->actor.params & 0xF].g,
colors[this->actor.params & 0xF].b, colors[this->actor.params & 0xF].a);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnDog_OverrideLimbDraw, EnDog_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnDog_OverrideLimbDraw, EnDog_PostLimbDraw, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_dog.c", 994);
}
+8 -7
View File
@@ -29,14 +29,14 @@ const ActorInit En_Ds_InitVars = {
(ActorFunc)EnDs_Draw,
};
extern SkeletonHeader D_06004768;
extern FlexSkeletonHeader D_06004768;
extern AnimationHeader D_0600039C;
void EnDs_Init(Actor* thisx, GlobalContext* globalCtx) {
EnDs* this = THIS;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 36.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06004768, &D_0600039C, &this->limbDrawTable, &this->unk_1B4, 6);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06004768, &D_0600039C, &this->limbDrawTable, &this->unk_1B4, 6);
SkelAnime_ChangeAnimDefaultStop(&this->skelAnime, &D_0600039C);
this->actor.colChkInfo.mass = 0xFF;
@@ -254,7 +254,7 @@ void EnDs_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnDs_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnDs_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnDs* this = THIS;
if (limbIndex == 5) {
@@ -264,11 +264,12 @@ s32 EnDs_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnDs_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnDs_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
static Vec3f sMultVec = { 1100.0f, 500.0f, 0.0f };
EnDs* this = THIS;
if (limbIndex == 5) {
Matrix_MultVec3f(&sMultVec, &thisx->posRot2.pos);
Matrix_MultVec3f(&sMultVec, &this->actor.posRot2.pos);
}
}
@@ -276,6 +277,6 @@ void EnDs_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnDs* this = THIS;
func_800943C8(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnDs_OverrideLimbDraw, EnDs_PostLimbDraw, this);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnDs_OverrideLimbDraw, EnDs_PostLimbDraw, this);
}
+4 -4
View File
@@ -1462,8 +1462,8 @@ void EnElf_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnElf_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
struct Actor* thisx, Gfx** gfx) {
s32 EnElf_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
Gfx** gfx) {
static Vec3f zeroVec = { 0.0f, 0.0f, 0.0f };
s32 pad;
f32 scale;
@@ -1529,8 +1529,8 @@ void EnElf_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPEndDisplayList(dListHead++);
gDPSetEnvColor(POLY_XLU_DISP++, (u8)this->outerColor.r, (u8)this->outerColor.g, (u8)this->outerColor.b,
(u8)(envAlpha * alphaScale));
POLY_XLU_DISP = SkelAnime_Draw2(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl,
EnElf_OverrideLimbDraw, NULL, &this->actor, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl,
EnElf_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_elf.c", 2793);
}
@@ -78,7 +78,7 @@ static InitChainEntry sInitChain[] = {
extern Gfx D_06008688[];
extern SkeletonHeader D_06008FB0;
extern FlexSkeletonHeader D_06008FB0;
extern AnimationHeader D_06009DB0;
extern AnimationHeader D_060039B0;
@@ -99,8 +99,8 @@ void EnFloormas_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_ProcessInitChain(&this->actor, sInitChain);
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 50.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06008FB0, &D_06009DB0, &this->limbDrawTable,
&this->transitionDrawTable, 25);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06008FB0, &D_06009DB0, &this->limbDrawTable,
&this->transitionDrawTable, 25);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
func_80061ED4(&this->actor.colChkInfo, &sDamageTable, &sColChkInfoInit);
@@ -1049,7 +1049,7 @@ void EnFloormas_Update(Actor* thisx, GlobalContext* globalCtx) {
}
s32 EnFloormas_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx, Gfx** gfx) {
void* thisx, Gfx** gfx) {
EnFloormas* this = THIS;
if (limbIndex == 1) {
pos->z += this->zOffset;
@@ -1057,8 +1057,7 @@ s32 EnFloormas_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** d
return 0;
}
void EnFloormas_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx,
Gfx** gfx) {
void EnFloormas_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx, Gfx** gfx) {
if (limbIndex == 2) {
Matrix_Push();
Matrix_Translate(1600.0f, -700.0f, -1700.0f, MTXMODE_APPLY);
@@ -1084,8 +1083,8 @@ void EnFloormas_Draw(Actor* thisx, GlobalContext* globalCtx) {
}
POLY_OPA_DISP =
SkelAnime_DrawSV2(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnFloormas_OverrideLimbDraw, EnFloormas_PostLimbDraw, &this->actor, POLY_OPA_DISP);
SkelAnime_DrawFlex(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnFloormas_OverrideLimbDraw, EnFloormas_PostLimbDraw, this, POLY_OPA_DISP);
if (this->collider.base.type == COLTYPE_UNK12) {
func_80026608(globalCtx);
}
@@ -1103,8 +1102,8 @@ void EnFloormas_DrawHighlighted(Actor* thisx, GlobalContext* globalCtx) {
func_80026690(globalCtx, &sMergeColor, this->actionTarget % 0x28, 0x28);
}
POLY_XLU_DISP =
SkelAnime_DrawSV2(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnFloormas_OverrideLimbDraw, EnFloormas_PostLimbDraw, &this->actor, POLY_XLU_DISP);
SkelAnime_DrawFlex(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnFloormas_OverrideLimbDraw, EnFloormas_PostLimbDraw, this, POLY_XLU_DISP);
if (this->collider.base.type == COLTYPE_UNK12) {
func_80026A6C(globalCtx);
}
+10 -10
View File
@@ -64,7 +64,7 @@ static UNK_PTR sMouthSegments[] = {
extern AnimationHeader D_0600057C;
extern AnimationHeader D_06000B04;
extern SkeletonHeader D_06006C90;
extern FlexSkeletonHeader D_06006C90;
extern CutsceneData D_0200E080[];
typedef enum {
@@ -77,8 +77,8 @@ void EnFu_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 36.0f);
SkelAnime_InitSV(globalCtx, &this->skelanime, &D_06006C90, &D_06000B04, this->limbDrawTable,
this->transitionDrawTable, 16);
SkelAnime_InitFlex(globalCtx, &this->skelanime, &D_06006C90, &D_06000B04, this->limbDrawTable,
this->transitionDrawTable, 16);
SkelAnime_ChangeAnimDefaultRepeat(&this->skelanime, &D_06000B04);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
@@ -125,7 +125,7 @@ void func_80A1DA04(EnFu* this, GlobalContext* globalCtx) {
this->behaviorFlags &= ~FU_WAIT;
this->actionFunc = EnFu_WaitChild;
if (this->skelanime.animCurrentSeg == &D_0600057C) {
if (this->skelanime.animation == &D_0600057C) {
SkelAnime_ChangeAnim(&this->skelanime, &D_06000B04, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06000B04), 2,
-4.0f);
}
@@ -245,8 +245,8 @@ void EnFu_Update(Actor* thisx, GlobalContext* globalCtx) {
Actor_MoveForward(&this->actor);
func_8002E4B4(globalCtx, &this->actor, 0.0f, 0.0f, 0.0f, 4);
if ((!(this->behaviorFlags & FU_WAIT)) && (SkelAnime_FrameUpdateMatrix(&this->skelanime) != 0)) {
SkelAnime_ChangeAnim(&this->skelanime, this->skelanime.animCurrentSeg, 1.0f, 0.0f,
SkelAnime_GetFrameCount(this->skelanime.animCurrentSeg), 2, 0.0f);
SkelAnime_ChangeAnim(&this->skelanime, this->skelanime.animation, 1.0f, 0.0f,
SkelAnime_GetFrameCount(this->skelanime.animation), 2, 0.0f);
}
this->actionFunc(this, globalCtx);
if ((this->behaviorFlags & FU_RESET_LOOK_ANGLE)) {
@@ -260,7 +260,7 @@ void EnFu_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnFu_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnFu_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnFu* this = THIS;
s32 pad1;
@@ -287,7 +287,7 @@ s32 EnFu_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnFu_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnFu_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnFu* this = THIS;
if (limbIndex == 14) {
@@ -304,8 +304,8 @@ void EnFu_Draw(Actor* thisx, GlobalContext* globalCtx) {
func_800943C8(globalCtx->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyesSegments[this->facialExpression]));
gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(sMouthSegments[this->facialExpression]));
SkelAnime_DrawSV(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, this->skelanime.dListCount,
EnFu_OverrideLimbDraw, EnFu_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, this->skelanime.dListCount,
EnFu_OverrideLimbDraw, EnFu_PostLimbDraw, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_fu.c", 791);
}
@@ -49,7 +49,7 @@ static UNK_PTR D_80A50BA4[] = {
0x060007FC,
};
extern SkeletonHeader D_060000F0;
extern FlexSkeletonHeader D_060000F0;
extern AnimationHeader D_060042AC;
extern Gfx D_060059B0[];
@@ -84,11 +84,10 @@ void EnGuest_Update(Actor* thisx, GlobalContext* globalCtx) {
this->actor.flags &= ~0x10;
Actor_ProcessInitChain(&this->actor, sInitChain);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060000F0, NULL, this->limbDrawTable, this->transitionDrawTable,
16);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060000F0, NULL, this->limbDrawTable,
this->transitionDrawTable, 16);
gSegments[6] = VIRTUAL_TO_PHYSICAL(globalCtx->objectCtx.status[this->osAnimeBankIndex].segment);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060042AC, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_060042AC.genericHeader), 0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060042AC, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060042AC), 0, 0.0f);
this->actor.draw = EnGuest_Draw;
this->actor.update = func_80A505CC;
@@ -186,7 +185,7 @@ Gfx* func_80A50708(GraphicsContext* gfxCtx, u8 r, u8 g, u8 b, u8 a) {
}
s32 EnGuest_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnGuest* this = THIS;
Vec3s sp3C;
@@ -229,8 +228,8 @@ void EnGuest_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x09, func_80A50708(globalCtx->state.gfxCtx, 0xA0, 0x3C, 0xDC, 0xFF));
gSPSegment(POLY_OPA_DISP++, 0x0A, SEGMENTED_TO_VIRTUAL(D_80A50BA4[this->unk_30E]));
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnGuest_OverrideLimbDraw, NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnGuest_OverrideLimbDraw, NULL, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_guest.c", 421);
}
+5 -6
View File
@@ -45,7 +45,7 @@ void EnHata_Init(Actor* thisx, GlobalContext* globalCtx) {
f32 frameCount;
temp = 0;
frameCount = SkelAnime_GetFrameCount(&D_06000444.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06000444);
Actor_SetScale(&this->dyna.actor, 1.0f / 75.0f);
SkelAnime_Init(globalCtx, &this->skelAnime, &D_06002FD0, &D_06000444, NULL, NULL, 0);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000444, 1.0f, 0.0f, frameCount, 0, 0.0f);
@@ -103,8 +103,7 @@ void EnHata_Update(Actor* thisx, GlobalContext* globalCtx) {
THIS->skelAnime.animPlaybackSpeed = (Math_Rand_ZeroFloat(1.25f) + 2.75f) * (gblCtx->envCtx.unk_B0 / 255.0f);
}
s32 EnHata_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
s32 EnHata_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnHata* this = THIS;
Vec3s* limbs;
@@ -117,13 +116,13 @@ s32 EnHata_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList
return 0;
}
void EnHata_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnHata_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
}
void EnHata_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnHata* this = THIS;
func_800943C8(globalCtx->state.gfxCtx);
Matrix_Scale(1.0f, 1.1f, 1.0f, MTXMODE_APPLY);
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHata_OverrideLimbDraw,
EnHata_PostLimbDraw, &this->dyna.actor);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHata_OverrideLimbDraw,
EnHata_PostLimbDraw, this);
}
@@ -140,7 +140,7 @@ void EnHeishi1_Destroy(Actor* thisx, GlobalContext* globalCtx) {
}
void EnHeishi1_SetupWalk(EnHeishi1* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005880.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005880);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005880, this->animSpeed, 0.0f, (s16)frameCount, 0,
this->transitionRate);
@@ -224,7 +224,7 @@ void EnHeishi1_Walk(EnHeishi1* this, GlobalContext* globalCtx) {
}
void EnHeishi1_SetupMoveToLink(EnHeishi1* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005880.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005880);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005880, 3.0f, 0.0f, (s16)frameCount, 0, -3.0f);
this->bodyTurnSpeed = 0.0f;
@@ -252,7 +252,7 @@ void EnHeishi1_MoveToLink(EnHeishi1* this, GlobalContext* globalCtx) {
void EnHeishi1_SetupWait(EnHeishi1* this, GlobalContext* globalCtx) {
s16 rand;
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, this->animSpeed, 0.0f, (s16)frameCount, 0,
this->transitionRate);
@@ -322,7 +322,7 @@ void EnHeishi1_Wait(EnHeishi1* this, GlobalContext* globalCtx) {
}
void EnHeishi1_SetupTurnTowardLink(EnHeishi1* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->kickTimer = 30;
@@ -344,7 +344,7 @@ void EnHeishi1_TurnTowardLink(EnHeishi1* this, GlobalContext* globalCtx) {
}
void EnHeishi1_SetupKick(EnHeishi1* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->actionFunc = EnHeishi1_Kick;
@@ -370,7 +370,7 @@ void EnHeishi1_Kick(EnHeishi1* this, GlobalContext* globalCtx) {
}
void EnHeishi1_SetupWaitNight(EnHeishi1* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->actionFunc = EnHeishi1_WaitNight;
@@ -482,7 +482,7 @@ void EnHeishi1_Update(Actor* thisx, GlobalContext* globalCtx) {
}
s32 EnHeishi1_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnHeishi1* this = THIS;
// turn the guards head to match the direction he is looking
@@ -499,8 +499,8 @@ void EnHeishi1_Draw(Actor* thisx, GlobalContext* globalCtx) {
Vec3f matrixScale = { 0.3f, 0.3f, 0.3f };
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHeishi1_OverrideLimbDraw, NULL,
&this->actor);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHeishi1_OverrideLimbDraw,
NULL, this);
func_80033C30(&this->actor.posRot.pos, &matrixScale, 0xFF, globalCtx);
if ((this->path == BREG(1)) && (BREG(0) != 0)) {
@@ -166,7 +166,7 @@ void func_80A531D8(EnHeishi2* this, GlobalContext* globalCtx) {
}
void func_80A531E4(EnHeishi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->actionFunc = func_80A53278;
@@ -264,7 +264,7 @@ void func_80A53538(EnHeishi2* this, GlobalContext* globalCtx) {
}
void func_80A535BC(EnHeishi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005500.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005500);
this->unk_2EC = frameCount;
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005500, 1.0f, 0.0f, frameCount, 2, -10.0f);
@@ -301,7 +301,7 @@ void func_80A53638(EnHeishi2* this, GlobalContext* globalCtx) {
}
void func_80A5372C(EnHeishi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->unk_2F2[0] = 200;
@@ -337,7 +337,7 @@ void func_80A53850(EnHeishi2* this, GlobalContext* globalCtx) {
}
void func_80A53908(EnHeishi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->actionFunc = func_80A5399C;
@@ -430,7 +430,7 @@ void func_80A53C0C(EnHeishi2* this, GlobalContext* globalCtx) {
}
void func_80A53C90(EnHeishi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005500.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005500);
this->unk_2EC = frameCount;
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005500, 1.0f, 0.0f, frameCount, 2, -10.0f);
@@ -468,7 +468,7 @@ void func_80A53D0C(EnHeishi2* this, GlobalContext* globalCtx) {
}
void func_80A53DF8(EnHeishi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->unk_2F2[0] = 200;
@@ -593,7 +593,7 @@ void func_80A5427C(EnHeishi2* this, GlobalContext* globalCtx) {
}
void func_80A54320(EnHeishi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005500.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005500);
this->unk_2EC = frameCount;
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005500, 1.0f, 0.0f, frameCount, 2, -10.0f);
@@ -745,7 +745,7 @@ void func_80A5475C(EnHeishi2* this, GlobalContext* globalCtx) {
}
void func_80A54954(EnHeishi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->actionFunc = func_80A549E8;
@@ -801,7 +801,7 @@ void EnHeishi2_Update(Actor* thisx, GlobalContext* globalCtx) {
}
s32 EnHeishi2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnHeishi2* this = THIS;
switch (this->initParams) {
@@ -822,7 +822,7 @@ s32 EnHeishi2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dL
return 0;
}
void EnHeishi2_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnHeishi2_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnHeishi2* this = THIS;
if (limbIndex == 16) {
Matrix_Get(&this->mtxf_330);
@@ -848,8 +848,8 @@ void EnHeishi2_Draw(Actor* thisx, GlobalContext* globalCtx) {
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHeishi2_OverrideLimbDraw,
EnHeishi2_PostLimbDraw, &this->actor);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHeishi2_OverrideLimbDraw,
EnHeishi2_PostLimbDraw, this);
if ((this->initParams == 5) && (gSaveContext.infTable[7] & 0x80)) {
linkObjBankIndex = Object_GetIndex(&globalCtx->objectCtx, OBJECT_LINK_CHILD);
if (linkObjBankIndex >= 0) {
@@ -83,7 +83,7 @@ void EnHeishi3_Destroy(Actor* thisx, GlobalContext* globalCtx) {
}
void EnHeishi3_SetupGuardType(EnHeishi3* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
if (this->unk_278 == 0) {
@@ -159,7 +159,7 @@ void EnHeishi3_StandSentinelInCastle(EnHeishi3* this, GlobalContext* globalCtx)
}
void EnHeishi3_CatchStart(EnHeishi3* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005880.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005880);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005880, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->caughtTimer = 20;
@@ -182,7 +182,7 @@ void func_80A55BD4(EnHeishi3* this, GlobalContext* globalCtx) {
}
void EnHeishi3_ResetAnimationToIdle(EnHeishi3* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->actionFunc = func_80A55D00;
@@ -219,7 +219,7 @@ void EnHeishi3_Update(Actor* thisx, GlobalContext* globalCtx) {
}
s32 EnHeishi3_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnHeishi3* this = THIS;
if (limbIndex == 9) {
@@ -238,6 +238,6 @@ void EnHeishi3_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnHeishi3* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHeishi3_OverrideLimbDraw, NULL,
&this->actor);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHeishi3_OverrideLimbDraw,
NULL, this);
}
@@ -357,7 +357,7 @@ void EnHeishi4_Update(Actor* thisx, GlobalContext* globalCtx) {
}
s32 EnHeishi_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnHeishi4* this = THIS;
if (limbIndex == 9) {
@@ -374,6 +374,6 @@ void EnHeishi4_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnHeishi4* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHeishi_OverrideLimbDraw, NULL,
&this->actor);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHeishi_OverrideLimbDraw, NULL,
this);
}
@@ -514,7 +514,7 @@ void EnHintnuts_Update(Actor* thisx, GlobalContext* globalCtx) {
Actor_SetHeight(&this->actor, this->skelAnime.animCurrentFrame);
} else if (this->actionFunc == EnHintnuts_Burrow) {
Actor_SetHeight(&this->actor, 20.0f - ((this->skelAnime.animCurrentFrame * 20.0f) /
SkelAnime_GetFrameCount(&D_060024CC.genericHeader)));
SkelAnime_GetFrameCount(&D_060024CC)));
} else {
Actor_SetHeight(&this->actor, 20.0f);
}
@@ -522,7 +522,7 @@ void EnHintnuts_Update(Actor* thisx, GlobalContext* globalCtx) {
}
s32 EnHintnuts_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
Vec3f vec;
f32 animCurrentFrame;
EnHintnuts* this = THIS;
@@ -555,7 +555,7 @@ void EnHintnuts_Draw(Actor* thisx, GlobalContext* globalCtx) {
if (this->actor.params == 0xA) {
Gfx_DrawDListOpa(globalCtx, D_060014E0);
} else {
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHintnuts_OverrideLimbDraw,
NULL, &this->actor);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHintnuts_OverrideLimbDraw,
NULL, this);
}
}
@@ -224,11 +224,11 @@ void func_80A68B20(EnHorseGanon* this) {
if (animationChanged == 1) {
SkelAnime_ChangeAnim(&this->skin.skelAnime, D_80A691B0[this->currentAnimation],
sAnimPlaybackSpeeds[this->currentAnimation] * sp30 * 1.5f, 0.0f,
SkelAnime_GetFrameCount(&D_80A691B0[this->currentAnimation]->genericHeader), 2, -3.0f);
SkelAnime_GetFrameCount(D_80A691B0[this->currentAnimation]), 2, -3.0f);
} else {
SkelAnime_ChangeAnim(&this->skin.skelAnime, D_80A691B0[this->currentAnimation],
sAnimPlaybackSpeeds[this->currentAnimation] * sp30 * 1.5f, 0.0f,
SkelAnime_GetFrameCount(&D_80A691B0[this->currentAnimation]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(D_80A691B0[this->currentAnimation]), 2, 0.0f);
}
}
@@ -181,7 +181,7 @@ void func_80A6993C(EnHorseLinkChild* this, s32 newAnimationIdx) {
if (this->animationIdx != newAnimationIdx) {
this->animationIdx = newAnimationIdx;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, -5.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -5.0f);
}
}
@@ -199,11 +199,10 @@ void func_80A699FC(EnHorseLinkChild* this, GlobalContext* globalCtx) {
if (this->animationIdx != newAnimationIdx) {
this->animationIdx = newAnimationIdx;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2,
-5.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -5.0f);
} else {
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0);
}
}
}
@@ -214,7 +213,7 @@ void func_80A69B7C(EnHorseLinkChild* this) {
this->animationIdx = 0;
this->actor.speedXZ = 0.0f;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, -5.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -5.0f);
}
void func_80A69C18(EnHorseLinkChild* this, GlobalContext* globalCtx) {
@@ -260,10 +259,10 @@ void func_80A69C18(EnHorseLinkChild* this, GlobalContext* globalCtx) {
if (this->animationIdx != newAnimationIdx) {
this->animationIdx = newAnimationIdx;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, -5.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -5.0f);
} else {
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
}
}
@@ -273,7 +272,7 @@ void func_80A69EC0(EnHorseLinkChild* this) {
this->animationIdx = 0;
this->actor.speedXZ = 0.0f;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, -5.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -5.0f);
}
void func_80A69F5C(EnHorseLinkChild* this, GlobalContext* globalCtx) {
@@ -390,11 +389,11 @@ void func_80A6A068(EnHorseLinkChild* this, GlobalContext* globalCtx) {
if ((this->animationIdx != newAnimationIdx) || (animationEnded == true)) {
this->animationIdx = newAnimationIdx;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, -5.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -5.0f);
} else {
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this),
this->skin.skelAnime.animCurrentFrame,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
}
@@ -403,7 +402,7 @@ void func_80A6A4DC(EnHorseLinkChild* this) {
this->animationIdx = Math_Rand_ZeroOne() > 0.5f ? 0 : 1;
DREG(53) = 0;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
void func_80A6A5A4(EnHorseLinkChild* this, GlobalContext* globalCtx) {
@@ -425,9 +424,9 @@ void func_80A6A5A4(EnHorseLinkChild* this, GlobalContext* globalCtx) {
if (SkelAnime_FrameUpdateMatrix(&this->skin.skelAnime)) {
if (Math_Coss(yawDiff) < 0.0f) {
this->animationIdx = 2;
SkelAnime_ChangeAnim(
&this->skin.skelAnime, sAnimations[this->animationIdx], D_80A6AF64[this->animationIdx], 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, -5.0f);
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx],
D_80A6AF64[this->animationIdx], 0.0f,
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -5.0f);
} else {
func_80A6A4DC(this);
}
@@ -442,7 +441,7 @@ void func_80A6A724(EnHorseLinkChild* this) {
this->unk_1E8 = false;
this->actor.speedXZ = 2.0f;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, -5.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -5.0f);
}
void func_80A6A7D0(EnHorseLinkChild* this, GlobalContext* globalCtx) {
@@ -502,10 +501,10 @@ void func_80A6A7D0(EnHorseLinkChild* this, GlobalContext* globalCtx) {
if (this->animationIdx != newAnimationIdx) {
this->animationIdx = newAnimationIdx;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, -5.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -5.0f);
} else {
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A695A4(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
}
}
@@ -250,7 +250,7 @@ void func_80A6B91C(EnHorseNormal* this, GlobalContext* globalCtx) {
this->waypoint = 0;
this->actor.speedXZ = 7.0f;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
void EnHorseNormal_FollowPath(EnHorseNormal* this, GlobalContext* globalCtx) {
@@ -274,7 +274,7 @@ void EnHorseNormal_FollowPath(EnHorseNormal* this, GlobalContext* globalCtx) {
this->skin.skelAnime.animPlaybackSpeed = func_80A6B30C(this);
if (SkelAnime_FrameUpdateMatrix(&this->skin.skelAnime)) {
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
func_80A6BCEC(this);
}
}
@@ -306,7 +306,7 @@ void func_80A6BC48(EnHorseNormal* this) {
this->actor.speedXZ = 0.0f;
this->unk_218 = 0.0f;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
void func_80A6BCEC(EnHorseNormal* this) {
@@ -403,7 +403,7 @@ void EnHorseNormal_Wander(EnHorseNormal* this, GlobalContext* globalCtx) {
func_80A6BCEC(this);
}
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, -3.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -3.0f);
} else {
switch (D_80A6D510[this->animationIdx]) {
case 0:
@@ -434,11 +434,10 @@ void EnHorseNormal_Wander(EnHorseNormal* this, GlobalContext* globalCtx) {
if (phi_t0 != this->animationIdx) {
this->animationIdx = phi_t0;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2,
-3.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, -3.0f);
} else {
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
}
}
@@ -452,7 +451,7 @@ void func_80A6C4CC(EnHorseNormal* this) {
this->actor.speedXZ = 0.0f;
this->unk_218 = 0.0f;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
void EnHorseNormal_Wait(EnHorseNormal* this, GlobalContext* globalCtx) {
@@ -470,7 +469,7 @@ void EnHorseNormal_Wait(EnHorseNormal* this, GlobalContext* globalCtx) {
}
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
}
@@ -483,7 +482,7 @@ void func_80A6C6B0(EnHorseNormal* this) {
this->actor.speedXZ = 0.0f;
this->unk_218 = 0.0f;
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
}
void EnHorseNormal_WaitClone(EnHorseNormal* this, GlobalContext* globalCtx) {
@@ -505,7 +504,7 @@ void EnHorseNormal_WaitClone(EnHorseNormal* this, GlobalContext* globalCtx) {
}
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimations[this->animationIdx], func_80A6B30C(this), 0.0f,
SkelAnime_GetFrameCount(&sAnimations[this->animationIdx]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimations[this->animationIdx]), 2, 0.0f);
this->unk_1E4 &= ~1;
this->unk_1E4 &= ~2;
@@ -179,7 +179,7 @@ void func_80A6DD14(EnHorseZelda* this) {
Audio_PlaySoundGeneral(NA_SE_EV_HORSE_RUN, &this->actor.projectedPos, 4, &D_801333E0, &D_801333E0, &D_801333E8);
SkelAnime_ChangeAnim(&this->skin.skelAnime, sAnimationHeaders[this->animationIndex],
sAnimPlaybackSpeeds[this->animationIndex] * sp34 * 1.5f, 0.0f,
SkelAnime_GetFrameCount(&sAnimationHeaders[this->animationIndex]->genericHeader), 2, 0.0f);
SkelAnime_GetFrameCount(sAnimationHeaders[this->animationIndex]), 2, 0.0f);
}
void func_80A6DDFC(EnHorseZelda* this, GlobalContext* globalCtx) {
@@ -217,7 +217,7 @@ void EnHorseZelda_Update(Actor* thisx, GlobalContext* globalCtx) {
CollisionCheck_SetOC(globalCtx, &globalCtx->colChkCtx, &this->colliderCylinder.base);
}
void func_80A6DFD4(EnHorseZelda* this, GlobalContext* globalCtx, ColliderJntSphItem* colliderSphereItem) {
void func_80A6DFD4(EnHorseZelda* this, GlobalContext* globalCtx, PSkinAwb* skin) {
Vec3f sp4C;
Vec3f sp40;
s32 pad;
@@ -228,7 +228,7 @@ void func_80A6DFD4(EnHorseZelda* this, GlobalContext* globalCtx, ColliderJntSphI
sp4C.y = this->colliderSphere.list[i].dim.modelSphere.center.y;
sp4C.z = this->colliderSphere.list[i].dim.modelSphere.center.z;
func_800A6408(colliderSphereItem, this->colliderSphere.list[i].dim.joint, &sp4C, &sp40);
func_800A6408(skin, this->colliderSphere.list[i].dim.joint, &sp4C, &sp40);
this->colliderSphere.list[i].dim.worldSphere.center.x = sp40.x;
this->colliderSphere.list[i].dim.worldSphere.center.y = sp40.y;
+7 -7
View File
@@ -35,7 +35,7 @@ static ColliderCylinderInit sCylinderInit = {
{ 40, 40, 0, { 0, 0, 0 } },
};
extern SkeletonHeader D_06006260;
extern FlexSkeletonHeader D_06006260;
extern AnimationHeader D_060005C0;
void EnHs2_Init(Actor* thisx, GlobalContext* globalCtx) {
@@ -43,8 +43,8 @@ void EnHs2_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 36.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06006260, &D_060005C0, this->limbDrawTable,
this->transitionDrawTable, 16);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06006260, &D_060005C0, this->limbDrawTable,
this->transitionDrawTable, 16);
SkelAnime_ChangeAnimDefaultRepeat(&this->skelAnime, &D_060005C0);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
@@ -118,7 +118,7 @@ void EnHs2_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnHs2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* pos, Vec3s* rot, Actor* thisx) {
s32 EnHs2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* pos, Vec3s* rot, void* thisx) {
EnHs2* this = THIS;
switch (limbIndex) {
@@ -140,7 +140,7 @@ s32 EnHs2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnHs2_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnHs2_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
static Vec3f D_80A6F4CC = { 300.0f, 1000.0f, 0.0f };
EnHs2* this = THIS;
@@ -153,6 +153,6 @@ void EnHs2_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnHs2* this = THIS;
func_800943C8(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnHs2_OverrideLimbDraw, EnHs2_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnHs2_OverrideLimbDraw, EnHs2_PostLimbDraw, this);
}
+56 -54
View File
@@ -76,9 +76,9 @@ extern Gfx D_06016F88[];
extern Gfx D_06018E78[];
extern Gfx D_06019100[];
extern Gfx D_06019E08[];
extern SkeletonHeader D_0601E178;
extern FlexSkeletonHeader D_0601E178;
extern AnimationHeader D_060203D8;
extern SkeletonHeader D_060205C0;
extern FlexSkeletonHeader D_060205C0;
static ColliderCylinderInit sCylinderInit = {
{ COLTYPE_UNK10, 0x00, 0x09, 0x39, 0x20, COLSHAPE_CYLINDER },
@@ -217,7 +217,7 @@ Actor* func_80A74674(GlobalContext* globalCtx, Actor* actor) {
}
void func_80A74714(EnIk* this) {
f32 frames = SkelAnime_GetFrameCount(&D_0600CD70.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_0600CD70);
f32 frame;
if (this->actor.params >= 2) {
@@ -253,7 +253,7 @@ void func_80A747C0(EnIk* this, GlobalContext* globalCtx) {
}
void func_80A7489C(EnIk* this) {
f32 frames = SkelAnime_GetFrameCount(&D_0600DD50.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_0600DD50);
this->actor.flags |= 5;
this->unk_2F8 = 4;
@@ -286,11 +286,11 @@ void func_80A74AAC(EnIk* this) {
this->unk_2F8 = 5;
if (this->unk_2FB == 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600ED24, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_0600ED24.genericHeader), 0, -4.0f);
SkelAnime_GetFrameCount(&D_0600ED24), 0, -4.0f);
this->actor.speedXZ = 0.9f;
} else {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06006734, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06006734.genericHeader), 0, -4.0f);
SkelAnime_GetFrameCount(&D_06006734), 0, -4.0f);
Audio_PlayActorSound2(&this->actor, NA_SE_EN_IRONNACK_DASH);
this->actor.speedXZ = 2.5f;
}
@@ -358,7 +358,7 @@ void func_80A74BA4(EnIk* this, GlobalContext* globalCtx) {
}
void func_80A74E2C(EnIk* this) {
f32 frames = SkelAnime_GetFrameCount(&D_06001C28.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_06001C28);
this->unk_2FF = 1;
this->unk_2F8 = 6;
@@ -398,7 +398,7 @@ void func_80A74EBC(EnIk* this, GlobalContext* globalCtx) {
}
void func_80A7506C(EnIk* this) {
f32 frames = SkelAnime_GetFrameCount(&D_060029FC.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_060029FC);
this->unk_2FE = 0;
this->unk_2F9 = (s8)frames;
@@ -416,7 +416,7 @@ void func_80A7510C(EnIk* this, GlobalContext* globalCtx) {
if (this->unk_2F8 == 8) {
func_80A7489C(this);
} else {
frames = SkelAnime_GetFrameCount(&D_06002538.genericHeader);
frames = SkelAnime_GetFrameCount(&D_06002538);
this->unk_2F8 = 8;
SkelAnime_ChangeAnim(&this->skelAnime, &D_06002538, 1.5f, 0.0f, frames, 3, -4.0f);
}
@@ -424,7 +424,7 @@ void func_80A7510C(EnIk* this, GlobalContext* globalCtx) {
}
void func_80A751C8(EnIk* this) {
f32 frames = SkelAnime_GetFrameCount(&D_060033C4.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_060033C4);
this->unk_2FF = 2;
this->unk_300 = 0;
@@ -464,7 +464,7 @@ void func_80A75260(EnIk* this, GlobalContext* globalCtx) {
}
void func_80A753D0(EnIk* this) {
f32 frames = SkelAnime_GetFrameCount(&D_06003DBC.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_06003DBC);
this->unk_2FF = this->unk_2FE = 0;
this->unk_2F8 = 8;
@@ -480,7 +480,7 @@ void func_80A7545C(EnIk* this, GlobalContext* globalCtx) {
}
void func_80A754A0(EnIk* this) {
f32 frames = SkelAnime_GetFrameCount(&D_060033C4.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_060033C4);
this->unk_2F8 = 1;
this->unk_2FF = 3;
@@ -507,7 +507,7 @@ void func_80A75530(EnIk* this, GlobalContext* globalCtx) {
}
void func_80A755F0(EnIk* this) {
f32 frames = SkelAnime_GetFrameCount(&D_0600485C.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_0600485C);
this->unk_2FE = 0;
this->unk_2F8 = 9;
@@ -541,11 +541,11 @@ void func_80A75790(EnIk* this) {
yawDiff = yaw - this->actor.shape.rot.y;
if (ABS(yawDiff) <= 0x4000) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06006194, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06006194.genericHeader), 2, -4.0f);
SkelAnime_GetFrameCount(&D_06006194), 2, -4.0f);
this->actor.speedXZ = -6.0f;
} else {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060045BC, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_060045BC.genericHeader), 2, -4.0f);
SkelAnime_GetFrameCount(&D_060045BC), 2, -4.0f);
this->actor.speedXZ = 6.0f;
}
this->unk_2FE = 0;
@@ -568,7 +568,7 @@ void func_80A758B0(EnIk* this, GlobalContext* globalCtx) {
}
void func_80A7598C(EnIk* this) {
f32 frames = SkelAnime_GetFrameCount(&D_06005944.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_06005944);
this->unk_2FE = 0;
this->unk_2F8 = 2;
@@ -620,7 +620,7 @@ void func_80A75C38(EnIk* this, GlobalContext* globalCtx) {
return;
}
if (this->shieldCollider.base.acFlags & 0x80) {
temp_f0 = SkelAnime_GetFrameCount(&D_0600485C.genericHeader) - 2.0f;
temp_f0 = SkelAnime_GetFrameCount(&D_0600485C) - 2.0f;
if (this->skelAnime.animCurrentFrame < temp_f0) {
this->skelAnime.animCurrentFrame = temp_f0;
}
@@ -753,8 +753,8 @@ Gfx* func_80A761B0(GraphicsContext* gfxCtx, u8 primR, u8 primG, u8 primB, u8 env
return displayList;
}
s32 EnIk_OverrideLimbDraw3(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* actor) {
EnIk* this = (EnIk*)actor;
s32 EnIk_OverrideLimbDraw3(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnIk* this = THIS;
if (limbIndex == 12) {
if (this->actor.params != 0) {
@@ -798,10 +798,10 @@ static Vec3f D_80A784D0[] = {
{ -3000.0, -700.0, -5000.0 },
};
void EnIk_PostLimbDraw3(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* actor) {
void EnIk_PostLimbDraw3(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
Vec3f spF4;
Vec3f spE8;
EnIk* this = (EnIk*)actor;
EnIk* this = THIS;
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_en_ik_inFight.c", 1201);
@@ -901,8 +901,8 @@ void func_80A76798(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x09, func_80A761B0(globalCtx->state.gfxCtx, 225, 205, 115, 25, 20, 0));
gSPSegment(POLY_OPA_DISP++, 0x0A, func_80A761B0(globalCtx->state.gfxCtx, 225, 205, 115, 25, 20, 0));
}
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnIk_OverrideLimbDraw3, EnIk_PostLimbDraw3, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnIk_OverrideLimbDraw3, EnIk_PostLimbDraw3, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ik_inFight.c", 1351);
}
@@ -1018,7 +1018,7 @@ void func_80A77148(EnIk* this) {
}
void func_80A77158(EnIk* this, GlobalContext* globalCtx) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600C114, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600C114.genericHeader),
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600C114, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600C114),
2, 0.0f);
func_80A770C0(this, globalCtx, 4);
this->action = 1;
@@ -1027,7 +1027,7 @@ void func_80A77158(EnIk* this, GlobalContext* globalCtx) {
}
void func_80A771E4(EnIk* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600C114, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600C114.genericHeader),
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600C114, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600C114),
2, 0.0f);
this->action = 2;
this->drawMode = 1;
@@ -1057,10 +1057,10 @@ void func_80A772EC(EnIk* this, GlobalContext* globalCtx) {
void func_80A7735C(EnIk* this, GlobalContext* globalCtx) {
s32 pad[3];
f32 frames = SkelAnime_GetFrameCount(&D_060203D8.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_060203D8);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060205C0, NULL, this->limbDrawTable, this->transitionDrawTable,
30);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060205C0, NULL, this->limbDrawTable, this->transitionDrawTable,
30);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060203D8, 1.0f, 0.0f, frames, 2, 0.0f);
this->action = 3;
this->drawMode = 2;
@@ -1099,9 +1099,11 @@ void func_80A774F8(EnIk* this, GlobalContext* globalCtx) {
}
}
s32 EnIk_OverrideLimbDraw2(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* actor) {
s32 EnIk_OverrideLimbDraw2(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnIk* this = THIS;
if ((limbIndex == 13) || (limbIndex == 26) || (limbIndex == 27)) {
if (EnIk_AnimCurrentFrame(actor) >= 30.0f) {
if (EnIk_AnimCurrentFrame(&this->actor) >= 30.0f) {
*dList = NULL;
}
}
@@ -1109,21 +1111,20 @@ s32 EnIk_OverrideLimbDraw2(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnIk_PostLimbDraw2(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* actor) {
void EnIk_PostLimbDraw2(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
GraphicsContext* gfxCtx = globalCtx->state.gfxCtx;
OPEN_DISPS(gfxCtx, "../z_en_ik_inAwake.c", 207);
switch (limbIndex) {
case 13:
if (EnIk_AnimCurrentFrame(actor) < 30.0f) {
s32 pad;
case 13: {
EnIk* this = THIS;
if (EnIk_AnimCurrentFrame(&this->actor) < 30.0f) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(gfxCtx, "../z_en_ik_inAwake.c", 267),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, D_06016D88);
}
break;
} break;
case 22:
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(gfxCtx, "../z_en_ik_inAwake.c", 274),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
@@ -1134,26 +1135,27 @@ void EnIk_PostLimbDraw2(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Ve
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, D_06016EE8);
break;
case 26:
if (EnIk_AnimCurrentFrame(actor) < 30.0f) {
s32 pad;
case 26: {
EnIk* this = THIS;
if (EnIk_AnimCurrentFrame(&this->actor) < 30.0f) {
// s32 pad;
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(gfxCtx, "../z_en_ik_inAwake.c", 288),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, D_06016BE0);
}
break;
case 27:
if (EnIk_AnimCurrentFrame(actor) < 30.0f) {
s32 pad;
} break;
case 27: {
EnIk* this = THIS;
if (EnIk_AnimCurrentFrame(&this->actor) < 30.0f) {
// s32 pad;
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(gfxCtx, "../z_en_ik_inAwake.c", 297),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPDisplayList(POLY_XLU_DISP++, D_06016CD8);
}
break;
} break;
}
CLOSE_DISPS(gfxCtx, "../z_en_ik_inAwake.c", 304);
}
@@ -1170,8 +1172,8 @@ void func_80A77844(EnIk* this, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x08, func_80A761B0(gfxCtx, 245, 225, 155, 30, 30, 0));
gSPSegment(POLY_OPA_DISP++, 0x09, func_80A761B0(gfxCtx, 255, 40, 0, 40, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x0A, func_80A761B0(gfxCtx, 255, 255, 255, 20, 40, 30));
SkelAnime_DrawSV(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnIk_OverrideLimbDraw2, EnIk_PostLimbDraw2, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnIk_OverrideLimbDraw2, EnIk_PostLimbDraw2, this);
CLOSE_DISPS(gfxCtx, "../z_en_ik_inAwake.c", 345);
}
@@ -1250,8 +1252,8 @@ void EnIk_Update(Actor* thisx, GlobalContext* globalCtx) {
sActionFuncs[this->action](this, globalCtx);
}
s32 EnIk_OverrideLimbDraw1(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* actor) {
EnIk* this = (EnIk*)actor;
s32 EnIk_OverrideLimbDraw1(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnIk* this = THIS;
f32 animCurrentFrame;
switch (limbIndex) {
@@ -1272,7 +1274,7 @@ s32 EnIk_OverrideLimbDraw1(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnIk_PostLimbDraw1(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* actor) {
void EnIk_PostLimbDraw1(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
GraphicsContext* gfxCtx = globalCtx->state.gfxCtx;
OPEN_DISPS(gfxCtx, "../z_en_ik_inConfrontion.c", 571);
@@ -1324,8 +1326,8 @@ void func_80A77EDC(EnIk* this, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x08, func_80A761B0(gfxCtx, 245, 225, 155, 30, 30, 0));
gSPSegment(POLY_OPA_DISP++, 0x09, func_80A761B0(gfxCtx, 255, 40, 0, 40, 0, 0));
gSPSegment(POLY_OPA_DISP++, 0x0A, func_80A761B0(gfxCtx, 255, 255, 255, 20, 40, 30));
SkelAnime_DrawSV(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnIk_OverrideLimbDraw1, EnIk_PostLimbDraw1, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnIk_OverrideLimbDraw1, EnIk_PostLimbDraw1, this);
CLOSE_DISPS(gfxCtx, "../z_en_ik_inConfrontion.c", 653);
}
@@ -1389,8 +1391,8 @@ void EnIk_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_Kill(&this->actor);
} else {
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 30.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0601E178, &D_0600C114, this->limbDrawTable,
this->transitionDrawTable, 30);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0601E178, &D_0600C114, this->limbDrawTable,
this->transitionDrawTable, 30);
func_80A74398(&this->actor, globalCtx);
func_80A780D0(this, globalCtx);
}
@@ -780,7 +780,7 @@ void EnInsect_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnInsect* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, NULL, NULL, NULL);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, NULL, NULL, NULL);
func_800628A4(0, &this->collider);
D_80A7DEB4 = 0;
}
+11 -12
View File
@@ -35,7 +35,7 @@ static ColliderCylinderInit sCylinderInit = {
{ 30, 40, 0, { 0, 0, 0 } },
};
extern SkeletonHeader D_06005EA0;
extern FlexSkeletonHeader D_06005EA0;
extern AnimationHeader D_0600045C;
extern AnimationHeader D_0600018C;
@@ -48,8 +48,8 @@ void EnJs_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
ActorShape_Init(&this->actor.shape, 0.0f, NULL, 36.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06005EA0, &D_0600045C, this->limbDrawTable,
this->transitionDrawTable, 13);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06005EA0, &D_0600045C, this->limbDrawTable,
this->transitionDrawTable, 13);
SkelAnime_ChangeAnimDefaultStop(&this->skelAnime, &D_0600045C);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
@@ -87,8 +87,7 @@ u8 func_80A88F64(EnJs* this, GlobalContext* globalCtx, u16 textId) {
void func_80A89008(EnJs* this) {
En_Js_SetupAction(this, func_80A89304);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600045C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600045C.genericHeader),
2, -4.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600045C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600045C), 2, -4.0f);
}
void func_80A89078(EnJs* this, GlobalContext* globalCtx) {
@@ -144,8 +143,7 @@ void func_80A891C4(EnJs* this, GlobalContext* globalCtx) {
void func_80A89294(EnJs* this) {
En_Js_SetupAction(this, func_80A891C4);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600018C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600018C.genericHeader),
2, -4.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600018C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600018C), 2, -4.0f);
}
void func_80A89304(EnJs* this, GlobalContext* globalCtx) {
@@ -196,7 +194,7 @@ void EnJs_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnJs_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* pos, Vec3s* rot, Actor* thisx) {
s32 EnJs_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* pos, Vec3s* rot, void* thisx) {
EnJs* this = THIS;
if (limbIndex == 12) {
@@ -205,17 +203,18 @@ s32 EnJs_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnJs_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnJs_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
static Vec3f D_80A896DC = { 0.0f, 0.0f, 0.0f };
EnJs* this = THIS;
if (limbIndex == 12) {
Matrix_MultVec3f(&D_80A896DC, &thisx->posRot2.pos);
Matrix_MultVec3f(&D_80A896DC, &this->actor.posRot2.pos);
}
}
void EnJs_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnJs* this = THIS;
func_800943C8(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnJs_OverrideLimbDraw, EnJs_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnJs_OverrideLimbDraw, EnJs_PostLimbDraw, this);
}
@@ -29,7 +29,7 @@ static ColliderCylinderInit sCylinderInit = {
{ 20, 70, 0, { 0, 0, 0 } },
};
extern SkeletonHeader D_060065B0;
extern FlexSkeletonHeader D_060065B0;
extern AnimationHeader D_06000214;
const ActorInit En_Kakasi_InitVars = {
@@ -60,7 +60,7 @@ void EnKakasi_Init(Actor* thisx, GlobalContext* globalCtx) {
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
this->actor.unk_1F = 6;
SkelAnime_InitSV(globalCtx, &this->skelanime, &D_060065B0, &D_06000214, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelanime, &D_060065B0, &D_06000214, NULL, NULL, 0);
this->rot = this->actor.posRot.rot;
this->actor.flags |= 0x400;
@@ -161,7 +161,7 @@ void func_80A8F320(EnKakasi* this, GlobalContext* globalCtx, s16 arg) {
}
void func_80A8F660(EnKakasi* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06000214.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06000214);
SkelAnime_ChangeAnim(&this->skelanime, &D_06000214, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
@@ -338,6 +338,6 @@ void EnKakasi_Draw(Actor* thisx, GlobalContext* globalCtx) {
osSyncPrintf(VT_FGCOL(YELLOW) "☆☆☆☆☆ フラグ! ☆☆☆☆☆ %d\n" VT_RST, gSaveContext.scarecrowCustomSongSet);
}
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, this->skelanime.dListCount, NULL,
NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, this->skelanime.dListCount,
NULL, NULL, this);
}
@@ -28,7 +28,7 @@ void func_80A904D8(EnKakasi2* this, GlobalContext* globalCtx);
void func_80A90578(EnKakasi2* this, GlobalContext* globalCtx);
void func_80A906C4(EnKakasi2* this, GlobalContext* globalCtx);
extern SkeletonHeader D_060065B0;
extern FlexSkeletonHeader D_060065B0;
extern AnimationHeader D_06000214;
const ActorInit En_Kakasi2_InitVars = {
@@ -86,7 +86,7 @@ void EnKakasi2_Init(Actor* thisx, GlobalContext* globalCtx) {
this->actor.draw = func_80A90948;
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060065B0, &D_06000214, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060065B0, &D_06000214, NULL, NULL, 0);
this->actionFunc = func_80A9062C;
} else {
this->actionFunc = func_80A90264;
@@ -112,7 +112,7 @@ void func_80A90264(EnKakasi2* this, GlobalContext* globalCtx) {
this->actor.draw = func_80A90948;
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060065B0, &D_06000214, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060065B0, &D_06000214, NULL, NULL, 0);
func_80080480(globalCtx, this);
this->actor.flags |= 0x8000001;
@@ -137,7 +137,7 @@ void func_80A90264(EnKakasi2* this, GlobalContext* globalCtx) {
this->actor.draw = func_80A90948;
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060065B0, &D_06000214, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060065B0, &D_06000214, NULL, NULL, 0);
func_80080480(globalCtx, this);
func_80078884(NA_SE_SY_CORRECT_CHIME);
@@ -148,7 +148,7 @@ void func_80A90264(EnKakasi2* this, GlobalContext* globalCtx) {
}
void func_80A904D8(EnKakasi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06000214.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06000214);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000214, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
Audio_PlayActorSound2(&this->actor, NA_SE_EV_COME_UP_DEKU_JR);
@@ -175,7 +175,7 @@ void func_80A90578(EnKakasi2* this, GlobalContext* globalCtx) {
}
void func_80A9062C(EnKakasi2* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06000214.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06000214);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000214, 0.0f, 0.0f, (s16)frameCount, 2, -10.0f);
this->actionFunc = func_80A906C4;
@@ -230,6 +230,6 @@ void func_80A90948(Actor* thisx, GlobalContext* globalCtx) {
EnKakasi2* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount, NULL,
NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
NULL, NULL, this);
}
@@ -33,7 +33,7 @@ static ColliderCylinderInit sCylinderInit = {
{ 20, 70, 0, { 0, 0, 0 } },
};
extern SkeletonHeader D_060065B0;
extern FlexSkeletonHeader D_060065B0;
extern AnimationHeader D_06000214;
const ActorInit En_Kakasi3_InitVars = {
@@ -65,7 +65,7 @@ void EnKakasi3_Init(Actor* thisx, GlobalContext* globalCtx) {
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060065B0, &D_06000214, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060065B0, &D_06000214, NULL, NULL, 0);
this->actor.flags |= 0x400;
this->rot = this->actor.posRot.rot;
this->actor.colChkInfo.mass = 0xFF;
@@ -164,7 +164,7 @@ void func_80A90EBC(EnKakasi3* this, GlobalContext* globalCtx, s32 arg) {
}
void func_80A911F0(EnKakasi3* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06000214.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06000214);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000214, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
this->actionFunc = func_80A91284;
@@ -428,6 +428,6 @@ void EnKakasi3_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnKakasi3* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount, NULL,
NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
NULL, NULL, this);
}
+7 -7
View File
@@ -51,7 +51,7 @@ static struct_80034EC0_Entry sAnimations[] = {
{ 0x0600046C, 1.0f, 0.0f, -1.0f, 0x00, -10.0f },
};
extern SkeletonHeader D_060086D0;
extern FlexSkeletonHeader D_060086D0;
u16 EnKz_GetTextNoMaskChild(GlobalContext* globalCtx, EnKz* this) {
Player* player = PLAYER;
@@ -304,8 +304,8 @@ void EnKz_Init(Actor* thisx, GlobalContext* globalCtx) {
EnKz* this = THIS;
s32 pad;
SkelAnime_InitSV(globalCtx, &this->skelanime, &D_060086D0, NULL, &this->limbDrawTable, &this->transitionDrawTable,
12);
SkelAnime_InitFlex(globalCtx, &this->skelanime, &D_060086D0, NULL, &this->limbDrawTable, &this->transitionDrawTable,
12);
ActorShape_Init(&this->actor.shape, 0.0, NULL, 0.0);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
@@ -453,7 +453,7 @@ void EnKz_Update(Actor* thisx, GlobalContext* globalCtx) {
this->actionFunc(this, globalCtx);
}
s32 EnKz_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnKz_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
s32 limb = limbIndex;
if (limb == 8 || limb == 9 || limb == 10) {
@@ -463,7 +463,7 @@ s32 EnKz_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnKz_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnKz_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
s32 limb = limbIndex;
Vec3f mult = { 2600.0f, 0.0f, 0.0f };
@@ -484,8 +484,8 @@ void EnKz_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyeSegments[this->eyeIdx]));
func_800943C8(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, this->skelanime.dListCount,
EnKz_OverrideLimbDraw, EnKz_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, this->skelanime.dListCount,
EnKz_OverrideLimbDraw, EnKz_PostLimbDraw, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_kz.c", 1281);
}
+13 -13
View File
@@ -71,7 +71,7 @@ static UNK_PTR D_80AA16D0[] = {
};
extern AnimationHeader D_06000820;
extern SkeletonHeader D_06008460;
extern FlexSkeletonHeader D_06008460;
extern AnimationHeader D_06008D64;
u16 EnMa1_GetText(GlobalContext* globalCtx, Actor* thisx) {
@@ -206,7 +206,7 @@ void func_80AA0A0C(EnMa1* this) {
}
void func_80AA0A84(EnMa1* this, UNK_TYPE idx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_80AA1678[idx].animation->genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(D_80AA1678[idx].animation);
SkelAnime_ChangeAnim(&this->skelAnime, D_80AA1678[idx].animation, 1.0f, 0.0f, frameCount, D_80AA1678[idx].unk_08,
D_80AA1678[idx].transitionRate);
@@ -216,7 +216,7 @@ void func_80AA0AF4(EnMa1* this, GlobalContext* globalCtx) {
Player* player = PLAYER;
s16 phi_a3;
if ((this->unk_1E8.unk_00 == 0) && (this->skelAnime.animCurrentSeg == &D_06008D64)) {
if ((this->unk_1E8.unk_00 == 0) && (this->skelAnime.animation == &D_06008D64)) {
phi_a3 = 1;
} else {
phi_a3 = 0;
@@ -229,7 +229,7 @@ void func_80AA0AF4(EnMa1* this, GlobalContext* globalCtx) {
}
void func_80AA0B74(EnMa1* this) {
if (this->skelAnime.animCurrentSeg == &D_06008D64) {
if (this->skelAnime.animation == &D_06008D64) {
if (this->unk_1E8.unk_00 == 0) {
if (this->unk_1E0 != 0) {
this->unk_1E0 = 0;
@@ -249,7 +249,7 @@ void EnMa1_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 18.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06008460, NULL, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06008460, NULL, NULL, NULL, 0);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
func_80061EFC(&this->actor.colChkInfo, DamageTable_Get(0x16), &sColChkInfoInit);
@@ -282,11 +282,11 @@ void EnMa1_Destroy(Actor* thisx, GlobalContext* globalCtx) {
void func_80AA0D88(EnMa1* this, GlobalContext* globalCtx) {
if (this->unk_1E8.unk_00 != 0) {
if (this->skelAnime.animCurrentSeg != &D_06000820) {
if (this->skelAnime.animation != &D_06000820) {
func_80AA0A84(this, 1);
}
} else {
if (this->skelAnime.animCurrentSeg != &D_06008D64) {
if (this->skelAnime.animation != &D_06008D64) {
func_80AA0A84(this, 3);
}
}
@@ -324,11 +324,11 @@ void func_80AA0F44(EnMa1* this, GlobalContext* globalCtx) {
Player* player = PLAYER;
if (this->unk_1E8.unk_00 != 0) {
if (this->skelAnime.animCurrentSeg != &D_06000820) {
if (this->skelAnime.animation != &D_06000820) {
func_80AA0A84(this, 1);
}
} else {
if (this->skelAnime.animCurrentSeg != &D_06008D64) {
if (this->skelAnime.animation != &D_06008D64) {
func_80AA0A84(this, 3);
}
}
@@ -397,7 +397,7 @@ void EnMa1_Update(Actor* thisx, GlobalContext* globalCtx) {
func_80AA0AF4(this, globalCtx);
}
s32 EnMa1_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnMa1_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnMa1* this = THIS;
Vec3s vec;
@@ -419,7 +419,7 @@ s32 EnMa1_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnMa1_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnMa1_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnMa1* this = THIS;
Vec3f vec = D_80AA16B8;
@@ -444,8 +444,8 @@ void EnMa1_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(D_80AA16C4[this->unk_1E6]));
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80AA16D0[this->unk_1E4]));
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnMa1_OverrideLimbDraw, EnMa1_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnMa1_OverrideLimbDraw, EnMa1_PostLimbDraw, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ma1.c", 1261);
}
+11 -11
View File
@@ -63,7 +63,7 @@ static UNK_PTR D_80AA28C0[] = {
};
extern Gfx D_06005420[];
extern SkeletonHeader D_06008D90;
extern FlexSkeletonHeader D_06008D90;
extern AnimationHeader D_060093BC;
extern AnimationHeader D_06009EE0;
@@ -123,7 +123,7 @@ void func_80AA1AE4(EnMa2* this, GlobalContext* globalCtx) {
Player* player = PLAYER;
s16 phi_a3;
if ((this->unk_1E0.unk_00 == 0) && (this->skelAnime.animCurrentSeg == &D_06009EE0)) {
if ((this->unk_1E0.unk_00 == 0) && (this->skelAnime.animation == &D_06009EE0)) {
phi_a3 = 1;
} else {
phi_a3 = 0;
@@ -160,7 +160,7 @@ u16 func_80AA1B58(EnMa2* this, GlobalContext* globalCtx) {
}
s32 func_80AA1C68(EnMa2* this) {
if (this->skelAnime.animCurrentSeg != &D_06009EE0) {
if (this->skelAnime.animation != &D_06009EE0) {
return 0;
}
if (this->unk_1E0.unk_00 != 0) {
@@ -185,14 +185,14 @@ void func_80AA1CC0(EnMa2* this) {
}
void func_80AA1D44(EnMa2* this, s32 idx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_80AA2858[idx].animation->genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(D_80AA2858[idx].animation);
SkelAnime_ChangeAnim(&this->skelAnime, D_80AA2858[idx].animation, 1.0f, 0.0f, frameCount, D_80AA2858[idx].unk_08,
D_80AA2858[idx].transitionRate);
}
void func_80AA1DB4(EnMa2* this, GlobalContext* globalCtx) {
if (this->skelAnime.animCurrentSeg == &D_06009EE0) {
if (this->skelAnime.animation == &D_06009EE0) {
if (this->unk_1E0.unk_00 == 0) {
if (this->unk_20A != 0) {
func_800F6584(0);
@@ -212,7 +212,7 @@ void EnMa2_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 18.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06008D90, NULL, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06008D90, NULL, NULL, NULL, 0);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
func_80061EFC(&this->actor.colChkInfo, DamageTable_Get(0x16), &sColChkInfoInit);
@@ -322,7 +322,7 @@ void EnMa2_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnMa2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnMa2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnMa2* this = THIS;
Vec3s vec;
@@ -348,7 +348,7 @@ s32 EnMa2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnMa2_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnMa2_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnMa2* this = THIS;
Vec3f vec = D_80AA28A8;
@@ -357,7 +357,7 @@ void EnMa2_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Ve
if (limbIndex == 18) {
Matrix_MultVec3f(&vec, &this->actor.posRot2.pos);
}
if ((limbIndex == 14) && (this->skelAnime.animCurrentSeg == &D_060093BC)) {
if ((limbIndex == 14) && (this->skelAnime.animation == &D_060093BC)) {
gSPDisplayList(POLY_OPA_DISP++, D_06005420);
}
@@ -380,8 +380,8 @@ void EnMa2_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(D_80AA28B4[this->unk_210]));
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80AA28C0[this->unk_20E]));
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnMa2_OverrideLimbDraw, EnMa2_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnMa2_OverrideLimbDraw, EnMa2_PostLimbDraw, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ma2.c", 990);
}
+11 -11
View File
@@ -65,7 +65,7 @@ static UNK_PTR D_80AA38B0[] = {
};
extern u32 D_06005420;
extern SkeletonHeader D_06008D90;
extern FlexSkeletonHeader D_06008D90;
extern AnimationHeader D_060093BC;
extern AnimationHeader D_06009EE0;
@@ -180,7 +180,7 @@ void func_80AA2E54(EnMa3* this, GlobalContext* globalCtx) {
Player* player = PLAYER;
s16 phi_a3;
if ((this->unk_1E0.unk_00 == 0) && (this->skelAnime.animCurrentSeg == &D_06009EE0)) {
if ((this->unk_1E0.unk_00 == 0) && (this->skelAnime.animation == &D_06009EE0)) {
phi_a3 = 1;
} else {
phi_a3 = 0;
@@ -205,7 +205,7 @@ s32 func_80AA2EC8(EnMa3* this, GlobalContext* globalCtx) {
}
s32 func_80AA2F28(EnMa3* this) {
if (this->skelAnime.animCurrentSeg != &D_06009EE0) {
if (this->skelAnime.animation != &D_06009EE0) {
return 0;
}
if (this->unk_1E0.unk_00 != 0) {
@@ -230,7 +230,7 @@ void func_80AA2F80(EnMa3* this) {
}
void func_80AA3004(EnMa3* this, s32 idx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_80AA3848[idx].animation->genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(D_80AA3848[idx].animation);
SkelAnime_ChangeAnim(&this->skelAnime, D_80AA3848[idx].animation, 1.0f, 0.0f, frameCount, D_80AA3848[idx].unk_08,
D_80AA3848[idx].transitionRate);
@@ -241,7 +241,7 @@ void EnMa3_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 18.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06008D90, NULL, 0, 0, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06008D90, NULL, 0, 0, 0);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
func_80061EFC(&this->actor.colChkInfo, DamageTable_Get(0x16), &sColChkInfoInit);
@@ -302,7 +302,7 @@ void EnMa3_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnMa3_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnMa3_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnMa3* this = THIS;
Vec3s vec;
@@ -328,16 +328,16 @@ s32 EnMa3_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnMa3_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnMa3_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnMa3* this = THIS;
Vec3f vec = D_80AA3898;
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_en_ma3.c", 927);
if (limbIndex == 18) {
Matrix_MultVec3f(&vec, &thisx->posRot2.pos);
Matrix_MultVec3f(&vec, &this->actor.posRot2.pos);
}
if ((limbIndex == 14) && (this->skelAnime.animCurrentSeg == &D_060093BC)) {
if ((limbIndex == 14) && (this->skelAnime.animation == &D_060093BC)) {
gSPDisplayList(POLY_OPA_DISP++, &D_06005420);
}
@@ -360,8 +360,8 @@ void EnMa3_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(D_80AA38A4[this->unk_210]));
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80AA38B0[this->unk_20E]));
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnMa3_OverrideLimbDraw, EnMa3_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnMa3_OverrideLimbDraw, EnMa3_PostLimbDraw, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ma3.c", 1013);
}
+11 -11
View File
@@ -55,7 +55,7 @@ static struct_80034EC0_Entry sAnimations[] = {
};
extern AnimationHeader D_060002C8;
extern SkeletonHeader D_06007FB8;
extern FlexSkeletonHeader D_06007FB8;
void func_80AAA250(EnMd* this) {
f32 initialFrame;
@@ -307,7 +307,7 @@ void func_80AAAA24(EnMd* this) {
}
break;
}
} else if (this->skelAnime.animCurrentSeg != &D_060002C8) {
} else if (this->skelAnime.animation != &D_060002C8) {
func_80034EC0(&this->skelAnime, sAnimations, 10);
func_80AAA92C(this, 0);
}
@@ -593,8 +593,8 @@ void EnMd_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 24.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06007FB8, NULL, this->limbDrawTable, this->transitionDrawTable,
17);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06007FB8, NULL, this->limbDrawTable, this->transitionDrawTable,
17);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
@@ -633,7 +633,7 @@ void EnMd_Destroy(Actor* thisx, GlobalContext* globalCtx) {
}
void func_80AAB874(EnMd* this, GlobalContext* globalCtx) {
if (this->skelAnime.animCurrentSeg == &D_060002C8) {
if (this->skelAnime.animation == &D_060002C8) {
func_80034F54(globalCtx, &this->unk_214, &this->unk_236, 17);
} else if ((this->unk_1E0.unk_00 == 0) && (this->unk_20B != 7)) {
func_80AAA92C(this, 7);
@@ -643,7 +643,7 @@ void func_80AAB874(EnMd* this, GlobalContext* globalCtx) {
}
void func_80AAB8F8(EnMd* this, GlobalContext* globalCtx) {
if (this->skelAnime.animCurrentSeg == &D_060002C8) {
if (this->skelAnime.animation == &D_060002C8) {
func_80034F54(globalCtx, &this->unk_214, &this->unk_236, 17);
}
func_80AAA93C(this);
@@ -695,7 +695,7 @@ void func_80AAB948(EnMd* this, GlobalContext* globalCtx) {
return;
}
if (this->skelAnime.animCurrentSeg == &D_060002C8) {
if (this->skelAnime.animation == &D_060002C8) {
func_80034F54(globalCtx, &this->unk_214, &this->unk_236, 17);
}
@@ -772,7 +772,7 @@ void EnMd_Update(Actor* thisx, GlobalContext* globalCtx) {
this->actionFunc(this, globalCtx);
}
s32 EnMd_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx,
s32 EnMd_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
Gfx** gfx) {
EnMd* this = THIS;
Vec3s vec;
@@ -798,12 +798,12 @@ s32 EnMd_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnMd_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx, Gfx** gfx) {
s32 pad;
void EnMd_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx, Gfx** gfx) {
EnMd* this = THIS;
Vec3f vec = { 400.0f, 0.0f, 0.0f };
if (limbIndex == 16) {
Matrix_MultVec3f(&vec, &thisx->posRot2.pos);
Matrix_MultVec3f(&vec, &this->actor.posRot2.pos);
}
}
+5 -5
View File
@@ -53,7 +53,7 @@ static InitChainEntry sInitChain[] = {
};
extern AnimationHeader D_060005EC;
extern SkeletonHeader D_06003DC0;
extern FlexSkeletonHeader D_06003DC0;
void EnMs_SetOfferText(EnMs* this, GlobalContext* globalCtx) {
this->actor.textId = Text_GetFaceReaction(globalCtx, 0x1B);
@@ -75,8 +75,8 @@ void EnMs_Init(Actor* thisx, GlobalContext* globalCtx) {
return;
}
Actor_ProcessInitChain(&this->actor, sInitChain);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06003DC0, &D_060005EC, &this->unkSkelAnimeStruct, &this->unk_1C6,
9);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06003DC0, &D_060005EC, &this->unkSkelAnimeStruct, &this->unk_1C6,
9);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder_Set3(globalCtx, &this->collider, this, &sCylinderInit);
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 35.0f);
@@ -183,6 +183,6 @@ void EnMs_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnMs* this = THIS;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount, NULL,
NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
NULL, NULL, this);
}
+6 -6
View File
@@ -91,7 +91,7 @@ static InitChainEntry sInitChain[] = {
ICHAIN_F32(unk_4C, 0, ICHAIN_STOP),
};
extern SkeletonHeader D_06002530;
extern FlexSkeletonHeader D_06002530;
extern AnimationHeader D_060000E8;
extern Gfx D_060023B0[];
extern Gfx D_06002428[];
@@ -130,8 +130,8 @@ void EnNiw_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_ProcessInitChain(&this->actor, sInitChain);
this->actor.flags |= 1;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 25.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06002530, &D_060000E8, this->limbDrawTable,
this->transitionDrawTable, 16);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06002530, &D_060000E8, this->limbDrawTable,
this->transitionDrawTable, 16);
if (globalCtx->sceneNum == SCENE_SPOT01) {
for (i = 0; i < ARRAY_COUNT(sKakarikoPosList); i++) {
@@ -1084,7 +1084,7 @@ void EnNiw_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnNiw_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnNiw_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnNiw* this = THIS;
Vec3f zeroVec = { 0.0f, 0.0f, 0.0f };
@@ -1114,8 +1114,8 @@ void EnNiw_Draw(Actor* thisx, GlobalContext* globalCtx) {
GraphicsContext* gfxCtx = globalCtx->state.gfxCtx;
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnNiw_OverrideLimbDraw, NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnNiw_OverrideLimbDraw, NULL, this);
if (this->actionFunc == func_80AB6450) {
func_80033C30(&this->actor.posRot.pos, &scale, 255, globalCtx);
@@ -42,7 +42,7 @@ static Vec3f sConstVec3f = { 0.2f, 0.2f, 0.2f };
static Gfx* D_80AB99D8[] = { 0x06004178, 0x06004978, 0x06005178 };
extern SkeletonHeader D_06009948;
extern FlexSkeletonHeader D_06009948;
extern AnimationHeader D_06000378;
extern AnimationHeader D_06009C78;
@@ -53,8 +53,8 @@ void EnNiwGirl_Init(Actor* thisx, GlobalContext* globalCtx) {
Vec3f vec2;
s32 pad2;
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06009948, &D_06000378, &this->limbDrawTable,
&this->transitionDrawTable, 17);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06009948, &D_06000378, &this->limbDrawTable,
&this->transitionDrawTable, 17);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
this->actor.unk_1F = 6;
@@ -223,7 +223,7 @@ void EnNiwGirl_Update(Actor* thisx, GlobalContext* globalCtx) {
}
s32 EnNiwGirlOverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnNiwGirl* this = THIS;
if (limbIndex == 3) {
@@ -245,8 +245,8 @@ void EnNiwGirl_Draw(Actor* thisx, GlobalContext* globalCtx) {
func_80093D18(globalCtx->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80AB99D8[this->unk_272]));
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnNiwGirlOverrideLimbDraw, 0, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnNiwGirlOverrideLimbDraw, 0, this);
func_80033C30(&this->actor.posRot.pos, &sp4C, 255, globalCtx);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_niw_girl.c", 592);
@@ -51,7 +51,7 @@ static ColliderCylinderInit sCylinderInit = {
{ 10, 10, 0, { 0, 0, 0 } },
};
extern SkeletonHeader D_060000F0;
extern FlexSkeletonHeader D_060000F0;
extern AnimationHeader D_06000718;
extern AnimationHeader D_060007D0;
extern AnimationHeader D_06009F94;
@@ -146,8 +146,8 @@ void func_80AB9F24(EnNiwLady* this, GlobalContext* globalCtx) {
if (Object_IsLoaded(&globalCtx->objectCtx, this->objectAneIndex) &&
Object_IsLoaded(&globalCtx->objectCtx, this->objectOsAnimeIndex)) {
gSegments[6] = VIRTUAL_TO_PHYSICAL(globalCtx->objectCtx.status[this->objectAneIndex].segment);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_060000F0, NULL, &this->limbDrawTable,
&this->transitionDrawTable, 16);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_060000F0, NULL, this->limbDrawTable,
this->transitionDrawTable, 16);
gSegments[6] = VIRTUAL_TO_PHYSICAL(globalCtx->objectCtx.status[this->objectOsAnimeIndex].segment);
this->unk_27E = 1;
this->actor.gravity = -3.0f;
@@ -211,7 +211,7 @@ void func_80ABA244(EnNiwLady* this, GlobalContext* globalCtx) {
gSaveContext.infTable[25] &= ~D_80ABB3B4[currentCucco->unk_2AA];
}
}
currentCucco = currentCucco->actor.next;
currentCucco = (EnNiw*)currentCucco->actor.next;
}
if (BREG(7) != 0) {
this->cuccosInPen = BREG(7) - 1;
@@ -522,7 +522,7 @@ void EnNiwLady_Update(Actor* thisx, GlobalContext* globalCtx) {
func_8002E4B4(globalCtx, thisx, 20.0f, 20.0f, 60.0f, 0x1D);
Collider_CylinderUpdate(thisx, &this->collider);
if (1) {}
CollisionCheck_SetOC(globalCtx, &globalCtx->colChkCtx, &this->collider);
CollisionCheck_SetOC(globalCtx, &globalCtx->colChkCtx, &this->collider.base);
}
}
}
@@ -536,7 +536,7 @@ Gfx* func_80ABB0A0(GraphicsContext* gfxCtx) {
}
s32 EnNiwLady_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnNiwLady* this = THIS;
s32 pad;
@@ -567,8 +567,8 @@ void EnNiwLady_Draw(Actor* thisx, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80ABB408[this->faceState]));
gSPSegment(POLY_OPA_DISP++, 0x0C, func_80ABB0A0(globalCtx->state.gfxCtx));
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnNiwLady_OverrideLimbDraw, 0, thisx);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl,
this->skelAnime.dListCount, EnNiwLady_OverrideLimbDraw, NULL, this);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_niw_lady.c", 1370);
}
@@ -657,8 +657,8 @@ void EnOkuta_Draw(Actor* thisx, GlobalContext* globalCtx) {
func_80093D18(globalCtx->state.gfxCtx);
if (this->actor.params == 0) {
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnOkuta_OverrideLimbDraw, NULL,
&this->actor);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnOkuta_OverrideLimbDraw,
NULL, this);
} else {
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_en_okuta.c", 1653);
+21 -27
View File
@@ -73,7 +73,7 @@ static Vec3f D_80AE4940 = { 300.0f, 0.0f, 0.0f };
static Vec3f D_80AE494C = { 300.0f, 0.0f, 0.0f };
static Vec3f D_80AE4958 = { 0.25f, 0.25f, 0.25f };
extern SkeletonHeader D_06003DD8;
extern FlexSkeletonHeader D_06003DD8;
extern AnimationHeader D_06004268;
extern AnimationHeader D_060046F8;
extern AnimationHeader D_06004ADC;
@@ -84,7 +84,7 @@ extern AnimationHeader D_06006E88;
extern AnimationHeader D_060074F0;
extern AnimationHeader D_06008040;
extern AnimationHeader D_060087D0;
extern SkeletonHeader D_0600E778;
extern FlexSkeletonHeader D_0600E778;
extern AnimationHeader D_0600EFDC;
void EnRd_SetupAction(EnRd* this, EnRdActionFunc actionFunc) {
@@ -113,12 +113,12 @@ void EnRd_Init(Actor* thisx, GlobalContext* globalCtx) {
}
if (thisx->params >= -1) {
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0600E778, &D_060087D0, this->limbDrawTable,
this->transitionDrawTable, 26);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0600E778, &D_060087D0, this->limbDrawTable,
this->transitionDrawTable, 26);
thisx->naviEnemyId = 42;
} else {
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06003DD8, &D_060087D0, this->limbDrawTable,
this->transitionDrawTable, 26);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06003DD8, &D_060087D0, this->limbDrawTable,
this->transitionDrawTable, 26);
thisx->naviEnemyId = 45;
}
@@ -231,8 +231,7 @@ void func_80AE2744(EnRd* this, GlobalContext* globalCtx) {
}
void func_80AE2970(EnRd* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060087D0, 0, 0, SkelAnime_GetFrameCount(&D_060087D0.genericHeader), 0,
-6.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060087D0, 0, 0, SkelAnime_GetFrameCount(&D_060087D0), 0, -6.0f);
this->unk_31B = 0xB;
this->unk_30C = 6;
this->actor.shape.rot.x = -0x4000;
@@ -268,8 +267,7 @@ void func_80AE2A10(EnRd* this, GlobalContext* globalCtx) {
}
void func_80AE2B90(EnRd* this, GlobalContext* globalCtx) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600EFDC, 1.0f, 4.0f, SkelAnime_GetFrameCount(&D_0600EFDC.genericHeader),
1, -4.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600EFDC, 1.0f, 4.0f, SkelAnime_GetFrameCount(&D_0600EFDC), 1, -4.0f);
this->actor.speedXZ = 0.4f;
this->unk_31B = 4;
EnRd_SetupAction(this, func_80AE2C1C);
@@ -336,8 +334,7 @@ void func_80AE2C1C(EnRd* this, GlobalContext* globalCtx) {
}
void func_80AE2F50(EnRd* this, GlobalContext* globalCtx) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600EFDC, 0.5f, 0, SkelAnime_GetFrameCount(&D_0600EFDC.genericHeader), 1,
-4.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600EFDC, 0.5f, 0, SkelAnime_GetFrameCount(&D_0600EFDC), 1, -4.0f);
this->unk_31B = 2;
EnRd_SetupAction(this, func_80AE2FD0);
}
@@ -385,8 +382,7 @@ void func_80AE2FD0(EnRd* this, GlobalContext* globalCtx) {
}
void func_80AE31DC(EnRd* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600EFDC, 0.5f, 0, SkelAnime_GetFrameCount(&D_0600EFDC.genericHeader), 1,
-4.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600EFDC, 0.5f, 0, SkelAnime_GetFrameCount(&D_0600EFDC), 1, -4.0f);
this->unk_31B = 3;
this->unk_305 = 1;
EnRd_SetupAction(this, func_80AE3260);
@@ -459,8 +455,8 @@ void func_80AE3454(EnRd* this, GlobalContext* globalCtx) {
Math_SmoothScaleMaxMinS(&this->unk_310, 0, 1, 0x5DC, 0);
case 2:
if (!(player->stateFlags2 & 0x80)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060046F8, 0.5f, 0.0f,
SkelAnime_GetFrameCount(&D_060046F8.genericHeader), 3, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060046F8, 0.5f, 0.0f, SkelAnime_GetFrameCount(&D_060046F8), 3,
0.0f);
this->unk_304++;
this->unk_31B = 4;
return;
@@ -510,8 +506,7 @@ void func_80AE3454(EnRd* this, GlobalContext* globalCtx) {
}
void func_80AE37BC(EnRd* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004F94, 0.0f, 0.0f, SkelAnime_GetFrameCount(&D_06004F94.genericHeader),
2, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004F94, 0.0f, 0.0f, SkelAnime_GetFrameCount(&D_06004F94), 2, 0.0f);
this->unk_31B = 7;
EnRd_SetupAction(this, func_80AE3834);
}
@@ -551,8 +546,7 @@ void func_80AE3978(EnRd* this, GlobalContext* globalCtx) {
}
void func_80AE39D4(EnRd* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06008040, -1.0f, SkelAnime_GetFrameCount(&D_06008040.genericHeader), 0.0f,
2, -4.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06008040, -1.0f, SkelAnime_GetFrameCount(&D_06008040), 0.0f, 2, -4.0f);
this->unk_31B = 6;
EnRd_SetupAction(this, func_80AE3A54);
}
@@ -798,7 +792,7 @@ void EnRd_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnRd_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx,
s32 EnRd_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
Gfx** gfx) {
EnRd* this = THIS;
@@ -810,7 +804,7 @@ s32 EnRd_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnRd_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx, Gfx** gfx) {
void EnRd_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx, Gfx** gfx) {
Vec3f sp2C = D_80AE4940;
EnRd* this = THIS;
s32 idx = -1;
@@ -870,9 +864,9 @@ void EnRd_Draw(Actor* thisx, GlobalContext* globalCtx) {
func_80093D18(globalCtx->state.gfxCtx);
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, this->unk_314);
gSPSegment(POLY_OPA_DISP++, 8, &D_80116280[2]);
POLY_OPA_DISP = SkelAnime_DrawSV2(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl,
this->skelAnime.dListCount, EnRd_OverrideLimbDraw, EnRd_PostLimbDraw,
&this->actor, POLY_OPA_DISP);
POLY_OPA_DISP = SkelAnime_DrawFlex(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl,
this->skelAnime.dListCount, EnRd_OverrideLimbDraw, EnRd_PostLimbDraw, this,
POLY_OPA_DISP);
func_80033C30(&thisPos, &D_80AE4958, 255, globalCtx);
if (this->unk_31A != 0) {
this->actor.dmgEffectTimer++;
@@ -887,8 +881,8 @@ void EnRd_Draw(Actor* thisx, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->unk_314);
gSPSegment(POLY_XLU_DISP++, 8, &D_80116280[0]);
POLY_XLU_DISP =
SkelAnime_DrawSV2(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl,
this->skelAnime.dListCount, EnRd_OverrideLimbDraw, NULL, &this->actor, POLY_XLU_DISP);
SkelAnime_DrawFlex(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl,
this->skelAnime.dListCount, EnRd_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
func_80033C30(&thisPos, &D_80AE4958, this->unk_314, globalCtx);
}
@@ -123,7 +123,7 @@ void EnReeba_Destroy(Actor* thisx, GlobalContext* globalCtx) {
}
void func_80AE4F40(EnReeba* this, GlobalContext* globalCtx) {
f32 frames = SkelAnime_GetFrameCount(&D_060001E4.genericHeader);
f32 frames = SkelAnime_GetFrameCount(&D_060001E4);
Player* player = PLAYER;
s16 playerSpeed;
@@ -620,7 +620,7 @@ void EnReeba_Draw(Actor* thisx, GlobalContext* globalCtx) {
gDPSetPrimColor(POLY_OPA_DISP++, 0x0, 0x01, 255, 255, 255, 255);
}
SkelAnime_Draw(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, NULL, NULL, &this->actor);
SkelAnime_DrawOpa(globalCtx, this->skelanime.skeleton, this->skelanime.limbDrawTbl, NULL, NULL, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_reeba.c", 1088);
+13 -17
View File
@@ -30,7 +30,7 @@ void func_80AE7D94(EnRl* this, GlobalContext* globalCtx);
static UNK_PTR D_80AE81A0[] = { 0x06003620, 0x06003960, 0x06003B60 };
extern SkeletonHeader D_06007B38;
extern FlexSkeletonHeader D_06007B38;
extern AnimationHeader D_06000A3C;
extern AnimationHeader D_06000830;
extern AnimationHeader D_0600040C;
@@ -57,8 +57,7 @@ void func_80AE72D0(EnRl* this) {
}
void func_80AE7358(EnRl* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000A3C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06000A3C.genericHeader),
0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000A3C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06000A3C), 0, 0.0f);
this->action = 4;
this->drawConfig = 0;
this->alpha = 0;
@@ -115,7 +114,7 @@ s32 func_80AE74FC(EnRl* this, GlobalContext* globalCtx, u16 arg2, s32 arg3) {
}
void func_80AE7544(EnRl* this, GlobalContext* globalCtx) {
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06007B38, &D_06000A3C, 0, 0, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06007B38, &D_06000A3C, 0, 0, 0);
}
void func_80AE7590(EnRl* this, GlobalContext* globalCtx) {
@@ -151,8 +150,8 @@ void func_80AE7698(EnRl* this, GlobalContext* globalCtx) {
if (globalCtx->csCtx.state != 0) {
csCmdActorAction = globalCtx->csCtx.npcActions[0];
if (csCmdActorAction != NULL && csCmdActorAction->action == 3) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600040C, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_0600040C.genericHeader), 2, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600040C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600040C), 2,
0.0f);
this->action = 2;
}
}
@@ -160,8 +159,7 @@ void func_80AE7698(EnRl* this, GlobalContext* globalCtx) {
void func_80AE772C(EnRl* this, s32 arg1) {
if (arg1) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000830, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06000830.genericHeader), 0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000830, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06000830), 0, 0.0f);
this->action = 3;
}
}
@@ -194,7 +192,7 @@ void func_80AE7838(EnRl* this, GlobalContext* globalCtx) {
}
void func_80AE7878(EnRl* this, GlobalContext* globalCtx) {
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06007B38, &D_06000A3C, 0, 0, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06007B38, &D_06000A3C, 0, 0, 0);
this->action = 4;
this->actor.shape.unk_14 = 0;
}
@@ -246,8 +244,7 @@ void func_80AE79A4(EnRl* this, GlobalContext* globalCtx) {
void func_80AE7AF8(EnRl* this, GlobalContext* globalCtx) {
if (func_80AE74B4(this, globalCtx, 3, 0)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600040C, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_0600040C.genericHeader), 2, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600040C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_0600040C), 2, -8.0f);
this->action = 6;
} else if (func_80AE74FC(this, globalCtx, 4, 0)) {
this->action = 5;
@@ -264,8 +261,7 @@ void func_80AE7AF8(EnRl* this, GlobalContext* globalCtx) {
void func_80AE7BF8(EnRl* this, s32 arg1) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000830, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06000830.genericHeader), 0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000830, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06000830), 0, 0.0f);
this->action = 7;
}
}
@@ -316,8 +312,8 @@ void func_80AE7D94(EnRl* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->alpha);
gSPSegment(POLY_XLU_DISP++, 0x0C, D_80116280);
POLY_XLU_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
NULL, NULL, NULL, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
NULL, NULL, NULL, POLY_XLU_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_rl_inKenjyanomaDemo02.c", 331);
}
@@ -365,8 +361,8 @@ void func_80AE7FDC(EnRl* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
gSPSegment(POLY_OPA_DISP++, 0x0C, &D_80116280[2]);
SkelAnime_DrawSV(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount, NULL, NULL,
&this->actor);
SkelAnime_DrawFlexOpa(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount, NULL, NULL,
&this->actor);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_rl.c", 437);
}
+44 -55
View File
@@ -151,7 +151,7 @@ extern AnimationHeader D_06008100;
extern AnimationHeader D_06008AA8;
extern AnimationHeader D_06009060;
extern AnimationHeader D_060097B8;
extern SkeletonHeader D_06012700;
extern FlexSkeletonHeader D_06012700;
extern AnimationHeader D_06012E94;
extern AnimationHeader D_06013A64;
@@ -376,8 +376,8 @@ void func_80AEB220(EnRu1* this, GlobalContext* globalCtx) {
void func_80AEB264(EnRu1* this, AnimationHeader* animation, u8 arg2, f32 transitionRate, s32 arg4) {
s32 pad[2];
AnimationHeader* animationHeader = SEGMENTED_TO_VIRTUAL(&animation->genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&animationHeader->genericHeader);
AnimationHeader* animHeader = SEGMENTED_TO_VIRTUAL(animation);
f32 frameCount = SkelAnime_GetFrameCount(animHeader);
f32 playbackSpeed;
f32 unk0;
f32 fc;
@@ -392,7 +392,7 @@ void func_80AEB264(EnRu1* this, AnimationHeader* animation, u8 arg2, f32 transit
playbackSpeed = -1.0f;
}
SkelAnime_ChangeAnim(&this->skelAnime, animationHeader, playbackSpeed, unk0, fc, arg2, transitionRate);
SkelAnime_ChangeAnim(&this->skelAnime, animHeader, playbackSpeed, unk0, fc, arg2, transitionRate);
}
s32 EnRu1_FrameUpdateMatrix(EnRu1* this) {
@@ -623,8 +623,7 @@ void func_80AEBC84(EnRu1* this, GlobalContext* globalCtx) {
void func_80AEBCB8(EnRu1* this, UNK_TYPE arg1) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06012E94, 1.0f, 0, SkelAnime_GetFrameCount(&D_06012E94.genericHeader),
0, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06012E94, 1.0f, 0, SkelAnime_GetFrameCount(&D_06012E94), 0, -8.0f);
}
}
@@ -644,7 +643,7 @@ void func_80AEBD94(EnRu1* this, GlobalContext* globalCtx) {
f32 frameCount;
if (func_80AEB480(globalCtx, 3)) {
frameCount = SkelAnime_GetFrameCount(&D_06009060.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06009060);
func_80AEB934(this, globalCtx);
func_80AEB738(this, globalCtx);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06009060, 1.0f, 0.0f, frameCount, 2, 0.0f);
@@ -658,7 +657,7 @@ void func_80AEBE3C(EnRu1* this, GlobalContext* globalCtx, s32 arg2) {
f32 frameCount;
if (arg2 != 0) {
frameCount = SkelAnime_GetFrameCount(&D_06013A64.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06013A64);
func_80AEB7D0(this);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06013A64, 1.0f, 0, frameCount, 0, -8.0f);
this->action = 3;
@@ -672,7 +671,7 @@ void func_80AEBEC8(EnRu1* this, GlobalContext* globalCtx) {
f32 frameCount;
if (func_80AEB458(globalCtx, 6)) {
frameCount = SkelAnime_GetFrameCount(&D_06008AA8.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06008AA8);
func_80AEB738(this, globalCtx);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06008AA8, 1.0f, 0, frameCount, 2, -8.0f);
this->action = 4;
@@ -700,7 +699,7 @@ void func_80AEBFD8(EnRu1* this, GlobalContext* globalCtx) {
csCtxFrames = globalCtx->csCtx.frames;
endFrame = csCmdNPCAction->endFrame;
if (csCtxFrames >= endFrame - 2) {
frameCount = SkelAnime_GetFrameCount(&D_06008100.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06008100);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06008100, 1.0, 0, frameCount, 2, -8.0f);
this->action = 6;
}
@@ -869,8 +868,7 @@ void func_80AEC6B0(EnRu1* this) {
void func_80AEC6E4(EnRu1* this, GlobalContext* globalCtx) {
if ((func_80AEAFA0(globalCtx, 4, 3)) && (this->unk_280 == 0)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06003784, 1.0f, 0, SkelAnime_GetFrameCount(&D_06003784.genericHeader),
2, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06003784, 1.0f, 0, SkelAnime_GetFrameCount(&D_06003784), 2, -8.0f);
this->unk_280 = 1;
func_80AEC6B0(this);
}
@@ -910,16 +908,14 @@ void func_80AEC81C(EnRu1* this, GlobalContext* globalCtx) {
void func_80AEC8B8(EnRu1* this, GlobalContext* globalCtx) {
if (func_80AEAFA0(globalCtx, 3, 3)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004074, 1.0f, 0, SkelAnime_GetFrameCount(&D_06004074.genericHeader),
2, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004074, 1.0f, 0, SkelAnime_GetFrameCount(&D_06004074), 2, -8.0f);
this->action = 10;
}
}
void func_80AEC93C(EnRu1* this, UNK_TYPE arg1) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060078E4, 1.0f, 0, SkelAnime_GetFrameCount(&D_060078E4.genericHeader),
0, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060078E4, 1.0f, 0, SkelAnime_GetFrameCount(&D_060078E4), 0, -8.0f);
this->actor.posRot.rot.y += 0x8000;
this->action = 0xB;
this->unk_26C = 0.0f;
@@ -1138,8 +1134,7 @@ void func_80AED154(EnRu1* this, GlobalContext* globalCtx) {
void func_80AED19C(EnRu1* this, s32 cond) {
if (cond) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001488, 1.0f, 0, SkelAnime_GetFrameCount(&D_06001488.genericHeader),
2, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06001488, 1.0f, 0, SkelAnime_GetFrameCount(&D_06001488), 2, -8.0f);
this->action = 20;
func_80AED0B0(this, 3);
}
@@ -1148,12 +1143,11 @@ void func_80AED19C(EnRu1* this, s32 cond) {
void func_80AED218(EnRu1* this, UNK_TYPE arg1) {
if (func_80AED084(this, 4)) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06002058, 1.0f, 0,
SkelAnime_GetFrameCount(&D_06002058.genericHeader), 0, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06002058, 1.0f, 0, SkelAnime_GetFrameCount(&D_06002058), 0,
-8.0f);
}
} else if (func_80AED084(this, 5)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06002990, 1.0f, 0, SkelAnime_GetFrameCount(&D_06002990.genericHeader),
2, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06002990, 1.0f, 0, SkelAnime_GetFrameCount(&D_06002990), 2, -8.0f);
this->action = 21;
this->unk_27C = this->actor.xzDistFromLink;
}
@@ -1220,7 +1214,7 @@ void func_80AED4FC(EnRu1* this) {
func_80078914(&this->actor.projectedPos, NA_SE_EV_LAND_DIRT);
}
func_80AED520(EnRu1* this, GlobalContext* globalCtx) {
void func_80AED520(EnRu1* this, GlobalContext* globalCtx) {
Player* player = PLAYER;
Audio_PlaySoundGeneral(NA_SE_PL_PULL_UP_RUTO, &player->actor.projectedPos, 4, &D_801333E0, &D_801333E0,
@@ -1624,8 +1618,7 @@ void func_80AEE628(EnRu1* this, GlobalContext* globalCtx) {
s8 curRoomNum = globalCtx->roomCtx.curRoom.num;
if (func_80AEAF38(globalCtx)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06006B9C, 1.0f, 0, SkelAnime_GetFrameCount(&D_06006B9C.genericHeader),
0, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06006B9C, 1.0f, 0, SkelAnime_GetFrameCount(&D_06006B9C), 0, -8.0f);
gSaveContext.infTable[20] |= 0x10;
this->action = 31;
}
@@ -1638,8 +1631,8 @@ s32 func_80AEE6D0(EnRu1* this, GlobalContext* globalCtx) {
if ((!(gSaveContext.infTable[20] & 0x10)) && (func_80AEB124(globalCtx) != 0)) {
if (!Player_InCsMode(globalCtx)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004648, 1.0f, 0,
SkelAnime_GetFrameCount(&D_06004350.genericHeader), 0, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004648, 1.0f, 0, SkelAnime_GetFrameCount(&D_06004350), 0,
-8.0f);
func_80AED600(this);
this->action = 34;
this->unk_26C = 0.0f;
@@ -1660,7 +1653,7 @@ void func_80AEE7C4(EnRu1* this, GlobalContext* globalCtx) {
f32* unk_370 = &this->unk_370;
if (Actor_HasNoParent(this, globalCtx)) {
frameCount = SkelAnime_GetFrameCount(&D_06006B9C.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06006B9C);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06006B9C, 1.0f, 0, frameCount, 0, -8.0f);
func_80AED6DC(this, globalCtx);
this->actor.speedXZ *= (kREG(25) * 0.01f) + 1.0f;
@@ -1684,7 +1677,7 @@ void func_80AEE7C4(EnRu1* this, GlobalContext* globalCtx) {
if (this->action != 32) {
if (*unk_370 > 30.0f) {
if (Math_Rand_S16Offset(0, 3) == 0) {
frameCount = SkelAnime_GetFrameCount(&D_06004350.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06004350);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06004350, 1.0f, 0, frameCount, 0, -8.0f);
func_80AED5DC(this);
this->action = 32;
@@ -1693,14 +1686,14 @@ void func_80AEE7C4(EnRu1* this, GlobalContext* globalCtx) {
}
} else {
if (*unk_370 > 50.0f) {
frameCount = SkelAnime_GetFrameCount(&D_06006B9C.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06006B9C);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06006B9C, 1.0f, 0, frameCount, 0, -8.0f);
this->action = 31;
*unk_370 = 0.0f;
}
}
} else {
frameCount = SkelAnime_GetFrameCount(&D_06006B9C.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06006B9C);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06006B9C, 1.0f, 0, frameCount, 0, -8.0f);
*unk_370 = 0.0f;
}
@@ -1850,7 +1843,7 @@ s32 func_80AEF0BC(EnRu1* this, GlobalContext* globalCtx) {
s32 frameCount;
if (gSaveContext.infTable[20] & 4) {
frameCount = SkelAnime_GetFrameCount(&D_06007534.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06007534);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06007534, 1.0f, 0, frameCount, 2, -8.0f);
globalCtx->msgCtx.msgMode = 0x37;
this->action = 26;
@@ -1876,8 +1869,7 @@ void func_80AEF188(EnRu1* this, GlobalContext* globalCtx) {
void func_80AEF1F0(EnRu1* this, GlobalContext* globalCtx, UNK_TYPE arg2) {
if (arg2 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06006B9C, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06006B9C.genericHeader), 0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06006B9C, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06006B9C), 0, 0.0f);
func_80106CCC(globalCtx);
gSaveContext.infTable[20] |= 8;
func_80AED6DC(this, globalCtx);
@@ -1985,7 +1977,7 @@ void func_80AEF624(EnRu1* this, GlobalContext* globalCtx) {
s16 newRotTmp;
if (func_80AEAFE0(globalCtx, 1, 3)) {
frameCount = SkelAnime_GetFrameCount(&D_060063F4.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_060063F4);
// this weird part with the redundant variable is necessary to match for some reason
csCmdNPCAction2 = globalCtx->csCtx.npcActions[3];
csCmdNPCAction = csCmdNPCAction2;
@@ -2011,8 +2003,7 @@ void func_80AEF624(EnRu1* this, GlobalContext* globalCtx) {
void func_80AEF728(EnRu1* this, UNK_TYPE arg1) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06003608, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&D_06003608.genericHeader), 0, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06003608, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06003608), 0, 0.0f);
func_80AEB3CC(this);
this->action = 38;
}
@@ -2020,16 +2011,14 @@ void func_80AEF728(EnRu1* this, UNK_TYPE arg1) {
void func_80AEF79C(EnRu1* this, GlobalContext* globalCtx) {
if (func_80AEAFE0(globalCtx, 2, 3)) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06002EC0, 1.0f, 0, SkelAnime_GetFrameCount(&D_06002EC0.genericHeader),
2, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06002EC0, 1.0f, 0, SkelAnime_GetFrameCount(&D_06002EC0), 2, -8.0f);
this->action = 39;
}
}
void func_80AEF820(EnRu1* this, UNK_TYPE arg1) {
if (arg1 != 0) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060097B8, 1.0f, 0, SkelAnime_GetFrameCount(&D_060097B8.genericHeader),
0, -8.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060097B8, 1.0f, 0, SkelAnime_GetFrameCount(&D_060097B8), 0, -8.0f);
this->action = 40;
}
}
@@ -2264,8 +2253,8 @@ void EnRu1_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
ActorShape_Init(&thisx->shape, 0.0f, ActorShadow_DrawFunc_Circle, 30.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06012700, NULL, &this->limbDrawTable, &this->transitionDrawTable,
17);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06012700, NULL, this->limbDrawTable, this->transitionDrawTable,
17);
func_80AEAD20(this, globalCtx);
switch (func_80AEADF0(this)) {
case 0:
@@ -2315,7 +2304,7 @@ void func_80AF0278(EnRu1* this, GlobalContext* globalCtx, s32 limbIndex, Vec3s*
}
}
s32 EnRu1_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, EnRu1* thisx,
s32 EnRu1_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
Gfx** gfx) {
EnRu1* this = THIS;
@@ -2327,7 +2316,7 @@ s32 EnRu1_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnRu1_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx, Gfx** gfx) {
void EnRu1_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx, Gfx** gfx) {
EnRu1* this = THIS;
Vec3f vec1;
Vec3f vec2;
@@ -2335,12 +2324,12 @@ void EnRu1_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Ve
if (limbIndex == 15) {
vec1 = sMultVec;
Matrix_MultVec3f(&vec1, &vec2);
thisx->posRot2.pos.x = vec2.x;
thisx->posRot2.pos.y = vec2.y;
thisx->posRot2.pos.z = vec2.z;
thisx->posRot2.rot.x = thisx->posRot.rot.x;
thisx->posRot2.rot.y = thisx->posRot.rot.y;
thisx->posRot2.rot.z = thisx->posRot.rot.z;
this->actor.posRot2.pos.x = vec2.x;
this->actor.posRot2.pos.y = vec2.y;
this->actor.posRot2.pos.z = vec2.z;
this->actor.posRot2.rot.x = this->actor.posRot.rot.x;
this->actor.posRot2.rot.y = this->actor.posRot.rot.y;
this->actor.posRot2.rot.z = this->actor.posRot.rot.z;
}
}
@@ -2366,8 +2355,8 @@ void func_80AF0400(EnRu1* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
gSPSegment(POLY_OPA_DISP++, 0x0C, &D_80116280[2]);
POLY_OPA_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnRu1_OverrideLimbDraw, EnRu1_PostLimbDraw, &this->actor, POLY_OPA_DISP);
POLY_OPA_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnRu1_OverrideLimbDraw, EnRu1_PostLimbDraw, this, POLY_OPA_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ru1.c", 1309);
}
@@ -2391,8 +2380,8 @@ void func_80AF05D4(EnRu1* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->unk_2A8);
gSPSegment(POLY_XLU_DISP++, 0x0C, &D_80116280[0]);
POLY_XLU_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnRu1_OverrideLimbDraw, NULL, &this->actor, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnRu1_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ru1.c", 1353);
}
+9 -10
View File
@@ -84,7 +84,7 @@ const ActorInit En_Ru2_InitVars = {
};
extern AnimationHeader D_060004CC;
extern SkeletonHeader D_0600C700;
extern FlexSkeletonHeader D_0600C700;
extern AnimationHeader D_0600D3DC;
extern AnimationHeader D_0600DCAC;
extern AnimationHeader D_06000DE8;
@@ -219,7 +219,7 @@ void func_80AF2868(EnRu2* this, GlobalContext* globalCtx, u32 npcActionIdx) {
}
void func_80AF28E8(EnRu2* this, AnimationHeader* animation, u8 arg2, f32 transitionRate, s32 arg4) {
f32 frameCount = SkelAnime_GetFrameCount(&animation->genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(animation);
f32 playbackSpeed;
f32 unk0;
f32 fc;
@@ -310,8 +310,7 @@ void func_80AF2BC0(EnRu2* this, GlobalContext* globalCtx) {
if (globalCtx->csCtx.state != 0) {
csCmdNPCAction = globalCtx->csCtx.npcActions[3];
if (csCmdNPCAction != NULL && csCmdNPCAction->action == 3) {
SkelAnime_ChangeAnim(&this->skelAnime, animation, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&animation->genericHeader), 2, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, animation, 1.0f, 0.0f, SkelAnime_GetFrameCount(animation), 2, 0.0f);
this->action = 4;
}
}
@@ -485,8 +484,8 @@ void func_80AF321C(EnRu2* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->alpha);
gSPSegment(POLY_XLU_DISP++, 0x0C, &D_80116280[0]);
POLY_XLU_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
NULL, NULL, NULL, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
NULL, NULL, NULL, POLY_XLU_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ru2_inKenjyanomaDemo02.c", 291);
}
@@ -770,8 +769,8 @@ void EnRu2_Init(Actor* thisx, GlobalContext* globalCtx) {
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 30.0f);
func_80AF2550(thisx, globalCtx);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0600C700, NULL, &this->limbDrawTable, &this->transitionDrawTable,
23);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0600C700, NULL, &this->limbDrawTable, &this->transitionDrawTable,
23);
switch (func_80AF26A0(this)) {
case 2:
@@ -810,8 +809,8 @@ void func_80AF3F20(EnRu2* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
gSPSegment(POLY_OPA_DISP++, 0x0C, &D_80116280[2]);
SkelAnime_DrawSV(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount, NULL, NULL,
&this->actor);
SkelAnime_DrawFlexOpa(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount, NULL, NULL,
this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ru2.c", 663);
}
+14 -18
View File
@@ -70,7 +70,7 @@ typedef enum {
/* 0x04 */ SHELLBLADE_BOUNCE,
} ShellbladeBehavior;
extern SkeletonHeader D_06002BF0;
extern FlexSkeletonHeader D_06002BF0;
extern AnimationHeader D_06000194;
extern AnimationHeader D_0600004C;
extern AnimationHeader D_06000124;
@@ -83,7 +83,7 @@ void EnSb_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_ProcessInitChain(&this->actor, sInitChain);
this->actor.colChkInfo.damageTable = &sDamageTable;
this->actor.colChkInfo.health = 2;
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06002BF0, &D_06000194, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06002BF0, &D_06000194, NULL, NULL, 0);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder_Set3(globalCtx, &this->collider, &this->actor, &sCylinderInit);
this->isDead = false;
@@ -115,29 +115,26 @@ void EnSb_SpawnBubbles(GlobalContext* globalCtx, EnSb* this) {
}
void EnSb_SetupWaitClosed(EnSb* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600004C, 1.0f, 0, SkelAnime_GetFrameCount(&D_0600004C.genericHeader), 2,
0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600004C, 1.0f, 0, SkelAnime_GetFrameCount(&D_0600004C), 2, 0.0f);
this->behavior = SHELLBLADE_WAIT_CLOSED;
this->actionFunc = EnSb_WaitClosed;
}
void EnSb_SetupOpen(EnSb* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000194, 1.0f, 0, SkelAnime_GetFrameCount(&D_06000194.genericHeader), 2,
0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000194, 1.0f, 0, SkelAnime_GetFrameCount(&D_06000194), 2, 0.0f);
this->behavior = SHELLBLADE_OPEN;
this->actionFunc = EnSb_Open;
Audio_PlayActorSound2(&this->actor, NA_SE_EN_SHELL_MOUTH);
}
void EnSb_SetupWaitOpen(EnSb* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_06002C8C, 1.0f, 0, SkelAnime_GetFrameCount(&D_06002C8C.genericHeader), 0,
0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06002C8C, 1.0f, 0, SkelAnime_GetFrameCount(&D_06002C8C), 0, 0.0f);
this->behavior = SHELLBLADE_WAIT_OPEN;
this->actionFunc = EnSb_WaitOpen;
}
void EnSb_SetupLunge(EnSb* this) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06000124.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06000124);
f32 playbackSpeed = this->actor.waterY > 0.0f ? 1.0f : 0.0f;
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000124, playbackSpeed, 0.0f, frameCount, 2, 0);
@@ -147,17 +144,16 @@ void EnSb_SetupLunge(EnSb* this) {
}
void EnSb_SetupBounce(EnSb* this) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060000B4, 1.0f, 0, SkelAnime_GetFrameCount(&D_060000B4.genericHeader), 2,
0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060000B4, 1.0f, 0, SkelAnime_GetFrameCount(&D_060000B4), 2, 0.0f);
this->behavior = SHELLBLADE_BOUNCE;
this->actionFunc = EnSb_Bounce;
}
void EnSb_SetupCooldown(EnSb* this, s32 changeSpeed) {
f32 frameCount = SkelAnime_GetFrameCount(&D_0600004C.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_0600004C);
if (this->behavior != SHELLBLADE_WAIT_CLOSED) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600004C.genericHeader, 1.0f, 0, frameCount, 2, 0.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_0600004C, 1.0f, 0, frameCount, 2, 0.0f);
}
this->behavior = SHELLBLADE_WAIT_CLOSED;
if (changeSpeed) {
@@ -189,7 +185,7 @@ void EnSb_WaitClosed(EnSb* this, GlobalContext* globalCtx) {
void EnSb_Open(EnSb* this, GlobalContext* globalCtx) {
f32 currentFrame = this->skelAnime.animCurrentFrame;
if (SkelAnime_GetFrameCount(&D_06000194.genericHeader) <= currentFrame) {
if (SkelAnime_GetFrameCount(&D_06000194) <= currentFrame) {
this->timer = 15;
EnSb_SetupWaitOpen(this);
} else {
@@ -260,7 +256,7 @@ void EnSb_Bounce(EnSb* this, GlobalContext* globalCtx) {
f32 frameCount;
currentFrame = this->skelAnime.animCurrentFrame;
frameCount = SkelAnime_GetFrameCount(&D_060000B4.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_060000B4);
Math_ApproxF(&this->actor.speedXZ, 0.0f, 0.2f);
if (currentFrame == frameCount) {
@@ -445,7 +441,7 @@ void EnSb_Update(Actor* thisx, GlobalContext* globalCtx) {
}
}
void EnSb_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx, Gfx** gfx) {
void EnSb_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnSb* this = THIS;
func_80032F54(&this->unk_1E0, limbIndex, 0, 6, 8, dList, -1);
@@ -458,8 +454,8 @@ void EnSb_Draw(Actor* thisx, GlobalContext* globalCtx) {
s16 fireDecr;
func_8002EBCC(&this->actor, globalCtx, 1);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount, NULL,
EnSb_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
NULL, EnSb_PostLimbDraw, this);
if (this->fire != 0) {
this->actor.dmgEffectTimer++;
fireDecr = this->fire - 1;
+2 -2
View File
@@ -1045,6 +1045,6 @@ void EnSt_Draw(Actor* thisx, GlobalContext* globalCtx) {
EnSt_CheckBodyStickHit(this, globalCtx);
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnSt_OverrideLimbDraw,
EnSt_PostLimbDraw, this);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnSt_OverrideLimbDraw,
EnSt_PostLimbDraw, this);
}
@@ -30,7 +30,7 @@ void func_80B131B8(EnSyatekiNiw* this, Vec3f* arg1, Vec3f* arg2, Vec3f* arg3, f3
extern AnimationHeader D_060000E8;
extern Gfx D_060023B0[];
extern Gfx D_06002428[];
extern SkeletonHeader D_06002530;
extern FlexSkeletonHeader D_06002530;
const ActorInit En_Syateki_Niw_InitVars = {
ACTOR_EN_SYATEKI_NIW,
@@ -62,8 +62,8 @@ void EnSyatekiNiw_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_ProcessInitChain(&this->actor, sInitChain);
this->actor.flags &= ~1;
ActorShape_Init(&this->actor.shape, 0.0f, ActorShadow_DrawFunc_Circle, 25.0f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06002530, &D_060000E8, this->limbDrawTable,
this->transitionDrawTable, 16);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06002530, &D_060000E8, this->limbDrawTable,
this->transitionDrawTable, 16);
this->unk_29E = this->actor.params;
if (this->unk_29E < 0) {
@@ -200,8 +200,7 @@ void func_80B11A94(EnSyatekiNiw* this, GlobalContext* globalCtx, s16 arg2) {
}
void func_80B11DEC(EnSyatekiNiw* this, GlobalContext* globalCtx) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060000E8, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060000E8.genericHeader),
0, -10.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060000E8, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060000E8), 0, -10.0f);
if (this->unk_29E != 0) {
Actor_SetScale(&this->actor, this->unk_2F4);
}
@@ -340,8 +339,7 @@ void func_80B11E78(EnSyatekiNiw* this, GlobalContext* globalCtx) {
}
void func_80B123A8(EnSyatekiNiw* this, GlobalContext* globalCtx) {
SkelAnime_ChangeAnim(&this->skelAnime, &D_060000E8, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060000E8.genericHeader),
0, -10.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_060000E8, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_060000E8), 0, -10.0f);
this->unk_27C = 6000.0f;
this->unk_288 = -10000.0f;
this->unk_2B0.z = 6000.0f;
@@ -663,7 +661,7 @@ void EnSyatekiNiw_Update(Actor* thisx, GlobalContext* globalCtx) {
}
s32 SyatekiNiw_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnSyatekiNiw* this = THIS;
Vec3f sp0 = { 0.0f, 0.0f, 0.0f };
@@ -696,8 +694,8 @@ void EnSyatekiNiw_Draw(Actor* thisx, GlobalContext* globalCtx) {
func_80026230(globalCtx, &sp30, 0, 0x14);
}
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
SyatekiNiw_OverrideLimbDraw, NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl,
this->skelAnime.dListCount, SyatekiNiw_OverrideLimbDraw, NULL, this);
func_80026608(globalCtx);
func_80B13464(this, globalCtx);
}
@@ -37,7 +37,7 @@ const ActorInit En_Takara_Man_InitVars = {
static u8 sTakaraIsInitialized = false;
extern SkeletonHeader D_06004FE0;
extern FlexSkeletonHeader D_06004FE0;
extern AnimationHeader D_06000498;
void EnTakaraMan_Destroy(Actor* thisx, GlobalContext* globalCtx) {
@@ -58,8 +58,8 @@ void EnTakaraMan_Init(Actor* thisx, GlobalContext* globalCtx) {
globalCtx->actorCtx.flags.chest); // "Bun! %x" (needs a better translation)
globalCtx->actorCtx.flags.chest = 0;
gSaveContext.inventory.dungeonKeys[gSaveContext.mapIndex] = -1;
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06004FE0, &D_06000498, this->limbDrawTbl, this->transitionDrawTbl,
10);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06004FE0, &D_06000498, this->limbDrawTbl,
this->transitionDrawTbl, 10);
thisx->posRot2.pos = thisx->posRot.pos;
this->pos = thisx->posRot.pos;
thisx->posRot.pos.x = 133.0f;
@@ -75,7 +75,7 @@ void EnTakaraMan_Init(Actor* thisx, GlobalContext* globalCtx) {
}
void func_80B176E0(EnTakaraMan* this, GlobalContext* globalCtx) {
f32 frameCount = SkelAnime_GetFrameCount(&D_06000498.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06000498);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000498, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f);
if (!this->unk_214) {
@@ -202,7 +202,7 @@ void EnTakaraMan_Update(Actor* thisx, GlobalContext* globalCtx) {
}
s32 EnTakaraMan_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnTakaraMan* this = THIS;
if (limbIndex == 1) {
@@ -227,8 +227,8 @@ void EnTakaraMan_Draw(Actor* thisx, GlobalContext* globalCtx) {
func_80093D18(globalCtx->state.gfxCtx);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sTakaraEyeTextures[this->eyeTextureIdx]));
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnTakaraMan_OverrideLimbDraw, NULL, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnTakaraMan_OverrideLimbDraw, NULL, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_takara_man.c", 544);
}
+11 -12
View File
@@ -37,7 +37,7 @@ extern UNK_TYPE D_06004B40;
extern Gfx D_0600ACE0[];
extern Gfx D_0600BC90[];
extern Gfx D_0600BCA0[];
extern SkeletonHeader D_0600BE40;
extern FlexSkeletonHeader D_0600BE40;
const ActorInit En_Tk_InitVars = {
ACTOR_EN_TK,
@@ -170,7 +170,7 @@ static CollisionCheckInfoInit2 sColChkInfoInit = {
void EnTk_RestAnim(EnTk* this, GlobalContext* globalCtx) {
AnimationHeader* anim = &D_06002F84;
SkelAnime_ChangeAnim(&this->skelAnim, anim, 1.f, 0.f, SkelAnime_GetFrameCount(&D_06002F84.genericHeader), 0, -10.f);
SkelAnime_ChangeAnim(&this->skelAnim, anim, 1.f, 0.f, SkelAnime_GetFrameCount(&D_06002F84), 0, -10.f);
this->actionCountdown = Math_Rand_S16Offset(60, 60);
this->actor.speedXZ = 0.f;
@@ -179,7 +179,7 @@ void EnTk_RestAnim(EnTk* this, GlobalContext* globalCtx) {
void EnTk_WalkAnim(EnTk* this, GlobalContext* globalCtx) {
AnimationHeader* anim = &D_06001FA8;
SkelAnime_ChangeAnim(&this->skelAnim, anim, 1.f, 0.f, SkelAnime_GetFrameCount(&D_06002F84.genericHeader), 0, -10.f);
SkelAnime_ChangeAnim(&this->skelAnim, anim, 1.f, 0.f, SkelAnime_GetFrameCount(&D_06002F84), 0, -10.f);
this->actionCountdown = Math_Rand_S16Offset(240, 240);
}
@@ -187,7 +187,7 @@ void EnTk_WalkAnim(EnTk* this, GlobalContext* globalCtx) {
void EnTk_DigAnim(EnTk* this, GlobalContext* globalCtx) {
AnimationHeader* anim = &D_06001144;
SkelAnime_ChangeAnim(&this->skelAnim, anim, 1.f, 0.f, SkelAnime_GetFrameCount(&D_06001144.genericHeader), 0, -10.f);
SkelAnime_ChangeAnim(&this->skelAnim, anim, 1.f, 0.f, SkelAnime_GetFrameCount(&D_06001144), 0, -10.f);
if (EnTk_CheckNextSpot(this, globalCtx) >= 0) {
this->validDigHere = 1;
@@ -285,7 +285,7 @@ f32 EnTk_Step(EnTk* this, GlobalContext* globalCtx) {
Audio_PlayActorSound2(&this->actor, NA_SE_EN_MORIBLIN_WALK);
}
if (this->skelAnim.animCurrentSeg != &D_06001FA8) {
if (this->skelAnim.animation != &D_06001FA8) {
return 0.f;
}
@@ -487,9 +487,8 @@ void EnTk_Init(Actor* thisx, GlobalContext* globalCtx) {
ActorShape_Init(&this->actor.shape, 0, ActorShadow_DrawFunc_Circle, 24.f);
SkelAnime_InitSV(globalCtx, &this->skelAnim, &D_0600BE40, NULL, this->hz_22A, this->hz_296, 18);
SkelAnime_ChangeAnim(&this->skelAnim, &D_06002F84, 1.f, 0.f, SkelAnime_GetFrameCount(&D_06002F84.genericHeader), 0,
0.f);
SkelAnime_InitFlex(globalCtx, &this->skelAnim, &D_0600BE40, NULL, this->hz_22A, this->hz_296, 18);
SkelAnime_ChangeAnim(&this->skelAnim, &D_06002F84, 1.f, 0.f, SkelAnime_GetFrameCount(&D_06002F84), 0, 0.f);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, &this->actor, &sCylinderInit);
@@ -688,7 +687,7 @@ void func_80B1D200(GlobalContext* globalCtx) {
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_tk.c", 1190);
}
s32 EnTk_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnTk_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnTk* this = THIS;
switch (limbIndex) {
@@ -706,7 +705,7 @@ s32 EnTk_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnTk_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnTk_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnTk* this = THIS;
Vec3f sp28 = { 0.f, 0.f, 4600.f };
Vec3f sp1C = { 0.f, 0.f, 0.f };
@@ -741,8 +740,8 @@ void EnTk_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sEyesSegments[this->eyeImageIdx]));
SkelAnime_DrawSV(globalCtx, this->skelAnim.skeleton, this->skelAnim.limbDrawTbl, this->skelAnim.dListCount,
EnTk_OverrideLimbDraw, EnTk_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnim.skeleton, this->skelAnim.limbDrawTbl, this->skelAnim.dListCount,
EnTk_OverrideLimbDraw, EnTk_PostLimbDraw, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_tk.c", 1312);
}
+2 -2
View File
@@ -43,8 +43,8 @@ typedef struct EnTk {
/* 0x0224 */ s16 blinkCountdown;
/* 0x0226 */ s16 headRot;
/* 0x0228 */ s16 currentWaypoint;
/* 0x022A */ u16 hz_22A[54];
/* 0x022A */ u16 hz_296[55];
/* 0x022A */ Vec3s hz_22A[18];
/* 0x0296 */ Vec3s hz_296[18];
/* 0x0304 */ Vec3f v3f_304;
/* 0x0310 */ EnTkEff eff[20];
} EnTk; // size = 0x0770
+4 -4
View File
@@ -408,7 +408,7 @@ void EnVm_Update(Actor* thisx, GlobalContext* globalCtx) {
this->actor.posRot2.pos.y += (6500.0f + this->actor.shape.unk_08) * this->actor.scale.y;
}
s32 EnVm_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 EnVm_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnVm* this = THIS;
if (limbIndex == 2) {
@@ -423,7 +423,7 @@ s32 EnVm_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
return 0;
}
void EnVm_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnVm_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
EnVm* this = THIS;
Vec3f sp80 = D_80B2EAF8;
Vec3f sp74 = D_80B2EB04;
@@ -481,8 +481,8 @@ void EnVm_Draw(Actor* thisx, GlobalContext* globalCtx) {
func_80093D18(globalCtx->state.gfxCtx);
func_80093D84(globalCtx->state.gfxCtx);
SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnVm_OverrideLimbDraw,
EnVm_PostLimbDraw, &this->actor);
SkelAnime_DrawOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnVm_OverrideLimbDraw,
EnVm_PostLimbDraw, this);
actorPos = this->actor.posRot.pos;
func_80033C30(&actorPos, &D_80B2EB7C, 255, globalCtx);
@@ -79,7 +79,7 @@ static InitChainEntry sInitChain[] = {
extern AnimationHeader D_06000EA4;
extern AnimationHeader D_06000590;
extern AnimationHeader D_0600299C;
extern SkeletonHeader D_06008FB0;
extern FlexSkeletonHeader D_06008FB0;
extern AnimationHeader D_06009DB0;
extern AnimationHeader D_060019CC;
extern AnimationHeader D_06009520;
@@ -93,8 +93,8 @@ void EnWallmas_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_ProcessInitChain(thisx, sInitChain);
ActorShape_Init(&thisx->shape, 0, NULL, 0.5f);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06008FB0, &D_06009DB0, &this->unkSkelAnimeStruct, &this->unk_22e,
0x19);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06008FB0, &D_06009DB0, &this->unkSkelAnimeStruct, &this->unk_22e,
25);
Collider_InitCylinder(globalCtx, &this->collider);
Collider_SetCylinder(globalCtx, &this->collider, thisx, &sCylinderInit);
@@ -581,7 +581,7 @@ void EnWallmas_DrawXlu(EnWallmas* this, GlobalContext* globalCtx) {
}
s32 EnWallMas_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx) {
void* thisx) {
EnWallmas* this = THIS;
if (limbIndex == 1) {
@@ -595,7 +595,7 @@ s32 EnWallMas_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dL
return 0;
}
void EnWallMas_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx) {
void EnWallMas_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
if (limbIndex == 2) {
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_en_wallmas.c", 1478);
@@ -619,8 +619,8 @@ void EnWallmas_Draw(Actor* thisx, GlobalContext* globalCtx) {
if (this->actionFunc != EnWallmas_WaitToDrop) {
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
EnWallMas_OverrideLimbDraw, EnWallMas_PostLimbDraw, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl,
this->skelAnime.dListCount, EnWallMas_OverrideLimbDraw, EnWallMas_PostLimbDraw, this);
}
EnWallmas_DrawXlu(this, globalCtx);
+35 -35
View File
@@ -50,7 +50,7 @@ static UNK_PTR D_80B4E62C[] = { 0x06007608 };
extern AnimationHeader D_06000438;
extern UNK_TYPE D_06008848;
extern UNK_TYPE D_06008C48;
extern SkeletonHeader D_0600F5D8;
extern FlexSkeletonHeader D_0600F5D8;
extern AnimationHeader D_06010B38;
extern AnimationHeader D_06011348;
extern AnimationHeader D_060116E4;
@@ -71,8 +71,8 @@ void EnZl1_Init(Actor* thisx, GlobalContext* globalCtx) {
f32 frameCount;
EnZl1* this = THIS;
frameCount = SkelAnime_GetFrameCount(&D_06012118.genericHeader);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_0600F5D8, NULL, NULL, NULL, 0);
frameCount = SkelAnime_GetFrameCount(&D_06012118);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0600F5D8, NULL, NULL, NULL, 0);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06012118, 1.0f, 0.0f, frameCount, 0, 0.0f);
Collider_InitCylinder(globalCtx, &this->collider);
@@ -82,7 +82,7 @@ void EnZl1_Init(Actor* thisx, GlobalContext* globalCtx) {
this->actor.unk_1F = 0;
if (gSaveContext.sceneSetupIndex >= 4) {
frameCount = SkelAnime_GetFrameCount(&D_06000438.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06000438);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000438, 1.0f, 0.0f, frameCount, 0, 0.0f);
this->unk_1E6 = 0;
this->actionFunc = func_80B4BC78;
@@ -90,12 +90,12 @@ void EnZl1_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_Kill(&this->actor);
} else if (((Flags_GetEventChkInf(9)) && (Flags_GetEventChkInf(0x25))) ||
((Flags_GetEventChkInf(9)) && (Flags_GetEventChkInf(0x37)))) {
frameCount = SkelAnime_GetFrameCount(&D_06000438.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06000438);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000438, 1.0f, 0.0f, frameCount, 0, 0.0f);
this->actor.textId = 0x703D;
this->actionFunc = func_80B4AF18;
} else if (Flags_GetEventChkInf(0x40)) {
frameCount = SkelAnime_GetFrameCount(&D_06000438.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06000438);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000438, 1.0f, 0.0f, frameCount, 0, 0.0f);
this->actor.textId = 0x703C;
this->actionFunc = func_80B4AF18;
@@ -113,7 +113,7 @@ void EnZl1_Destroy(Actor* thisx, GlobalContext* globalCtx) {
}
void func_80B4AE18(EnZl1* this) {
if ((this->skelAnime.animCurrentSeg == &D_06010B38) && (this->skelAnime.animCurrentFrame < 26.0f)) {
if ((this->skelAnime.animation == &D_06010B38) && (this->skelAnime.animCurrentFrame < 26.0f)) {
this->unk_1F4 = &D_06008C48;
this->unk_1F8 = &D_06008848;
this->unk_1FC = 2;
@@ -152,7 +152,7 @@ void func_80B4AF18(EnZl1* this, GlobalContext* globalCtx) {
void func_80B4B010(EnZl1* this, GlobalContext* globalCtx) {
Player* player = PLAYER;
s32 pad2;
AnimationHeader* animationHeader;
s32 pad3;
s32 pad;
Vec3f vec1 = { -460.0f, 118.0f, 0.0f };
Vec3f vec2 = { -406.0f, 110.0f, 0.0f };
@@ -160,9 +160,8 @@ void func_80B4B010(EnZl1* this, GlobalContext* globalCtx) {
s16 rotDiff;
if (func_8002F194(&this->actor, globalCtx)) {
animationHeader = &D_06010B38;
SkelAnime_ChangeAnim(&this->skelAnime, animationHeader, 1.0f, 0.0f,
SkelAnime_GetFrameCount(&animationHeader->genericHeader), 3, -10.0f);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06010B38, 1.0f, 0.0f, SkelAnime_GetFrameCount(&D_06010B38), 3,
-10.0f);
this->unk_1E8 = Gameplay_CreateSubCamera(globalCtx);
Gameplay_ChangeCameraStatus(globalCtx, 0, 1);
Gameplay_ChangeCameraStatus(globalCtx, this->unk_1E8, 7);
@@ -198,7 +197,7 @@ void func_80B4B240(EnZl1* this, GlobalContext* globalCtx) {
u8 sp54[] = { 0x00, 0x00, 0x02 };
s32 pad2;
Player* player = PLAYER;
AnimationHeader* animationHeader;
AnimationHeader* animHeaderSeg;
MessageContext* msgCtx = &globalCtx->msgCtx;
f32 frameCount;
s32 sp3C = 0;
@@ -215,7 +214,7 @@ void func_80B4B240(EnZl1* this, GlobalContext* globalCtx) {
}
break;
case 64:
animationHeader = &D_06011348;
animHeaderSeg = &D_06011348;
sp3C = 1;
this->actor.textId = 0x702E;
func_8010B680(globalCtx, this->actor.textId, NULL);
@@ -237,20 +236,20 @@ void func_80B4B240(EnZl1* this, GlobalContext* globalCtx) {
case 2:
if ((func_8010BDBC(msgCtx) == 4) && (func_80106BC8(globalCtx) != 0)) {
if (msgCtx->choiceIndex == 0) {
animationHeader = &D_06013F10;
animHeaderSeg = &D_06013F10;
sp3C = 2;
this->unk_1E2++;
} else {
animationHeader = &D_060116E4;
animHeaderSeg = &D_060116E4;
sp3C = 2;
this->unk_1E2 = 6;
}
}
break;
case 3:
frameCount = SkelAnime_GetFrameCount(&D_06013F10.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_06013F10);
if (this->skelAnime.animCurrentFrame == frameCount) {
animationHeader = &D_060143A8;
animHeaderSeg = &D_060143A8;
sp3C = 1;
this->actor.textId = 0x7032;
func_8010B720(globalCtx, this->actor.textId);
@@ -260,7 +259,7 @@ void func_80B4B240(EnZl1* this, GlobalContext* globalCtx) {
case 4:
if ((func_8010BDBC(msgCtx) == 4) && (func_80106BC8(globalCtx) != 0)) {
if (msgCtx->choiceIndex == 0) {
animationHeader = &D_060132D8;
animHeaderSeg = &D_060132D8;
sp3C = 2;
this->unk_1E2 = 9;
} else {
@@ -278,9 +277,9 @@ void func_80B4B240(EnZl1* this, GlobalContext* globalCtx) {
}
break;
case 6:
frameCount = SkelAnime_GetFrameCount(&D_060116E4.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_060116E4);
if (this->skelAnime.animCurrentFrame == frameCount) {
animationHeader = &D_06011B88;
animHeaderSeg = &D_06011B88;
sp3C = 1;
this->actor.textId = 0x7031;
func_8010B720(globalCtx, this->actor.textId);
@@ -297,7 +296,7 @@ void func_80B4B240(EnZl1* this, GlobalContext* globalCtx) {
case 8:
if ((func_8010BDBC(msgCtx) == 4) && (func_80106BC8(globalCtx) != 0)) {
if (msgCtx->choiceIndex == 0) {
animationHeader = &D_060138E0;
animHeaderSeg = &D_060138E0;
sp3C = 2;
this->unk_1E2 = 3;
} else {
@@ -308,9 +307,9 @@ void func_80B4B240(EnZl1* this, GlobalContext* globalCtx) {
}
break;
case 9:
frameCount = SkelAnime_GetFrameCount(&D_060132D8.genericHeader);
frameCount = SkelAnime_GetFrameCount(&D_060132D8);
if (this->skelAnime.animCurrentFrame == frameCount) {
animationHeader = &D_06000438;
animHeaderSeg = &D_06000438;
sp3C = 1;
globalCtx->csCtx.segment = D_80B4C5D0;
gSaveContext.cutsceneTrigger = 1;
@@ -320,8 +319,8 @@ void func_80B4B240(EnZl1* this, GlobalContext* globalCtx) {
break;
}
if (sp3C != 0) {
frameCount = SkelAnime_GetFrameCount(&animationHeader->genericHeader);
SkelAnime_ChangeAnim(&this->skelAnime, animationHeader, 1.0f, 0.0f, frameCount, sp54[sp3C], -10.0f);
frameCount = SkelAnime_GetFrameCount(animHeaderSeg);
SkelAnime_ChangeAnim(&this->skelAnime, animHeaderSeg, 1.0f, 0.0f, frameCount, sp54[sp3C], -10.0f);
}
func_80038290(globalCtx, &this->actor, &this->unk_200, &this->unk_206, this->actor.posRot2.pos);
}
@@ -380,7 +379,7 @@ void func_80B4B8B4(EnZl1* this, GlobalContext* globalCtx) {
this->actor.posRot.pos = sp48;
}
if (this->unk_1E6 != npcAction->action) {
frameCount = SkelAnime_GetFrameCount(&spB0[npcAction->action]->genericHeader);
frameCount = SkelAnime_GetFrameCount(spB0[npcAction->action]);
SkelAnime_ChangeAnim(&this->skelAnime, spB0[npcAction->action], 1.0f, 0.0f, frameCount,
spA4[npcAction->action], -10.0f);
this->unk_1E6 = npcAction->action;
@@ -404,7 +403,7 @@ void func_80B4B8B4(EnZl1* this, GlobalContext* globalCtx) {
void func_80B4BBC4(EnZl1* this, GlobalContext* globalCtx) {
s32 pad;
f32 frameCount = SkelAnime_GetFrameCount(&D_06000438.genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(&D_06000438);
Player* player = PLAYER;
SkelAnime_ChangeAnim(&this->skelAnime, &D_06000438, 1.0f, 0.0f, frameCount, 0, 0.0f);
@@ -433,8 +432,8 @@ void func_80B4BC78(EnZl1* this, GlobalContext* globalCtx) {
s32 pad;
f32 frameCount;
if (SkelAnime_FrameUpdateMatrix(&this->skelAnime) && (this->skelAnime.animCurrentSeg == &D_06010B38)) {
frameCount = SkelAnime_GetFrameCount(&D_06011348.genericHeader);
if (SkelAnime_FrameUpdateMatrix(&this->skelAnime) && (this->skelAnime.animation == &D_06010B38)) {
frameCount = SkelAnime_GetFrameCount(&D_06011348);
SkelAnime_ChangeAnim(&this->skelAnime, &D_06011348, 1.0f, 0.0f, frameCount, 0, -10.0f);
}
func_80B4B874(this, globalCtx);
@@ -447,7 +446,7 @@ void func_80B4BC78(EnZl1* this, GlobalContext* globalCtx) {
}
if (this->unk_1E6 != npcAction->action) {
frameCount = SkelAnime_GetFrameCount(&sp90[npcAction->action]->genericHeader);
frameCount = SkelAnime_GetFrameCount(sp90[npcAction->action]);
SkelAnime_ChangeAnim(&this->skelAnime, sp90[npcAction->action], 1.0f, 0.0f, frameCount,
sp84[npcAction->action], -10.0f);
this->unk_1E6 = npcAction->action;
@@ -562,7 +561,7 @@ void EnZl1_Update(Actor* thisx, GlobalContext* globalCtx) {
func_80B4AE18(this);
}
s32 func_80B4C340(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) {
s32 func_80B4C340(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx) {
EnZl1* this = THIS;
if ((limbIndex == 4) || (limbIndex == 3) || (limbIndex == 6) || (limbIndex == 5)) {
@@ -583,11 +582,12 @@ s32 func_80B4C340(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* p
return 0;
}
void func_80B4C400(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* this) {
void func_80B4C400(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx) {
Vec3f vec = { 0.0f, 0.0f, 0.0f };
EnZl1* this = THIS;
if (limbIndex == 17) {
Matrix_MultVec3f(&vec, &this->posRot2.pos);
Matrix_MultVec3f(&vec, &this->actor.posRot2.pos);
}
}
@@ -601,8 +601,8 @@ void EnZl1_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x0A, SEGMENTED_TO_VIRTUAL(this->unk_1EC));
func_80093D18(globalCtx->state.gfxCtx);
SkelAnime_DrawSV(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
func_80B4C340, func_80B4C400, &this->actor);
SkelAnime_DrawFlexOpa(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, this->skelAnime.dListCount,
func_80B4C340, func_80B4C400, this);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_girlB.c", 2046);
}
+13 -14
View File
@@ -18,8 +18,7 @@ void EnZl2_Destroy(Actor* thisx, GlobalContext* globalCtx);
void EnZl2_Update(Actor* thisx, GlobalContext* globalCtx);
void EnZl2_Draw(Actor* thisx, GlobalContext* globalCtx);
s32 func_80B4F45C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx,
Gfx** gfx);
s32 func_80B4F45C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx, Gfx** gfx);
void func_80B50BBC(EnZl2* this, GlobalContext* globalCtx);
void func_80B50BEC(EnZl2* this, GlobalContext* globalCtx);
@@ -80,7 +79,7 @@ static EnZl2ActionFunc sActionFuncs[] = {
func_80B51C0C, func_80B51C64, func_80B51CA8, func_80B52068, func_80B52098, func_80B52108,
};
static EnZl2PreLimbDrawFunc sOverrideLimbDrawFuncs[] = {
static OverrideLimbDraw sOverrideLimbDrawFuncs[] = {
func_80B4F45C,
};
@@ -129,7 +128,7 @@ extern AnimationHeader D_0600AFE0;
extern AnimationHeader D_0600B224;
extern AnimationHeader D_0600B5FC;
extern Gfx D_0600BAE8[];
extern SkeletonHeader D_06010D70;
extern FlexSkeletonHeader D_06010D70;
void EnZl2_Destroy(Actor* thisx, GlobalContext* globalCtx) {
EnZl2* this = THIS;
@@ -477,7 +476,7 @@ void func_80B4F230(EnZl2* this, s16 arg1, s32 arg2) {
this->unk_20C[arg2] = arg1;
}
s32 func_80B4F45C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx,
s32 func_80B4F45C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
Gfx** gfx) {
s32 pad;
EnZl2* this = THIS;
@@ -577,7 +576,7 @@ s32 func_80B4F45C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* p
return 0;
}
void EnZl2_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx, Gfx** gfx) {
void EnZl2_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx, Gfx** gfx) {
EnZl2* this = THIS;
s32 pad[2];
@@ -610,7 +609,7 @@ void func_80B4FCCC(EnZl2* this, GlobalContext* globalCtx) {
}
void func_80B4FD00(EnZl2* this, AnimationHeader* animation, u8 arg2, f32 transitionRate, s32 arg4) {
f32 frameCount = SkelAnime_GetFrameCount(&animation->genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(animation);
f32 playbackSpeed;
f32 unk0;
f32 fc;
@@ -1622,7 +1621,7 @@ void func_80B521A0(EnZl2* this, GlobalContext* globalCtx) {
if (Object_IsLoaded(objectCtx, bankIndex)) {
this->unk_274 = bankIndex;
func_80B4FCCC(this, globalCtx);
this->unk_278 = SkelAnime_GetFrameCount(&D_060022D0.genericHeader);
this->unk_278 = SkelAnime_GetFrameCount(&D_060022D0);
func_80B52114(this, globalCtx);
}
}
@@ -1644,7 +1643,7 @@ void EnZl2_Init(Actor* thisx, GlobalContext* globalCtx) {
ActorShape_Init(actorShape, 0.0f, ActorShadow_DrawFunc_Circle, 30.0f);
actorShape->unk_14 = 0;
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06010D70, NULL, NULL, NULL, 0);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06010D70, NULL, NULL, NULL, 0);
switch (thisx->params) {
case 1:
@@ -1656,7 +1655,7 @@ void EnZl2_Init(Actor* thisx, GlobalContext* globalCtx) {
}
}
s32 EnZl2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx,
s32 EnZl2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
Gfx** gfx) {
EnZl2* this = THIS;
@@ -1692,8 +1691,8 @@ void func_80B523C8(EnZl2* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
gSPSegment(POLY_OPA_DISP++, 0x0B, &D_80116280[2]);
POLY_OPA_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnZl2_OverrideLimbDraw, EnZl2_PostLimbDraw, &this->actor, POLY_OPA_DISP);
POLY_OPA_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnZl2_OverrideLimbDraw, EnZl2_PostLimbDraw, this, POLY_OPA_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_zl2.c", 1648);
}
@@ -1717,8 +1716,8 @@ void func_80B525D4(EnZl2* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->alpha);
gSPSegment(POLY_XLU_DISP++, 0x0B, &D_80116280[0]);
POLY_XLU_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnZl2_OverrideLimbDraw, NULL, &this->actor, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnZl2_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_zl2.c", 1692);
}
@@ -7,8 +7,6 @@
struct EnZl2;
typedef void (*EnZl2ActionFunc)(struct EnZl2*, GlobalContext*);
typedef s32 (*EnZl2PreLimbDrawFunc)(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
Actor* thisx, Gfx** gfx);
typedef void (*EnZl2DrawFunc)(struct EnZl2*, GlobalContext*);
typedef struct EnZl2 {
+14 -14
View File
@@ -52,6 +52,7 @@ Vec3f D_80B5A4B0 = { 42.0f, 260.0f, 13.0f };
u32 D_80B5A4BC = 0;
extern FlexSkeletonHeader D_06010D70;
extern AnimationHeader D_060001D8;
extern AnimationHeader D_060004F4;
extern AnimationHeader D_060014DC;
@@ -83,7 +84,6 @@ extern AnimationHeader D_06009FBC;
extern AnimationHeader D_0600A334;
extern AnimationHeader D_0600A598;
extern AnimationHeader D_0600AACC;
extern SkeletonHeader D_06010D70;
extern AnimationHeader D_06001110;
extern AnimationHeader D_06001D8C;
extern AnimationHeader D_06002348;
@@ -618,7 +618,7 @@ void func_80B54360(EnZl3* this, s16 arg1, s32 arg2) {
this->unk_2BC[arg2] = arg1;
}
s32 func_80B5458C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx,
s32 func_80B5458C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
Gfx** gfx) {
s32 pad[3];
EnZl3* this = THIS;
@@ -722,7 +722,7 @@ s32 func_80B5458C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* p
return 0;
}
void EnZl3_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, Actor* thisx, Gfx** gfx) {
void EnZl3_PostLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx, Gfx** gfx) {
EnZl3* this = THIS;
s32 pad;
Vec3f sp34;
@@ -770,7 +770,7 @@ void func_80B54DE0(EnZl3* this, GlobalContext* globalCtx) {
}
void func_80B54E14(EnZl3* this, AnimationHeader* animation, u8 arg2, f32 transitionRate, s32 arg4) {
f32 frameCount = SkelAnime_GetFrameCount(&animation->genericHeader);
f32 frameCount = SkelAnime_GetFrameCount(animation);
f32 playbackSpeed;
f32 unk0;
f32 fc;
@@ -1068,7 +1068,7 @@ void func_80B559C4(EnZl3* this) {
Vec3f* thisPos = &this->actor.posRot.pos;
Vec3f* unk_32C = &this->unk_32C;
Vec3f* unk_338 = &this->unk_338;
f32 temp_f0 = func_8006F9BC(SkelAnime_GetFrameCount(&D_06005248.genericHeader), 0,
f32 temp_f0 = func_8006F9BC(SkelAnime_GetFrameCount(&D_06005248), 0,
(s32)this->skelAnime.animCurrentFrame, 3, 3);
thisPos->x = unk_32C->x + (temp_f0 * (unk_338->x - unk_32C->x));
@@ -2468,7 +2468,7 @@ void func_80B593D0(EnZl3* this, GlobalContext* globalCtx) {
func_80B58C08(this, globalCtx);
}
s32 func_80B5944C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx,
s32 func_80B5944C(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
Gfx** gfx) {
if (limbIndex == 14) {
Mtx* mtx = Graph_Alloc(globalCtx->state.gfxCtx, sizeof(Mtx) * 7);
@@ -2685,8 +2685,8 @@ void EnZl3_Init(Actor* thisx, GlobalContext* globalCtx) {
ActorShape_Init(shape, 0.0f, ActorShadow_DrawFunc_Circle, 30.0f);
shape->unk_14 = 0;
func_80B533B0(thisx, globalCtx);
SkelAnime_InitSV(globalCtx, &this->skelAnime, &D_06010D70, NULL, this->limbDrawTable, this->transitionDrawTable,
15);
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_06010D70, NULL, this->limbDrawTable, this->transitionDrawTable,
15);
switch (func_80B54DD4(this)) {
case 1:
@@ -2700,12 +2700,12 @@ void EnZl3_Init(Actor* thisx, GlobalContext* globalCtx) {
osSyncPrintf("ゼルダ姫のEn_Zl3_Actor_ctは通った!!!!!!!!!!!!!!!!!!!!!!!!!\n");
}
static OverrideLimbDraw2 sOverrideLimbDrawFuncs[] = {
static OverrideLimbDraw sOverrideLimbDrawFuncs[] = {
func_80B5458C,
func_80B5944C,
};
s32 EnZl3_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx,
s32 EnZl3_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, void* thisx,
Gfx** gfx) {
EnZl3* this = THIS;
@@ -2739,8 +2739,8 @@ void func_80B59FF4(EnZl3* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, 0, 0, 0, 255);
gSPSegment(POLY_OPA_DISP++, 11, &D_80116280[2]);
POLY_OPA_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnZl3_OverrideLimbDraw, EnZl3_PostLimbDraw, &this->actor, POLY_OPA_DISP);
POLY_OPA_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnZl3_OverrideLimbDraw, EnZl3_PostLimbDraw, this, POLY_OPA_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_zl3.c", 2190);
}
@@ -2764,8 +2764,8 @@ void func_80B5A1D0(EnZl3* this, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 0, this->unk_258);
gSPSegment(POLY_XLU_DISP++, 11, &D_80116280[0]);
POLY_XLU_DISP = SkelAnime_DrawSV2(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnZl3_OverrideLimbDraw, NULL, &this->actor, POLY_XLU_DISP);
POLY_XLU_DISP = SkelAnime_DrawFlex(globalCtx, skelAnime->skeleton, skelAnime->limbDrawTbl, skelAnime->dListCount,
EnZl3_OverrideLimbDraw, NULL, this, POLY_XLU_DISP);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_zl3.c", 2234);
}
@@ -223,7 +223,7 @@ void MagicWind_Update(Actor* thisx, GlobalContext* globalCtx) {
this->actionFunc(this, globalCtx);
}
s32 MagicWind_OverrideLimbDraw(GlobalContext* globalCtx, SkelAnimeCurve* skelCurve, s32 limbIndex, Actor* thisx) {
s32 MagicWind_OverrideLimbDraw(GlobalContext* globalCtx, SkelAnimeCurve* skelCurve, s32 limbIndex, void* thisx) {
MagicWind* this = THIS;
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_magic_wind.c", 615);
File diff suppressed because it is too large Load Diff