mirror of https://github.com/zeldaret/mm.git
Document stray fairy related objects (#552)
This commit is contained in:
parent
6125d48b07
commit
e7ba2c507d
|
|
@ -942,36 +942,39 @@
|
|||
<Limb Name="gameplay_keep_Standardlimb_02AF34" Type="Standard" Offset="0x2AF34" />
|
||||
<Skeleton Name="gameplay_keep_Skel_02AF58" Type="Flex" LimbType="Standard" Offset="0x2AF58" />
|
||||
<Animation Name="gameplay_keep_Anim_02B2E8" Offset="0x2B2E8" />
|
||||
<Animation Name="gameplay_keep_Anim_02B494" Offset="0x2B494" />
|
||||
<DList Name="gameplay_keep_DL_02B6B0" Offset="0x2B6B0" />
|
||||
<DList Name="gameplay_keep_DL_02B748" Offset="0x2B748" />
|
||||
<DList Name="gameplay_keep_DL_02B7E0" Offset="0x2B7E0" />
|
||||
<DList Name="gameplay_keep_DL_02B888" Offset="0x2B888" />
|
||||
<DList Name="gameplay_keep_DL_02B920" Offset="0x2B920" />
|
||||
<DList Name="gameplay_keep_DL_02B9B8" Offset="0x2B9B8" />
|
||||
<DList Name="gameplay_keep_DL_02BA68" Offset="0x2BA68" />
|
||||
<DList Name="gameplay_keep_DL_02BB00" Offset="0x2BB00" />
|
||||
<DList Name="gameplay_keep_DL_02BB98" Offset="0x2BB98" />
|
||||
<Texture Name="gameplay_keep_Tex_02BC30" OutName="tex_02BC30" Format="ia8" Width="32" Height="32" Offset="0x2BC30" />
|
||||
<Texture Name="gameplay_keep_Tex_02C030" OutName="tex_02C030" Format="ia8" Width="16" Height="32" Offset="0x2C030" />
|
||||
<Texture Name="gameplay_keep_Tex_02C230" OutName="tex_02C230" Format="ia8" Width="32" Height="32" Offset="0x2C230" />
|
||||
<Texture Name="gameplay_keep_Tex_02C630" OutName="tex_02C630" Format="ia8" Width="16" Height="16" Offset="0x2C630" />
|
||||
<Texture Name="gameplay_keep_Tex_02C730" OutName="tex_02C730" Format="i4" Width="16" Height="16" Offset="0x2C730" />
|
||||
<TextureAnimation Name="gameplay_keep_Matanimheader_02C818" Offset="0x2C818" />
|
||||
<TextureAnimation Name="gameplay_keep_Matanimheader_02C890" Offset="0x2C890" />
|
||||
<TextureAnimation Name="gameplay_keep_Matanimheader_02C908" Offset="0x2C908" />
|
||||
<TextureAnimation Name="gameplay_keep_Matanimheader_02C980" Offset="0x2C980" />
|
||||
<TextureAnimation Name="gameplay_keep_Matanimheader_02C9F8" Offset="0x2C9F8" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_02CA08" Type="Standard" Offset="0x2CA08" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_02CA14" Type="Standard" Offset="0x2CA14" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_02CA20" Type="Standard" Offset="0x2CA20" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_02CA2C" Type="Standard" Offset="0x2CA2C" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_02CA38" Type="Standard" Offset="0x2CA38" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_02CA44" Type="Standard" Offset="0x2CA44" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_02CA50" Type="Standard" Offset="0x2CA50" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_02CA5C" Type="Standard" Offset="0x2CA5C" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_02CA68" Type="Standard" Offset="0x2CA68" />
|
||||
<Skeleton Name="gameplay_keep_Skel_02CA98" Type="Flex" LimbType="Standard" Offset="0x2CA98" />
|
||||
|
||||
<!-- Stray Fairy -->
|
||||
<Animation Name="gStrayFairyFlyingAnim" Offset="0x2B494" /> <!-- Original name is "ys_fly01" -->
|
||||
<DList Name="gStrayFairyRightFacingHeadDL" Offset="0x2B6B0" />
|
||||
<DList Name="gStrayFairyLeftFacingHeadDL" Offset="0x2B748" />
|
||||
<DList Name="gStrayFairyGlowDL" Offset="0x2B7E0" />
|
||||
<DList Name="gStrayFairyTorsoDL" Offset="0x2B888" />
|
||||
<DList Name="gStrayFairyLeftArmDL" Offset="0x2B920" />
|
||||
<DList Name="gStrayFairyPelvisAndLegsDL" Offset="0x2B9B8" />
|
||||
<DList Name="gStrayFairyRightArmDL" Offset="0x2BA68" />
|
||||
<DList Name="gStrayFairyRightWingDL" Offset="0x2BB00" />
|
||||
<DList Name="gStrayFairyLeftWingDL" Offset="0x2BB98" />
|
||||
<Texture Name="gStrayFairyRightFacingHeadTex" OutName="stray_fairy_right_facing_head" Format="ia8" Width="32" Height="32" Offset="0x2BC30" />
|
||||
<Texture Name="gStrayFairyBodyTex" OutName="stray_fairy_body" Format="ia8" Width="16" Height="32" Offset="0x2C030" />
|
||||
<Texture Name="gStrayFairyLeftFacingHeadTex" OutName="stray_fairy_left_facing_head" Format="ia8" Width="32" Height="32" Offset="0x2C230" />
|
||||
<Texture Name="gStrayFairyWingTex" OutName="stray_fairy_wing" Format="ia8" Width="16" Height="16" Offset="0x2C630" />
|
||||
<Texture Name="gStrayFairyGlowTex" OutName="stray_fairy_glow" Format="i4" Width="16" Height="16" Offset="0x2C730" />
|
||||
<TextureAnimation Name="gStrayFairyClockTownTexAnim" Offset="0x2C818" />
|
||||
<TextureAnimation Name="gStrayFairySnowheadTexAnim" Offset="0x2C890" />
|
||||
<TextureAnimation Name="gStrayFairyWoodfallTexAnim" Offset="0x2C908" />
|
||||
<TextureAnimation Name="gStrayFairyGreatBayTexAnim" Offset="0x2C980" />
|
||||
<TextureAnimation Name="gStrayFairyStoneTowerTexAnim" Offset="0x2C9F8" />
|
||||
<Limb Name="gStrayFairyRightFacingHeadLimb" Type="Standard" Offset="0x2CA08" />
|
||||
<Limb Name="gStrayFairyLeftWingLimb" Type="Standard" Offset="0x2CA14" />
|
||||
<Limb Name="gStrayFairyRightWingLimb" Type="Standard" Offset="0x2CA20" />
|
||||
<Limb Name="gStrayFairyGlowLimb" Type="Standard" Offset="0x2CA2C" />
|
||||
<Limb Name="gStrayFairyTorsoLimb" Type="Standard" Offset="0x2CA38" />
|
||||
<Limb Name="gStrayFairyRightArmLimb" Type="Standard" Offset="0x2CA44" />
|
||||
<Limb Name="gStrayFairyPelvisAndLegsLimb" Type="Standard" Offset="0x2CA50" />
|
||||
<Limb Name="gStrayFairyLeftArmLimb" Type="Standard" Offset="0x2CA5C" />
|
||||
<Limb Name="gStrayFairyLeftFacingHeadLimb" Type="Standard" Offset="0x2CA68" />
|
||||
<Skeleton Name="gStrayFairySkel" Type="Flex" LimbType="Standard" Offset="0x2CA98" />
|
||||
|
||||
<Texture Name="gameplay_keep_Tex_02CAA8" OutName="tex_02CAA8" Format="i4" Width="16" Height="16" Offset="0x2CAA8" />
|
||||
<Texture Name="gameplay_keep_Tex_02CB30" OutName="tex_02CB30" Format="i8" Width="16" Height="16" Offset="0x2CB30" />
|
||||
<Texture Name="gameplay_keep_Tex_02CC30" OutName="tex_02CC30" Format="rgba16" Width="32" Height="32" Offset="0x2CC30" />
|
||||
|
|
|
|||
|
|
@ -3896,13 +3896,6 @@ extern AnimationHeader D_04029140;
|
|||
extern Gfx D_04029CB0[];
|
||||
extern Gfx D_04029CF0[];
|
||||
extern UNK_TYPE D_04029D20;
|
||||
extern AnimationHeader D_0402B494;
|
||||
extern AnimatedMaterial D_0402C818;
|
||||
extern AnimatedMaterial D_0402C890;
|
||||
extern AnimatedMaterial D_0402C908;
|
||||
extern AnimatedMaterial D_0402C980;
|
||||
extern AnimatedMaterial D_0402C9F8;
|
||||
extern FlexSkeletonHeader D_0402CA98;
|
||||
extern Gfx D_0402E510[];
|
||||
extern AnimationHeader D_0402E65C;
|
||||
extern AnimationHeader D_0402F0EC;
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
*/
|
||||
|
||||
#include "z_en_elforg.h"
|
||||
#include "objects/gameplay_keep/gameplay_keep.h"
|
||||
|
||||
#define FLAGS 0x00000010
|
||||
|
||||
|
|
@ -72,7 +73,8 @@ void EnElforg_Init(Actor* thisx, GlobalContext* globalCtx) {
|
|||
Actor_SetScale(&this->actor, 0.01f);
|
||||
this->flags = 0;
|
||||
this->direction = 0;
|
||||
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &D_0402CA98, &D_0402B494, this->jointTable, this->jointTable, 10);
|
||||
SkelAnime_InitFlex(globalCtx, &this->skelAnime, &gStrayFairySkel, &gStrayFairyFlyingAnim, this->jointTable,
|
||||
this->jointTable, STRAY_FAIRY_LIMB_MAX);
|
||||
this->skelAnime.playSpeed = 1.0f;
|
||||
ActorShape_Init(&this->actor.shape, 0.0f, NULL, 0.0f);
|
||||
this->actor.shape.shadowAlpha = 255;
|
||||
|
|
@ -575,13 +577,14 @@ s32 EnElforg_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dLi
|
|||
EnElforg* this = THIS;
|
||||
|
||||
if (this->direction < 0) {
|
||||
if (limbIndex == 9) {
|
||||
if (limbIndex == STRAY_FAIRY_LIMB_LEFT_FACING_HEAD) {
|
||||
*dList = NULL;
|
||||
}
|
||||
} else if (limbIndex == 1) {
|
||||
} else if (limbIndex == STRAY_FAIRY_LIMB_RIGHT_FACING_HEAD) {
|
||||
*dList = NULL;
|
||||
}
|
||||
return 0;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
void EnElforg_Draw(Actor* thisx, GlobalContext* globalCtx) {
|
||||
|
|
@ -589,22 +592,23 @@ void EnElforg_Draw(Actor* thisx, GlobalContext* globalCtx) {
|
|||
EnElforg* this = THIS;
|
||||
|
||||
OPEN_DISPS(globalCtx->state.gfxCtx);
|
||||
|
||||
func_8012C2DC(globalCtx->state.gfxCtx);
|
||||
switch (this->area) {
|
||||
case STRAY_FAIRY_AREA_WOODFALL:
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(&D_0402C908));
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(gStrayFairyWoodfallTexAnim));
|
||||
break;
|
||||
case STRAY_FAIRY_AREA_SNOWHEAD:
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(&D_0402C890));
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(gStrayFairySnowheadTexAnim));
|
||||
break;
|
||||
case STRAY_FAIRY_AREA_GREAT_BAY:
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(&D_0402C980));
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(gStrayFairyGreatBayTexAnim));
|
||||
break;
|
||||
case STRAY_FAIRY_AREA_STONE_TOWER:
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(&D_0402C9F8));
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(gStrayFairyStoneTowerTexAnim));
|
||||
break;
|
||||
default:
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(&D_0402C818));
|
||||
AnimatedMat_Draw(globalCtx, Lib_SegmentedToVirtual(gStrayFairyClockTownTexAnim));
|
||||
break;
|
||||
}
|
||||
Matrix_InsertMatrix(&globalCtx->billboardMtxF, MTXMODE_APPLY);
|
||||
|
|
|
|||
|
|
@ -33,6 +33,20 @@ typedef enum {
|
|||
STRAY_FAIRY_AREA_MAX
|
||||
} StrayFairyArea;
|
||||
|
||||
typedef enum {
|
||||
/* 0 */ STRAY_FAIRY_LIMB_NONE,
|
||||
/* 1 */ STRAY_FAIRY_LIMB_RIGHT_FACING_HEAD,
|
||||
/* 2 */ STRAY_FAIRY_LIMB_LEFT_WING,
|
||||
/* 3 */ STRAY_FAIRY_LIMB_RIGHT_WING,
|
||||
/* 4 */ STRAY_FAIRY_LIMB_GLOW,
|
||||
/* 5 */ STRAY_FAIRY_LIMB_TORSO,
|
||||
/* 6 */ STRAY_FAIRY_LIMB_RIGHT_ARM,
|
||||
/* 7 */ STRAY_FAIRY_LIMB_PELVIS_AND_LEGS,
|
||||
/* 8 */ STRAY_FAIRY_LIMB_LEFT_ARM,
|
||||
/* 9 */ STRAY_FAIRY_LIMB_LEFT_FACING_HEAD,
|
||||
/* 10 */ STRAY_FAIRY_LIMB_MAX,
|
||||
} StrayFairyLimbs;
|
||||
|
||||
struct EnElforg;
|
||||
|
||||
typedef void (*EnElforgActionFunc)(struct EnElforg*, GlobalContext*);
|
||||
|
|
@ -40,11 +54,11 @@ typedef void (*EnElforgActionFunc)(struct EnElforg*, GlobalContext*);
|
|||
typedef struct EnElforg {
|
||||
/* 0x000 */ Actor actor;
|
||||
/* 0x144 */ SkelAnime skelAnime;
|
||||
/* 0x188 */ Vec3s jointTable[10];
|
||||
/* 0x188 */ Vec3s jointTable[STRAY_FAIRY_LIMB_MAX];
|
||||
/* 0x1C4 */ ColliderCylinder collider;
|
||||
/* 0x210 */ Actor* enemy;
|
||||
/* 0x214 */ u16 flags;
|
||||
/* 0x216 */ s16 direction; // negative when facing left, positive when facing right
|
||||
/* 0x216 */ s16 direction; // negative when facing right, positive when facing left
|
||||
/* 0x218 */ s16 area;
|
||||
/* 0x21C */ s32 timer;
|
||||
/* 0x220 */ s32 secondaryTimer;
|
||||
|
|
|
|||
Loading…
Reference in New Issue