mirror of
https://github.com/zeldaret/mm.git
synced 2026-08-11 03:25:45 -04:00
z_en_item00 (#78)
* z_en_item00 WIP 17/21 match, rest close to matching * Split .rodata for z_en_item00 * Item00 documentation, some misc cleanup * Minor cleanup * Fixup for z_collision_check * Address feedback * Delete old file * Fix bad merge
This commit is contained in:
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
+2
-2
@@ -414,7 +414,7 @@ void Lights_DrawGlow(GlobalContext* globalCtx) {
|
||||
gDPSetCombineLERP(dl++, 0, 0, 0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0,
|
||||
0, 0, 0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0);
|
||||
|
||||
gSPDisplayList(dl++, &D_04029CB0);
|
||||
gSPDisplayList(dl++, D_04029CB0);
|
||||
|
||||
do {
|
||||
if (light->info->type == LIGHT_POINT_GLOW) {
|
||||
@@ -429,7 +429,7 @@ void Lights_DrawGlow(GlobalContext* globalCtx) {
|
||||
|
||||
gSPMatrix(dl++, Matrix_NewMtx(globalCtx->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
gSPDisplayList(dl++, &D_04029CF0);
|
||||
gSPDisplayList(dl++, D_04029CF0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -52,7 +52,6 @@ Vec3f D_808C1C40 = { 0.0f, 500.0f, 0.0f };
|
||||
Vec3f D_808C1C4C = { 0.0f, -500.0f, 0.0f };
|
||||
|
||||
extern Gfx D_0601D960[];
|
||||
extern Gfx D_040008D0[];
|
||||
|
||||
void ArmsHook_SetupAction(ArmsHook* this, ArmsHookActionFunc actionFunc) {
|
||||
this->actionFunc = actionFunc;
|
||||
|
||||
@@ -30,7 +30,7 @@ void func_80BFCFA0(EnScopecoin* this, GlobalContext* globalCtx) {
|
||||
|
||||
void func_80BFCFB8(EnScopecoin* this, GlobalContext* globalCtx) {
|
||||
if (Actor_GetCollectibleFlag(globalCtx, (this->actor.params & 0x7F0) >> 4)) {
|
||||
func_800A7730(globalCtx, &this->actor.world, 2);
|
||||
Item_DropCollectible(globalCtx, &this->actor.world, 2);
|
||||
Actor_MarkForDeath(&this->actor);
|
||||
}
|
||||
}
|
||||
@@ -77,14 +77,14 @@ void EnScopecoin_Update(Actor* thisx, GlobalContext* globalCtx) {
|
||||
this->actionFunc(this, globalCtx);
|
||||
}
|
||||
|
||||
static UNK_PTR D_80BFD280[] = {D_04061FC0, D_04061FE0, D_04062000, D_04062040, D_04062020, D_04062060, D_04062000};
|
||||
static UNK_PTR D_80BFD280[] = {&D_04061FC0, &D_04061FE0, &D_04062000, &D_04062040, &D_04062020, &D_04062060, &D_04062000};
|
||||
|
||||
void EnScopecoin_Draw(Actor *thisx, GlobalContext *globalCtx) {
|
||||
EnScopecoin* this = THIS;
|
||||
GraphicsContext* gfxCtx = globalCtx->state.gfxCtx;
|
||||
|
||||
|
||||
func_8012C28C(globalCtx->state.gfxCtx);
|
||||
func_800B8050(&this->actor, globalCtx, 0);
|
||||
func_800B8050(&this->actor, globalCtx, 0);
|
||||
OPEN_DISPS(gfxCtx);
|
||||
|
||||
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
@@ -67,10 +67,9 @@ void func_8093089C(EnTuboTrap *this, GlobalContext *globalCtx) {
|
||||
s32 dropCount = func_800A8150(itemParam);
|
||||
|
||||
if (dropCount >= 0) {
|
||||
// in OOT this is Item_DropCollectible
|
||||
func_800A7730(globalCtx,
|
||||
&this->actor.world,
|
||||
((this->actor.params & 0x7F) << 8) | dropCount);
|
||||
Item_DropCollectible(globalCtx,
|
||||
&this->actor.world,
|
||||
((this->actor.params & 0x7F) << 8) | dropCount);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -120,10 +119,10 @@ void func_809308F4(EnTuboTrap *this, GlobalContext *globalCtx) {
|
||||
arg5,
|
||||
0x14,
|
||||
0,
|
||||
0,
|
||||
((Rand_ZeroOne() * 85.0f) + 15.0f),
|
||||
0,
|
||||
0,
|
||||
((Rand_ZeroOne() * 85.0f) + 15.0f),
|
||||
0,
|
||||
0,
|
||||
0x3C,
|
||||
-1,
|
||||
GAMEPLAY_DANGEON_KEEP,
|
||||
@@ -150,7 +149,7 @@ void func_80930B60(EnTuboTrap *this, GlobalContext *globalCtx) {
|
||||
|
||||
pos = *actorPos;
|
||||
pos.y += this->actor.yDistToWater;
|
||||
|
||||
|
||||
EffectSsGSplash_Spawn(globalCtx, &pos, NULL, NULL, 0, 0x190);
|
||||
|
||||
for (i = 0, var = 0; i < 15; i++, var += 20000) {
|
||||
@@ -176,15 +175,15 @@ void func_80930B60(EnTuboTrap *this, GlobalContext *globalCtx) {
|
||||
}
|
||||
|
||||
EffectSsKakera_Spawn(globalCtx,
|
||||
&pos,
|
||||
&vel,
|
||||
&pos,
|
||||
&vel,
|
||||
actorPos,
|
||||
-0xAA,
|
||||
-0xAA,
|
||||
arg5,
|
||||
0x32, 5, 0,
|
||||
0x32, 5, 0,
|
||||
((Rand_ZeroOne() * 85.0f) + 15.0f),
|
||||
0, 0, 0x46,
|
||||
-1,
|
||||
0, 0, 0x46,
|
||||
-1,
|
||||
GAMEPLAY_DANGEON_KEEP,
|
||||
&D_05018090);
|
||||
|
||||
@@ -195,7 +194,7 @@ void func_80930B60(EnTuboTrap *this, GlobalContext *globalCtx) {
|
||||
void func_80930DDC(EnTuboTrap *this, GlobalContext *globalCtx) {
|
||||
Actor *player = PLAYER;
|
||||
Actor *player2 = PLAYER;
|
||||
|
||||
|
||||
// in oot func_800F0568 is Audio_PlaySoundAtPosition
|
||||
|
||||
if (((this->actor.bgCheckFlags & 0x20) != 0) && (this->actor.yDistToWater > 15.0f)) {
|
||||
@@ -240,13 +239,13 @@ void func_80930DDC(EnTuboTrap *this, GlobalContext *globalCtx) {
|
||||
func_8093089C(this, globalCtx);
|
||||
Actor_MarkForDeath(&this->actor);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#if NON-MATCHING
|
||||
// Wait For Proximity (idle)
|
||||
// NON-MATCHING: wrong register used, v instead of t for the weirdValues[] pointer
|
||||
void func_80931004(EnTuboTrap *this, GlobalContext *globalCtx) {
|
||||
Actor *player = PLAYER;
|
||||
Actor *player = PLAYER;
|
||||
f32 currentHeight;
|
||||
s8 weirdvalue;
|
||||
s16 startingRotation;
|
||||
@@ -261,7 +260,7 @@ void func_80931004(EnTuboTrap *this, GlobalContext *globalCtx) {
|
||||
func_800BC154(globalCtx, &globalCtx->actorCtx, this, ACTORCAT_ENEMY);
|
||||
currentHeight = this->actor.world.pos.y;
|
||||
this->actor.flags |= 0x11; // always update and can target
|
||||
|
||||
|
||||
// hard to know what this value is even used for without knowing what ActorPlayer::unk14B is
|
||||
// wild guess: this is player animation state, height is modified to always point at center of link model
|
||||
weirdvalue = D_8093146C[ ((ActorPlayer*) player)->unk14B & 0xFF];
|
||||
|
||||
Reference in New Issue
Block a user