mirror of
https://github.com/zeldaret/oot
synced 2026-06-04 10:48:51 -04:00
name SkelAnime_InitLinkAnimetion, name load animation types and callbacks, rename several segement addresses in decompiled actors
This commit is contained in:
+43
-42
@@ -1131,72 +1131,73 @@ s32 Scene_ExecuteCommands(GlobalContext* globalCtx, SceneCmd* sceneCmd);
|
||||
void func_80098CBC(GlobalContext* globalCtx, u8* nbTransitionActors);
|
||||
void func_800994A0(GlobalContext* globalCtx);
|
||||
void Scene_Draw(GlobalContext* globalCtx);
|
||||
void SkelAnime_LodDraw(GlobalContext* globalCtx, u32* limbIndex, Vec3s* actorDrawTable,
|
||||
void SkelAnime_LodDraw(GlobalContext* globalCtx, Skeleton* skeleton, Vec3s* actorDrawTable,
|
||||
SkelAnime_LimbUpdateMatrix updateMtxFunc, SkelAnime_LimbAppendDlist appendDlistFunc,
|
||||
Actor* actor, s32 dListIndex);
|
||||
void SkelAnime_LodDrawSV(GlobalContext* globalCtx, u32* limbTable, Vec3s* actorDrawTable, s32 limbCount,
|
||||
void SkelAnime_LodDrawSV(GlobalContext* globalCtx, Skeleton* skeleton, Vec3s* actorDrawTable, s32 limbCount,
|
||||
SkelAnime_LimbUpdateMatrix updateMtxFunc, SkelAnime_LimbAppendDlist appendDlistFunc,
|
||||
Actor* actor, s32 dListIndex);
|
||||
void SkelAnime_Draw(GlobalContext* globalCtx, u32* limbIndex, Vec3s* actorDrawTable,
|
||||
void SkelAnime_Draw(GlobalContext* globalCtx, Skeleton* skeleton, Vec3s* actorDrawTable,
|
||||
SkelAnime_LimbUpdateMatrix updateMtxFunc, SkelAnime_LimbAppendDlist appendDlistFunc, Actor* actor);
|
||||
void SkelAnime_DrawSV(GlobalContext* globalCtx, u32* limbTable, Vec3s* actorDrawTable, u32 dListCount,
|
||||
void SkelAnime_DrawSV(GlobalContext* globalCtx, Skeleton* skeleton, Vec3s* actorDrawTable, s32 limbCount,
|
||||
SkelAnime_LimbUpdateMatrix updateMtxFunc, SkelAnime_LimbAppendDlist appendDlistFunc,
|
||||
Actor* actor);
|
||||
s32 SkelAnime_GetFrameCount(u32 animation);
|
||||
Gfx* SkelAnime_Draw2(GlobalContext* globalCtx, u32* limbTable, Vec3s* actorDrawTable,
|
||||
s16 SkelAnime_GetFrameCount(GenericAnimationHeader* animationSeg);
|
||||
Gfx* SkelAnime_Draw2(GlobalContext* globalCtx, Skeleton* skeleton, Vec3s* actorDrawTable,
|
||||
SkelAnime_LimbUpdateMatrix2 updateMtxFunc, SkelAnime_LimbAppendDlist2 appendDlistFunc,
|
||||
Actor* actor, Gfx* gfx);
|
||||
Gfx* SkelAnime_DrawSV2(GlobalContext* globalCtx, u32* limbTable, Vec3s* actorDrawTable, s32 dListCount,
|
||||
Gfx* SkelAnime_DrawSV2(GlobalContext* globalCtx, Skeleton* skeleton, Vec3s* actorDrawTable, s32 dListCount,
|
||||
SkelAnime_LimbUpdateMatrix2 updateMtxFunc, SkelAnime_LimbAppendDlist2 appendDlistFunc,
|
||||
Actor* actor, Gfx* gfx);
|
||||
void func_800A2E70(u8, Vec3s*, Vec3s*, Vec3s*, f32);
|
||||
void func_800A32EC(u16* arg0);
|
||||
void func_800A32F4(s32 arg0);
|
||||
void func_800A3310(void* arg0);
|
||||
void func_800A336C(GlobalContext* globalCtx, u32 linkAnimetionSeg, s32 frame, s32 limbCount, void* ram);
|
||||
void func_800A3478(GlobalContext* globalCtx, s32 vecCount, Vec3s* dst, Vec3s* src);
|
||||
void func_800A34DC(GlobalContext* globalCtx, s32 arg1, Vec3s* arg2, Vec3s* arg3, f32 arg4);
|
||||
void func_800A3548(GlobalContext* globalCtx, s32 vecCount, s32 dst, s32 src, s32 index);
|
||||
void func_800A35B4(GlobalContext* globalCtx, s32 vecCount, Vec3s* dst, Vec3s* src, u8* index);
|
||||
void func_800A3620(GlobalContext* globalCtx, Actor* actor, SkelAnime* skelAnime, f32 arg3);
|
||||
void SkelAnime_LoadLinkAnimetion(GlobalContext* globalCtx, LinkAnimetionEntry* linkAnimetionSeg, s32 frame, s32 limbCount, void* ram);
|
||||
void SkelAnime_LoadAnimationType1(GlobalContext* globalCtx, s32 vecCount, Vec3s* dst, Vec3s* src);
|
||||
void SkelAnime_LoadAnimationType2(GlobalContext* globalCtx, s32 limbCount, Vec3s* arg2, Vec3s* arg3, f32 arg4);
|
||||
void SkelAnime_LoadAnimationType3(GlobalContext* globalCtx, s32 vecCount, Vec3s* dst, Vec3s* src, u8* index);
|
||||
void SkelAnime_LoadAnimationType4(GlobalContext* globalCtx, s32 vecCount, Vec3s* dst, Vec3s* src, u8* index);
|
||||
void SkelAnime_LoadAnimationType5(GlobalContext* globalCtx, Actor* actor, SkelAnime* skelAnime, f32 arg3);
|
||||
void func_800A390C(GlobalContext* globalCtx, AnimationContext* animationCtx);
|
||||
void func_800A39AC(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 limbHeaderSeg, u32* animation, s32 flags,
|
||||
Vec3s* actorDrawTbl, Vec3s* arg6, s32 limbBufCount);
|
||||
void SkelAnime_InitLinkAnimetion(GlobalContext* globalCtx, SkelAnime* skelAnime, SkeletonHeader* skeletonHeaderSeg,
|
||||
LinkAnimetionEntry* linkAnimetionEntrySeg, s32 flags, Vec3s* actorDrawTbl, Vec3s* arg6, s32 limbBufCount);
|
||||
void func_800A3B8C(SkelAnime* skelAnime);
|
||||
void func_800A3BC0(GlobalContext* globalCtx, SkelAnime* skelAnime);
|
||||
void func_800A3C9C(GlobalContext* globalCtx, SkelAnime* skelAnime);
|
||||
void func_800A3EE8(GlobalContext* globalCtx, SkelAnime* skelAnime, f32 arg2);
|
||||
void func_800A3F08(GlobalContext* globalCtx, SkelAnime* skelAnime, u32* animation, f32 playbackSpeed, f32 arg4,
|
||||
f32 frameCount, u8 arg6, f32 arg7);
|
||||
void func_800A407C(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 animation);
|
||||
void func_800A40DC(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 animation, f32 playbackSpeed);
|
||||
void func_800A4140(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 animation);
|
||||
void func_800A419C(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 animation, f32 playbackSpeed);
|
||||
void SkelAnime_LinkChangeAnimation(GlobalContext* globalCtx, SkelAnime* skelAnime, LinkAnimetionEntry* linkAnimetionEntrySeg, f32 playbackSpeed,
|
||||
f32 arg4, f32 frameCount, u8 arg6, f32 arg7);
|
||||
void func_800A407C(GlobalContext* globalCtx, SkelAnime* skelAnime, LinkAnimetionEntry* linkAnimetionEntrySeg);
|
||||
void func_800A40DC(GlobalContext* globalCtx, SkelAnime* skelAnime, LinkAnimetionEntry* linkAnimetionEntrySeg, f32 playbackSpeed);
|
||||
void func_800A4140(GlobalContext* globalCtx, SkelAnime* skelAnime, LinkAnimetionEntry* linkAnimetionEntrySeg);
|
||||
void func_800A419C(GlobalContext* globalCtx, SkelAnime* skelAnime, LinkAnimetionEntry* linkAnimetionEntrySeg, f32 playbackSpeed);
|
||||
void func_800A41FC(GlobalContext* globalCtx, SkelAnime* skelAnime);
|
||||
void func_800A425C(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 animation, f32 frame);
|
||||
void func_800A42A0(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 animation, f32 frame);
|
||||
void func_800A425C(GlobalContext* globalCtx, SkelAnime* skelAnime, LinkAnimetionEntry* linkAnimetionEntrySeg, f32 frame);
|
||||
void func_800A42A0(GlobalContext* globalCtx, SkelAnime* skelAnime, LinkAnimetionEntry* linkAnimetionEntrySeg, f32 frame);
|
||||
void func_800A42E4(GlobalContext* globalCtx, SkelAnime* skelAnime, f32 frame);
|
||||
void func_800A431C(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 animationSeg, f32 frame, s32 arg4, f32 arg5,
|
||||
f32 arg6, s32 arg7);
|
||||
void func_800A43B8(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 animation, f32 frame, s32 arg4, f32 arg5,
|
||||
f32 arg6, s32 arg7);
|
||||
void func_800A431C(GlobalContext* globalCtx, SkelAnime* skelAnime, LinkAnimetionEntry* linkAnimetionEntrySeg, f32 frame, LinkAnimetionEntry* linkAnimetionEntrySeg2,
|
||||
f32 arg5, f32 arg6, Vec3s* arg7);
|
||||
void func_800A43B8(GlobalContext* globalCtx, SkelAnime* skelAnime, LinkAnimetionEntry* linkAnimetionEntrySeg, f32 frame, LinkAnimetionEntry* linkAnimetionEntrySeg2,
|
||||
f32 arg5, f32 arg6, Vec3s* arg7);
|
||||
s32 func_800A4530(SkelAnime* skelAnime, f32 arg1);
|
||||
void SkelAnime_Init(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 limbHeaderSeg, u32 animation,
|
||||
Vec3s* actorDrawTable, s32 arg5, s32 limbCount);
|
||||
void SkelAnime_InitSV(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 limbHeaderSeg, u32 animation,
|
||||
Vec3s* actorDrawTable, s32 arg5, s32 limbCount);
|
||||
void SkelAnime_InitSkin(GlobalContext* globalCtx, SkelAnime* skelAnime, u32 limbHeaderSeg, u32 animation);
|
||||
void SkelAnime_Init(GlobalContext* globalCtx, SkelAnime* skelAnime, SkeletonHeader* skeletonHeaderSeg,
|
||||
AnimationHeader* animationseg, Vec3s* actorDrawTable, Vec3s* arg5, s32 limbCount);
|
||||
void SkelAnime_InitSV(GlobalContext* globalCtx, SkelAnime* skelAnime, SkeletonHeader* skeletonHeaderSeg,
|
||||
AnimationHeader* animationseg, Vec3s* actorDrawTable, Vec3s* arg5, s32 limbCount);
|
||||
void SkelAnime_InitSkin(GlobalContext* globalCtx, SkelAnime* skelAnime, SkeletonHeader* skeletonHeaderSeg,
|
||||
AnimationHeader* animationseg);
|
||||
s32 SkelAnime_FrameUpdateMatrix(SkelAnime* skelAnime);
|
||||
void SkelAnime_ChangeAnimationImpl(SkelAnime* skelAnime, u32* animation, f32 playbackSpeed, f32 unk0, f32 frameCount,
|
||||
u8 unk1, f32 transitionRate, s8 unk2);
|
||||
void SkelAnime_ChangeAnimation(SkelAnime* skelAnime, u32 animation, f32 playbackSpeed, f32 unk0, f32 frameCount,
|
||||
u8 unk1, f32 transitionRate);
|
||||
void func_800A51E8(SkelAnime* skelAnime, u32 animation);
|
||||
void func_800A5240(SkelAnime* skelAnime, u32 animation, f32 transitionRate);
|
||||
void func_800A529C(SkelAnime* skelAnime, u32 animation, f32 playbackSpeed);
|
||||
void SkelAnime_ChangeAnimationDefault(SkelAnime* skelAnime, u32 animation);
|
||||
void SkelAnime_ChangeAnimationTransitionRate(SkelAnime* skelAnime, u32 animation, f32 transitionRate);
|
||||
void SkelAnime_ChangeAnimationPlaybackSpeed(SkelAnime* skelAnime, u32 animation, f32 playbackSpeed);
|
||||
void SkelAnime_ChangeAnimationImpl(SkelAnime* skelAnime, AnimationHeader* animationseg, f32 playbackSpeed, f32 frame,
|
||||
f32 frameCount, u8 unk1, f32 transitionRate, s8 unk2);
|
||||
void SkelAnime_ChangeAnimation(SkelAnime* skelAnime, AnimationHeader* animationseg, f32 playbackSpeed, f32 unk0,
|
||||
f32 frameCount, u8 unk1, f32 transitionRate);
|
||||
void func_800A51E8(SkelAnime* skelAnime, AnimationHeader* animationseg);
|
||||
void func_800A5240(SkelAnime* skelAnime, AnimationHeader* animationseg, f32 transitionRate);
|
||||
void func_800A529C(SkelAnime* skelAnime, AnimationHeader* animationseg, f32 playbackSpeed);
|
||||
void SkelAnime_ChangeAnimationDefault(SkelAnime* skelAnime, AnimationHeader* animationseg);
|
||||
void SkelAnime_ChangeAnimationTransitionRate(SkelAnime* skelAnime, AnimationHeader* animationseg, f32 transitionRate);
|
||||
void SkelAnime_ChangeAnimationPlaybackSpeed(SkelAnime* skelAnime, AnimationHeader* animationseg, f32 playbackSpeed);
|
||||
void func_800A5408(SkelAnime* skelAnime);
|
||||
void func_800A5428(SkelAnime* skelAnime, Vec3s* dst, Vec3s* src, u8* index);
|
||||
void func_800A54FC(SkelAnime* skelAnime, Vec3f* pos, s16 angle);
|
||||
|
||||
+1
-1
@@ -54,7 +54,7 @@ extern u32 D_0403F070;
|
||||
extern u32 D_04042440;
|
||||
//extern ? D_04048160;
|
||||
extern u32 D_04048180;
|
||||
extern u32 D_04049210;
|
||||
extern Gfx D_04049210[];
|
||||
extern u32 D_04049AD0;
|
||||
//extern ? D_0404D1C0;
|
||||
extern u32 D_0404D450;
|
||||
|
||||
+6
-6
@@ -956,12 +956,12 @@ typedef struct LoadedParticleEntry {
|
||||
|
||||
// Some animation related structure
|
||||
typedef struct {
|
||||
/* 0x00 */ u32 animation;
|
||||
/* 0x04 */ f32 playbackSpeed;
|
||||
/* 0x08 */ f32 unk_08;
|
||||
/* 0x0C */ f32 frameCount;
|
||||
/* 0x10 */ u8 unk_10;
|
||||
/* 0x14 */ f32 transitionRate;
|
||||
/* 0x00 */ AnimationHeader* animation;
|
||||
/* 0x04 */ f32 playbackSpeed;
|
||||
/* 0x08 */ f32 unk_08;
|
||||
/* 0x0C */ f32 frameCount;
|
||||
/* 0x10 */ u8 unk_10;
|
||||
/* 0x14 */ f32 transitionRate;
|
||||
} struct_80034EC0_Entry; // size = 0x18
|
||||
|
||||
typedef struct {
|
||||
|
||||
+51
-40
@@ -7,13 +7,11 @@
|
||||
|
||||
#define LINK_ANIMETION_OFFSET(addr,offset) (((u32)&_link_animetionSegmentRomStart)+((u32)addr)-((u32)&link_animetion_segment)+((u32)offset))
|
||||
#define LIMB_DONE 0xFF
|
||||
#define ANIMATION_ENTRY_MAX 0x32
|
||||
|
||||
struct GlobalContext;
|
||||
struct Actor;
|
||||
|
||||
typedef struct {
|
||||
/* 0x000 */ u32 limbs[1]; // One ore more limbs, index 0 is the root limb.
|
||||
} SkelLimbTable; // Size >= 4
|
||||
typedef struct SkelAnime SkelAnime;
|
||||
|
||||
typedef struct {
|
||||
/* 0x000 */ Vec3s translation; // Translation relative to parent limb. root limb is a tranlation for entire model.
|
||||
@@ -23,39 +21,15 @@ typedef struct {
|
||||
} SkelLimbEntry; // Size = 0xC or 0x10
|
||||
|
||||
typedef struct {
|
||||
/* 0x000 */ u32 limbIndexSeg; // Segment address of SkelLimbIndex.
|
||||
/* 0x000 */ SkelLimbEntry* limbs[1]; // One ore more limbs, index 0 is the root limb.
|
||||
} Skeleton; // Size >= 4
|
||||
|
||||
typedef struct {
|
||||
/* 0x000 */ Skeleton* skeletonSeg; // Segment address of SkelLimbIndex.
|
||||
/* 0x004 */ u8 limbCount; // Number of limbs in the model.
|
||||
/* 0x005 */ char unk_05[3]; // unknown, maybe padding?
|
||||
/* 0x008 */ u8 dListCount; // Number of display lists in the model.
|
||||
} SkelAnimeLimbHeader; // Size = 0xC
|
||||
|
||||
typedef struct SkelAnime {
|
||||
/* 0x00 */ u8 limbCount; // joint_Num
|
||||
/* 0x01 */ u8 unk_01; // state? 00 = loop 02 = don't loop ?
|
||||
/* 0x02 */ u8 dListCount;
|
||||
/* 0x03 */ s8 unk_03;
|
||||
/* 0x04 */ u32 limbIndex;
|
||||
/* 0x08 */ u32* animCurrent;
|
||||
/* 0x0C */ f32 unk_0C;
|
||||
/* 0x10 */ f32 animFrameCount; // ending frame?
|
||||
/* 0x14 */ f32 unk_14; // Loop frame?
|
||||
/* 0x18 */ f32 animCurrentFrame;
|
||||
/* 0x1C */ f32 animPlaybackSpeed;
|
||||
/* 0x20 */ Vec3s* actorDrawTbl; // now_joint
|
||||
/* 0x24 */ Vec3s* unk_24; // morf_joint
|
||||
/* 0x28 */ f32 unk_28;
|
||||
/* 0x2C */ f32 unk_2C;
|
||||
/* 0x30 */ s32 (*animUpdate)();
|
||||
/* 0x34 */ s8 unk_34;
|
||||
/* 0x35 */ u8 unk_35; // flags
|
||||
/* 0x36 */ s16 unk_36;
|
||||
/* 0x38 */ s16 unk_38;
|
||||
/* 0x3A */ s16 unk_3A;
|
||||
/* 0x3C */ s16 unk_3C;
|
||||
/* 0x3E */ s16 unk_3E;
|
||||
/* 0x40 */ s16 unk_40;
|
||||
/* 0x42 */ s16 unk_42;
|
||||
} SkelAnime; // size = 0x44
|
||||
} SkeletonHeader; // Size = 0xC
|
||||
|
||||
typedef s16 AnimationRotationValue;
|
||||
|
||||
@@ -66,15 +40,19 @@ typedef struct {
|
||||
} AnimationRotationIndex; // size = 0x06
|
||||
|
||||
typedef struct {
|
||||
/* 0x000 */ s16 frameCount;
|
||||
/* 0x002 */ s16 unk_02;
|
||||
s16 frameCount;
|
||||
s16 unk_02;
|
||||
} GenericAnimationHeader;
|
||||
|
||||
typedef struct {
|
||||
/* 0x000 */ GenericAnimationHeader genericHeader;
|
||||
/* 0x004 */ u32 rotationValueSeg; // referenced as tbl
|
||||
/* 0x008 */ u32 rotationIndexSeg; // referenced as ref_tbl
|
||||
/* 0x00C */ u16 limit;
|
||||
} AnimationHeader; // size = 0x10
|
||||
|
||||
typedef enum {
|
||||
ANIMATION_TYPE0,
|
||||
ANIMATION_LINKANIMETION,
|
||||
ANIMATION_TYPE1,
|
||||
ANIMATION_TYPE2,
|
||||
ANIMATION_TYPE3,
|
||||
@@ -98,7 +76,7 @@ typedef struct {
|
||||
|
||||
typedef struct {
|
||||
/* 0x000 */ u8 unk_00;
|
||||
/* 0x001 */ u8 unk_01;
|
||||
/* 0x001 */ u8 limbCount;
|
||||
/* 0x004 */ Vec3s* unk_04;
|
||||
/* 0x008 */ Vec3s* unk_08;
|
||||
/* 0x00C */ f32 unk_0C;
|
||||
@@ -154,14 +132,47 @@ typedef struct {
|
||||
typedef struct AnimationContext {
|
||||
s16 animationCount;
|
||||
char unk_02[2];
|
||||
AnimationEntry entries[0x32];
|
||||
AnimationEntry entries[ANIMATION_ENTRY_MAX];
|
||||
} AnimationContext;
|
||||
|
||||
typedef struct {
|
||||
u16 frameCount;
|
||||
GenericAnimationHeader genericHeader;
|
||||
u32 animationSegAddress;
|
||||
} LinkAnimetionEntry;
|
||||
|
||||
struct SkelAnime {
|
||||
/* 0x00 */ u8 limbCount; // joint_Num
|
||||
/* 0x01 */ u8 unk_01; // state? 00 = loop 02 = don't loop ?
|
||||
/* 0x02 */ u8 dListCount;
|
||||
/* 0x03 */ s8 unk_03;
|
||||
/* 0x04 */ Skeleton* skeleton;
|
||||
/* 0x08 */
|
||||
union {
|
||||
AnimationHeader* animCurrentSeg;
|
||||
LinkAnimetionEntry* linkAnimetionSeg;
|
||||
GenericAnimationHeader* genericSeg;
|
||||
};
|
||||
/* 0x0C */ f32 unk_0C;
|
||||
/* 0x10 */ f32 animFrameCount; // ending frame?
|
||||
/* 0x14 */ f32 unk_14; // Loop frame?
|
||||
/* 0x18 */ f32 animCurrentFrame;
|
||||
/* 0x1C */ f32 animPlaybackSpeed;
|
||||
/* 0x20 */ Vec3s* actorDrawTbl; // now_joint
|
||||
/* 0x24 */ Vec3s* unk_24; // morf_joint
|
||||
/* 0x28 */ f32 unk_28;
|
||||
/* 0x2C */ f32 unk_2C;
|
||||
/* 0x30 */ s32 (*animUpdate)();
|
||||
/* 0x34 */ s8 unk_34;
|
||||
/* 0x35 */ u8 unk_35; // flags
|
||||
/* 0x36 */ s16 unk_36;
|
||||
/* 0x38 */ s16 unk_38;
|
||||
/* 0x3A */ s16 unk_3A;
|
||||
/* 0x3C */ s16 unk_3C;
|
||||
/* 0x3E */ s16 unk_3E;
|
||||
/* 0x40 */ s16 unk_40;
|
||||
/* 0x42 */ s16 unk_42;
|
||||
}; // size = 0x44
|
||||
|
||||
typedef s32 (*SkelAnime_LimbUpdateMatrix)(struct GlobalContext* globalCtx, s32 limbIndex, Gfx** dList,
|
||||
Vec3f* pos, Vec3s* rot, struct Actor* actor);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user