mirror of
https://github.com/izzy2lost/2ship2harkinian-Android.git
synced 2026-06-19 01:20:08 -07:00
En_kusa OK and Documented (#640)
* matched one function * More matches * more matches * cleaning up some stuff * making some progress * two new matches, and a partial match * meh...i'll come back to this * fixing ctx names * more matches * OK and documented * fixing data stuff * PR suggestions * fixing name and DL issues * fixing pr suggestions * PR feedback * ....format.... * PR fix * fixes * dang format * fixing name * I'm blind * fixing obj_grass
This commit is contained in:
@@ -40,8 +40,8 @@
|
||||
<DList Name="gameplay_field_keep_DL_006760" Offset="0x6760" />
|
||||
<Texture Name="gameplay_field_keep_Tex_006810" OutName="tex_006810" Format="rgba16" Width="32" Height="32" Offset="0x6810" />
|
||||
<Texture Name="gameplay_field_keep_Tex_007010" OutName="tex_007010" Format="rgba16" Width="32" Height="32" Offset="0x7010" />
|
||||
<DList Name="gameplay_field_keep_DL_0078A0" Offset="0x78A0" />
|
||||
<DList Name="gameplay_field_keep_DL_007938" Offset="0x7938" />
|
||||
<DList Name="gKusaBushType1" Offset="0x78A0" />
|
||||
<DList Name="gKusaBushType2" Offset="0x7938" />
|
||||
<Texture Name="gameplay_field_keep_Tex_0079D0" OutName="tex_0079D0" Format="i8" Width="64" Height="32" Offset="0x79D0" />
|
||||
<Texture Name="gameplay_field_keep_Tex_0081D0" OutName="tex_0081D0" Format="ia8" Width="64" Height="32" Offset="0x81D0" />
|
||||
<DList Name="gameplay_field_keep_DL_0089D0" Offset="0x89D0" />
|
||||
|
||||
@@ -1172,8 +1172,8 @@
|
||||
<Limb Name="gameplay_keep_Standardlimb_05272C" Type="Standard" Offset="0x5272C" />
|
||||
<Limb Name="gameplay_keep_Standardlimb_052738" Type="Standard" Offset="0x52738" />
|
||||
<Skeleton Name="gameplay_keep_Skel_0527A0" Type="Normal" LimbType="Standard" Offset="0x527A0" />
|
||||
<DList Name="gameplay_keep_DL_0527F0" Offset="0x527F0" />
|
||||
<DList Name="gameplay_keep_DL_0528B0" Offset="0x528B0" />
|
||||
<DList Name="gKakeraLeafMiddle" Offset="0x527F0" />
|
||||
<DList Name="gKakeraLeafTip" Offset="0x528B0" />
|
||||
<Texture Name="gameplay_keep_Tex_052940" OutName="tex_052940" Format="rgba16" Width="32" Height="32" Offset="0x52940" />
|
||||
<Texture Name="gameplay_keep_Tex_053140" OutName="tex_053140" Format="rgba16" Width="32" Height="32" Offset="0x53140" />
|
||||
<Texture Name="gameplay_keep_Tex_053940" OutName="tex_053940" Format="i4" Width="64" Height="64" Offset="0x53940" />
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<Root>
|
||||
<File Name="object_kusa" Segment="6">
|
||||
<DList Name="object_kusa_DL_000140" Offset="0x140" />
|
||||
<DList Name="object_kusa_DL_0002E0" Offset="0x2E0" />
|
||||
<DList Name="gKusaSprout" Offset="0x140" />
|
||||
<DList Name="gKusaStump" Offset="0x2E0" />
|
||||
</File>
|
||||
</Root>
|
||||
|
||||
@@ -1469,9 +1469,7 @@ beginseg
|
||||
name "ovl_En_Kusa"
|
||||
compress
|
||||
include "build/src/overlays/actors/ovl_En_Kusa/z_en_kusa.o"
|
||||
include "build/data/ovl_En_Kusa/ovl_En_Kusa.data.o"
|
||||
include "build/data/ovl_En_Kusa/ovl_En_Kusa.bss.o"
|
||||
include "build/data/ovl_En_Kusa/ovl_En_Kusa.reloc.o"
|
||||
include "build/src/overlays/actors/ovl_En_Kusa/ovl_En_Kusa_reloc.o"
|
||||
endseg
|
||||
|
||||
beginseg
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -7,12 +7,33 @@ struct EnKusa;
|
||||
|
||||
typedef void (*EnKusaActionFunc)(struct EnKusa*, GlobalContext*);
|
||||
|
||||
typedef enum {
|
||||
/* 0 */ ENKUSA_TYPE_BUSH,
|
||||
/* 1 */ ENKUSA_TYPE_REGROWING_GRASS,
|
||||
/* 2 */ ENKUSA_TYPE_GRASS,
|
||||
/* 3 */ ENKUSA_TYPE_GRASS_2
|
||||
} EnKusaType;
|
||||
|
||||
typedef struct EnKusa {
|
||||
/* 0x0000 */ Actor actor;
|
||||
/* 0x0144 */ EnKusaActionFunc actionFunc;
|
||||
/* 0x0148 */ char unk_148[0x54];
|
||||
/* 0x000 */ Actor actor;
|
||||
/* 0x144 */ EnKusaActionFunc actionFunc;
|
||||
/* 0x148 */ ColliderCylinder collider;
|
||||
/* 0x194 */ u8 timer;
|
||||
/* 0x195 */ s8 objIndex;
|
||||
/* 0x196 */ s8 kusaMtxIdx;
|
||||
/* 0x197 */ u8 isCut;
|
||||
/* 0x198 */ u8 isInWater;
|
||||
} EnKusa; // size = 0x19C
|
||||
|
||||
extern const ActorInit En_Kusa_InitVars;
|
||||
|
||||
#define KUSA_GET_COLLECTIBLE_ID(thisx) ((((thisx)->params >> 8) & 0x7F))
|
||||
#define KUSA_GET_RAND_COLLECTIBLE_ID(thisx) (((thisx)->params >> 8) & 0xF)
|
||||
#define KUSA_SHOULD_SPAWN_BUGS(thisx) (((thisx)->params >> 0x4) & 1)
|
||||
#define KUSA_GET_PARAMS_0C(thisx) (((thisx)->params >> 0xC) & 0x1)
|
||||
#define KUSA_GET_PARAMS_3F(thisx) (((thisx)->params >> 0x2) & 0x3F)
|
||||
|
||||
|
||||
#define GET_KUSA_TYPE(thisx)((thisx)->params & 0x3)
|
||||
|
||||
#endif // Z_EN_KUSA_H
|
||||
|
||||
@@ -1310,8 +1310,8 @@ void EnKusa2_Update(Actor* thisx, GlobalContext* globalCtx) {
|
||||
|
||||
void func_80A5E6F0(Actor* thisx, GlobalContext* globalCtx) {
|
||||
static Gfx* D_80A5EB68[] = {
|
||||
gameplay_keep_DL_0528B0,
|
||||
gameplay_keep_DL_0527F0,
|
||||
gKakeraLeafTip,
|
||||
gKakeraLeafMiddle,
|
||||
};
|
||||
EnKusa2* this = THIS;
|
||||
s32 i;
|
||||
@@ -1343,7 +1343,7 @@ void func_80A5E80C(GlobalContext* globalCtx, s32 arg1) {
|
||||
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 255, 255, 255, arg1);
|
||||
gSPDisplayList(POLY_XLU_DISP++, gameplay_field_keep_DL_007938);
|
||||
gSPDisplayList(POLY_XLU_DISP++, gKusaBushType2);
|
||||
|
||||
CLOSE_DISPS(globalCtx->state.gfxCtx);
|
||||
}
|
||||
@@ -1356,7 +1356,7 @@ void EnKusa2_Draw(Actor* thisx, GlobalContext* globalCtx) {
|
||||
(this->actor.projectedPos.z < 400.0f)) {
|
||||
func_80A5B954(&D_80A60908[this->unk_1CE], 0.0015f);
|
||||
}
|
||||
Gfx_DrawDListOpa(globalCtx, gameplay_field_keep_DL_0078A0);
|
||||
Gfx_DrawDListOpa(globalCtx, gKusaBushType1);
|
||||
} else if (this->actor.projectedPos.z < 1300.0f) {
|
||||
func_80A5E80C(globalCtx, (1300.0f - this->actor.projectedPos.z) * 2.55f);
|
||||
}
|
||||
@@ -1370,14 +1370,14 @@ void func_80A5E9B4(Actor* thisx, GlobalContext* globalCtx) {
|
||||
sp18.z = thisx->shape.rot.z + D_80A5EAFC.z;
|
||||
Matrix_SetStateRotationAndTranslation(thisx->world.pos.x, thisx->world.pos.y, thisx->world.pos.z, &sp18);
|
||||
Matrix_Scale(thisx->scale.x, thisx->scale.y, thisx->scale.z, MTXMODE_APPLY);
|
||||
Gfx_DrawDListOpa(globalCtx, gameplay_field_keep_DL_0078A0);
|
||||
Gfx_DrawDListOpa(globalCtx, gKusaBushType1);
|
||||
}
|
||||
|
||||
void func_80A5EA48(Actor* thisx, GlobalContext* globalCtx) {
|
||||
EnKusa2* this = THIS;
|
||||
|
||||
if (this->unk_1CF == 0xFF) {
|
||||
Gfx_DrawDListOpa(globalCtx, gameplay_field_keep_DL_0078A0);
|
||||
Gfx_DrawDListOpa(globalCtx, gKusaBushType1);
|
||||
} else {
|
||||
func_80A5E80C(globalCtx, this->unk_1CF);
|
||||
}
|
||||
|
||||
@@ -90,7 +90,7 @@ static AnimationInfoS sAnimations[] = {
|
||||
{ &object_dnt_Anim_002670, 1.0f, 0, -1, ANIMMODE_ONCE, 0 },
|
||||
};
|
||||
|
||||
Gfx* D_80BCCCDC[] = { gameplay_keep_DL_0527F0, gameplay_keep_DL_0528B0 };
|
||||
Gfx* D_80BCCCDC[] = { gKakeraLeafMiddle, gKakeraLeafTip };
|
||||
|
||||
Vec3f D_80BCCCE4 = { 0.0f, -0.5f, 0.0f };
|
||||
|
||||
|
||||
@@ -303,8 +303,8 @@ void func_809375C8(ObjBean* this, GlobalContext* globalCtx) {
|
||||
|
||||
void func_809375F4(ObjBean* this, GlobalContext* globalCtx) {
|
||||
static Gfx* D_80939024[] = {
|
||||
gameplay_keep_DL_0527F0,
|
||||
gameplay_keep_DL_0528B0,
|
||||
gKakeraLeafMiddle,
|
||||
gKakeraLeafTip,
|
||||
};
|
||||
Vec3f spC4;
|
||||
Vec3f spB8;
|
||||
|
||||
@@ -118,7 +118,7 @@ void func_809A9314(ObjGrassStruct1_1* ptr, GlobalContext* globalCtx) {
|
||||
spBC.z = (Rand_ZeroOne() - 0.5f) * 8.0f;
|
||||
|
||||
EffectSsKakera_Spawn(globalCtx, &spB0, &spBC, &spB0, -100, 64, 40, 3, 0,
|
||||
D_809AAB7C[(s32)(Rand_ZeroOne() * 111.1f) & 7], 0, 0, 80, -1, 1, gameplay_keep_DL_0527F0);
|
||||
D_809AAB7C[(s32)(Rand_ZeroOne() * 111.1f) & 7], 0, 0, 80, -1, 1, gKakeraLeafMiddle);
|
||||
|
||||
spB0.x = ptr->unk_00.x + (ptr2->x * 16.0f);
|
||||
spB0.y = (ptr->unk_00.y + (ptr2->y * 16.0f)) + 10.0f;
|
||||
@@ -129,7 +129,7 @@ void func_809A9314(ObjGrassStruct1_1* ptr, GlobalContext* globalCtx) {
|
||||
spBC.z = (Rand_ZeroOne() - 0.5f) * 6.0f;
|
||||
|
||||
EffectSsKakera_Spawn(globalCtx, &spB0, &spBC, &spB0, -100, 64, 40, 3, 0,
|
||||
D_809AAB7C[(s32)(Rand_ZeroOne() * 111.1f) % 7], 0, 0, 80, -1, 1, gameplay_keep_DL_0528B0);
|
||||
D_809AAB7C[(s32)(Rand_ZeroOne() * 111.1f) % 7], 0, 0, 80, -1, 1, gKakeraLeafTip);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+28
-28
@@ -7251,37 +7251,37 @@
|
||||
0x809340BC:("func_809340BC",),
|
||||
0x80934178:("func_80934178",),
|
||||
0x80934464:("func_80934464",),
|
||||
0x809349E0:("func_809349E0",),
|
||||
0x80934AB4:("func_80934AB4",),
|
||||
0x80934F58:("func_80934F58",),
|
||||
0x80934FFC:("func_80934FFC",),
|
||||
0x809350C4:("func_809350C4",),
|
||||
0x809350F8:("func_809350F8",),
|
||||
0x8093517C:("func_8093517C",),
|
||||
0x809351A0:("func_809351A0",),
|
||||
0x809354F8:("func_809354F8",),
|
||||
0x809355A4:("func_809355A4",),
|
||||
0x8093561C:("func_8093561C",),
|
||||
0x809349E0:("EnKusa_ApplySway",),
|
||||
0x80934AB4:("EnKusa_Sway",),
|
||||
0x80934F58:("EnKusa_SnapToFloor",),
|
||||
0x80934FFC:("EnKusa_DropCollectible",),
|
||||
0x809350C4:("EnKusa_UpdateVelY",),
|
||||
0x809350F8:("EnKusa_RandScaleVecToZero",),
|
||||
0x8093517C:("EnKusa_SetScaleSmall",),
|
||||
0x809351A0:("EnKusa_SpawnFragments",),
|
||||
0x809354F8:("EnKusa_SpawnBugs",),
|
||||
0x809355A4:("EnKusa_GetWaterBox",),
|
||||
0x8093561C:("EnKusa_InitCollider",),
|
||||
0x80935674:("EnKusa_Init",),
|
||||
0x80935898:("EnKusa_Destroy",),
|
||||
0x809358C4:("func_809358C4",),
|
||||
0x809358D8:("func_809358D8",),
|
||||
0x80935988:("func_80935988",),
|
||||
0x809359AC:("func_809359AC",),
|
||||
0x80935B94:("func_80935B94",),
|
||||
0x80935BBC:("func_80935BBC",),
|
||||
0x80935CE8:("func_80935CE8",),
|
||||
0x80935D64:("func_80935D64",),
|
||||
0x80936120:("func_80936120",),
|
||||
0x80936168:("func_80936168",),
|
||||
0x809361A4:("func_809361A4",),
|
||||
0x809361B4:("func_809361B4",),
|
||||
0x80936220:("func_80936220",),
|
||||
0x80936290:("func_80936290",),
|
||||
0x809362D8:("func_809362D8",),
|
||||
0x809358C4:("EnKusa_SetupWaitObject",),
|
||||
0x809358D8:("EnKusa_WaitObject",),
|
||||
0x80935988:("EnKusa_SetupInteract",),
|
||||
0x809359AC:("EnKusa_WaitForInteract",),
|
||||
0x80935B94:("EnKusa_SetupLiftedUp",),
|
||||
0x80935BBC:("EnKusa_LiftedUp",),
|
||||
0x80935CE8:("EnKusa_SetupFall",),
|
||||
0x80935D64:("EnKusa_Fall",),
|
||||
0x80936120:("EnKusa_SetupCut",),
|
||||
0x80936168:("EnKusa_CutWaitRegrow",),
|
||||
0x809361A4:("EnKusa_DoNothing",),
|
||||
0x809361B4:("EnKusa_SetupUprootedWaitRegrow",),
|
||||
0x80936220:("EnKusa_UprootedWaitRegrow",),
|
||||
0x80936290:("EnKusa_SetupRegrow",),
|
||||
0x809362D8:("EnKusa_Regrow",),
|
||||
0x80936370:("EnKusa_Update",),
|
||||
0x80936414:("func_80936414",),
|
||||
0x809365CC:("func_809365CC",),
|
||||
0x80936414:("EnKusa_DrawBush",),
|
||||
0x809365CC:("EnKusa_DrawGrass",),
|
||||
0x80936CF0:("func_80936CF0",),
|
||||
0x80936D58:("func_80936D58",),
|
||||
0x80936F04:("func_80936F04",),
|
||||
|
||||
@@ -1495,10 +1495,6 @@ D_06003C80 = 0x06003C80;
|
||||
D_06003D58 = 0x06003D58;
|
||||
D_06006198 = 0x06006198;
|
||||
|
||||
// ovl_En_Kusa
|
||||
|
||||
D_06000140 = 0x06000140;
|
||||
D_060002E0 = 0x060002E0;
|
||||
|
||||
// ovl_En_Lift_Nuts
|
||||
|
||||
|
||||
Reference in New Issue
Block a user