mirror of
https://github.com/zeldaret/tmc
synced 2026-08-21 06:29:00 -04:00
Unify nonmatching namings
This commit is contained in:
@@ -444,8 +444,7 @@ void sub_0802AF9C(Entity* this) {
|
||||
}
|
||||
}
|
||||
|
||||
#if NON_MATCHING
|
||||
void sub_0802AFC8(Entity* this) {
|
||||
NONMATCH("asm/non_matching/bombPeahat/sub_0802AFC8.inc", void sub_0802AFC8(Entity* this)) {
|
||||
u32 flag = 8;
|
||||
if (this->field_0xf < 0x29) {
|
||||
u32 tmp;
|
||||
@@ -470,12 +469,7 @@ void sub_0802AFC8(Entity* this) {
|
||||
this->palette.b.b0 = this->palette.b.b4;
|
||||
}
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
void sub_0802AFC8(Entity* this) {
|
||||
asm(".include \"asm/non_matching/bombPeahat/sub_0802AFC8.inc\"");
|
||||
}
|
||||
#endif
|
||||
END_NONMATCH
|
||||
|
||||
void sub_0802B048(Entity* this) {
|
||||
Entity* ent;
|
||||
|
||||
@@ -523,8 +523,7 @@ bool32 sub_080291DC(Entity* this) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
#if NON_MATCHING
|
||||
void sub_0802922C(Entity* this) {
|
||||
NONMATCH("asm/non_matching/businessScrub/sub_0802925C.inc", void sub_0802922C(Entity* this)) {
|
||||
const struct SalesOffering* offer = (const struct SalesOffering*)this->field_0x7c.WORD;
|
||||
|
||||
this->action = 6;
|
||||
@@ -538,12 +537,7 @@ void sub_0802922C(Entity* this) {
|
||||
|
||||
sub_080290E0(this, 3);
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
void sub_0802922C(Entity* this) {
|
||||
asm(".include \"asm/non_matching/businessScrub/sub_0802925C.inc\"");
|
||||
}
|
||||
#endif
|
||||
END_NONMATCH
|
||||
|
||||
void sub_0802925C(Entity* this) {
|
||||
sub_08078784(this, sub_0801E99C(this));
|
||||
|
||||
+1
-4
@@ -391,10 +391,7 @@ void sub_0802124C(Entity* this) {
|
||||
}
|
||||
}
|
||||
|
||||
NAKED
|
||||
u32 sub_08021274(u32 a, u32 b) {
|
||||
asm(".include \"asm/non_matching/darkNut/sub_08021274.inc\"");
|
||||
}
|
||||
ASM_FUNC("asm/non_matching/darkNut/sub_08021274.inc", u32 sub_08021274(u32 a, u32 b))
|
||||
|
||||
void sub_080212B0(Entity* this) {
|
||||
u8 tmp;
|
||||
|
||||
@@ -11,6 +11,8 @@ extern const u16 gUnk_080CD568[];
|
||||
extern const u8 gUnk_080CD580[];
|
||||
extern const s16 gUnk_080CD58C[];
|
||||
|
||||
extern void sub_080AEFB4(Entity*);
|
||||
|
||||
void FallingBoulder(Entity* this) {
|
||||
EnemyFunctionHandler(this, gUnk_080CD540);
|
||||
}
|
||||
@@ -58,8 +60,7 @@ void sub_0802C318(Entity* this) {
|
||||
}
|
||||
}
|
||||
|
||||
#if NON_MATCHING
|
||||
void sub_0802C334(Entity* this) {
|
||||
NONMATCH("asm/non_matching/fallingBoulder/sub_0802C334.inc", void sub_0802C334(Entity* this)) {
|
||||
if ((u16)this->field_0x7c.HALF.LO == 0) {
|
||||
u32 tmp = gRoomControls.roomOriginY;
|
||||
if (&gPlayerEntity == NULL)
|
||||
@@ -99,7 +100,7 @@ void sub_0802C334(Entity* this) {
|
||||
diff += 0x18;
|
||||
}
|
||||
sub_0802C62C(this);
|
||||
this->field_0x7a.HWORD = Random() & 0xff | 0x100;
|
||||
this->field_0x7a.HWORD = (Random() & 0xff) | 0x100;
|
||||
return;
|
||||
}
|
||||
break;
|
||||
@@ -124,12 +125,7 @@ void sub_0802C334(Entity* this) {
|
||||
this->spritePriority.b0 = 1;
|
||||
UpdateSpriteForCollisionLayer(this);
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
void sub_0802C334(Entity* this) {
|
||||
asm(".include \"asm/non_matching/fallingBoulder/sub_0802C334.inc\"");
|
||||
}
|
||||
#endif
|
||||
END_NONMATCH
|
||||
|
||||
void nullsub_148(Entity* this) {
|
||||
/* ... */
|
||||
|
||||
@@ -204,8 +204,7 @@ void sub_0802805C(Entity* this) {
|
||||
}
|
||||
}
|
||||
|
||||
#if NON_MATCHING
|
||||
void sub_0802810C(Entity* this) {
|
||||
NONMATCH("asm/non_matching/likeLike/sub_0802810C.inc", void sub_0802810C(Entity* this)) {
|
||||
gPlayerState.jumpStatus = 0x41;
|
||||
gPlayerState.field_0xa = 0;
|
||||
gPlayerState.flags.all &= 0xffffffef;
|
||||
@@ -224,12 +223,7 @@ void sub_0802810C(Entity* this) {
|
||||
this->iframes = -18;
|
||||
}
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
void sub_0802810C(Entity* this) {
|
||||
asm(".include \"asm/non_matching/likeLike/sub_0802810C.inc\"");
|
||||
}
|
||||
#endif
|
||||
END_NONMATCH
|
||||
|
||||
void sub_080281A0(Entity* this) {
|
||||
this->field_0xf = 0x19;
|
||||
|
||||
@@ -318,10 +318,7 @@ void sub_08029DE4(Entity* this) {
|
||||
}
|
||||
}
|
||||
|
||||
NAKED
|
||||
void sub_08029E0C(Entity* this) {
|
||||
asm(".include \"asm/non_matching/madderpillar/sub_08029E0C.inc\"");
|
||||
}
|
||||
ASM_FUNC("asm/non_matching/madderpillar/sub_08029E0C.inc", void sub_08029E0C(Entity* this))
|
||||
|
||||
void sub_08029EEC(Entity* this) {
|
||||
u32 uVar1 = (this->direction >> 3) + this->field_0x74.HALF.HI;
|
||||
|
||||
+2
-8
@@ -141,15 +141,9 @@ void sub_08022DE8(Entity* this) {
|
||||
}
|
||||
}
|
||||
|
||||
NAKED
|
||||
void sub_08022E40(Entity* this) {
|
||||
asm(".include \"asm/non_matching/moldorm/sub_08022E40.inc\"");
|
||||
}
|
||||
ASM_FUNC("asm/non_matching/moldorm/sub_08022E40.inc", void sub_08022E40(Entity* this))
|
||||
|
||||
NAKED
|
||||
void sub_08022EAC(Entity* this) {
|
||||
asm(".include \"asm/non_matching/moldorm/sub_08022EAC.inc\"");
|
||||
}
|
||||
ASM_FUNC("asm/non_matching/moldorm/sub_08022EAC.inc", void sub_08022EAC(Entity* this))
|
||||
|
||||
void sub_08022F14(Entity* this) {
|
||||
if (sub_08049FA0(this) == 0) {
|
||||
|
||||
+4
-16
@@ -27,8 +27,7 @@ extern void (*const gUnk_080CBC98[])(Entity*);
|
||||
extern void (*const gUnk_080CBCA8[])(Entity*);
|
||||
extern const s8 gUnk_080CBCB8[];
|
||||
|
||||
#if NON_MATCHING
|
||||
void Moldworm(Entity* this) {
|
||||
NONMATCH("asm/non_matching/moldworm/Moldworm.inc", void Moldworm(Entity* this)) {
|
||||
u16 prevX = this->x.HALF.HI;
|
||||
u16 prevY = this->y.HALF.HI;
|
||||
|
||||
@@ -56,12 +55,7 @@ void Moldworm(Entity* this) {
|
||||
(((this->x.HALF.HI - prevX + 8) & 0xf) << 4) | ((this->y.HALF.HI - prevY + 8U) & 0xf);
|
||||
}
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
void Moldworm(Entity* this) {
|
||||
asm(".include \"asm/non_matching/moldworm/moldworm.inc\"");
|
||||
}
|
||||
#endif
|
||||
END_NONMATCH
|
||||
|
||||
void sub_080230CC(Entity* this) {
|
||||
gUnk_080CBC50[this->action](this);
|
||||
@@ -472,10 +466,7 @@ void sub_08023990(Entity* this, u32 param_2, u32 param_3) {
|
||||
}
|
||||
|
||||
/* TODO: fix struct */
|
||||
NAKED
|
||||
void sub_080239F0(Entity* this) {
|
||||
asm(".include \"asm/non_matching/moldworm/sub_080239F0.inc\"");
|
||||
}
|
||||
ASM_FUNC("asm/non_matching/moldworm/sub_080239F0.inc", void sub_080239F0(Entity* this))
|
||||
|
||||
bool32 sub_08023A38(u32 unk) {
|
||||
if (unk == 0x1a || unk == 0x29) {
|
||||
@@ -522,10 +513,7 @@ void sub_08023AB0(Entity* this) {
|
||||
}
|
||||
}
|
||||
|
||||
NAKED
|
||||
bool32 sub_08023B38(Entity* this) {
|
||||
asm(".include \"asm/non_matching/moldworm/sub_08023B38.inc\"");
|
||||
}
|
||||
ASM_FUNC("asm/non_matching/moldworm/sub_08023B38.inc", bool32 sub_08023B38(Entity* this))
|
||||
|
||||
// clang-format off
|
||||
void (*const gUnk_080CBC38[])(Entity*) = {
|
||||
|
||||
+7
-21
@@ -4,6 +4,7 @@
|
||||
#include "createObject.h"
|
||||
#include "game.h"
|
||||
#include "functions.h"
|
||||
#include "save.h"
|
||||
|
||||
extern u32 sub_080002E0(u16, u32);
|
||||
extern void sub_0800449C(Entity*, u32);
|
||||
@@ -559,20 +560,14 @@ void sub_080249DC(Entity* this) {
|
||||
InitializeAnimation(this, this->animationState);
|
||||
}
|
||||
|
||||
#if NON_MATCHING
|
||||
void sub_080249F4(Entity* this) {
|
||||
NONMATCH("asm/non_matching/pesto/sub_080249F4.inc", void sub_080249F4(Entity* this)) {
|
||||
u8 direction = ((this->direction + 2) & 0x1c) >> 2;
|
||||
if (direction != this->animationState) {
|
||||
this->animationState = direction;
|
||||
InitializeAnimation(this, this->animationState);
|
||||
}
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
void sub_080249F4(Entity* this) {
|
||||
asm(".include \"asm/non_matching/pesto/sub_080249F4.inc\"");
|
||||
}
|
||||
#endif
|
||||
END_NONMATCH
|
||||
|
||||
void sub_08024A14(Entity* this, u32 param_2, u32 param_3) {
|
||||
u8 unk = FALSE;
|
||||
@@ -703,10 +698,7 @@ bool32 sub_08024B38(Entity* this) {
|
||||
return iVar4;
|
||||
}
|
||||
|
||||
NAKED
|
||||
bool32 sub_08024C48(Entity* this, bool32 unk) {
|
||||
asm(".include \"asm/non_matching/pesto/sub_08024C48.inc\"");
|
||||
}
|
||||
ASM_FUNC("asm/non_matching/pesto/sub_08024C48.inc", bool32 sub_08024C48(Entity* this, bool32 unk))
|
||||
|
||||
void sub_08024C7C(Entity* this) {
|
||||
this->action = 1;
|
||||
@@ -794,8 +786,7 @@ u32 sub_08024E34(void) {
|
||||
return gUnk_080CBF20[idx];
|
||||
}
|
||||
|
||||
#if NON_MATCHING
|
||||
void sub_08024E4C(Entity* this) {
|
||||
NONMATCH("asm/non_matching/pesto/sub_08024E4C.inc", void sub_08024E4C(Entity* this)) {
|
||||
if (this->field_0x82.HALF.HI == 3) {
|
||||
this->field_0xf++;
|
||||
this->field_0xf &= 0xff;
|
||||
@@ -829,7 +820,7 @@ void sub_08024E4C(Entity* this) {
|
||||
player->animationState = 4;
|
||||
player->spritePriority.b1 = 0;
|
||||
if (this->field_0xf == 0) {
|
||||
(this->field_0x86.HALF.HI++;
|
||||
this->field_0x86.HALF.HI++;
|
||||
player->iframes = 8;
|
||||
ModHealth(-2);
|
||||
sub_0800449C(player, 0x7a);
|
||||
@@ -837,12 +828,7 @@ void sub_08024E4C(Entity* this) {
|
||||
}
|
||||
}
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
void sub_08024E4C(Entity* this) {
|
||||
asm(".include \"asm/non_matching/pesto/sub_08024E4C.inc\"");
|
||||
}
|
||||
#endif
|
||||
END_NONMATCH
|
||||
|
||||
void sub_08024F50(Entity* this) {
|
||||
gPlayerState.field_0xa = 0;
|
||||
|
||||
@@ -468,8 +468,7 @@ bool32 sub_080258C4(Entity* this) {
|
||||
}
|
||||
}
|
||||
|
||||
#if NON_MATCHING
|
||||
bool32 sub_0802594C(Entity* this, u32 param_2) {
|
||||
NONMATCH("asm/non_matching/puffstool/sub_0802594C.inc", bool32 sub_0802594C(Entity* this, u32 param_2)) {
|
||||
const s8* unk = gUnk_080CC090[param_2];
|
||||
u32 uVar1 = this->collisionLayer;
|
||||
RoomControls* ctrl = &gRoomControls;
|
||||
@@ -492,12 +491,7 @@ bool32 sub_0802594C(Entity* this, u32 param_2) {
|
||||
|
||||
return 0;
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
bool32 sub_0802594C(Entity* this, u32 param_2) {
|
||||
asm(".include \"asm/non_matching/puffstool/sub_0802594C.inc\"");
|
||||
}
|
||||
#endif
|
||||
END_NONMATCH
|
||||
|
||||
void sub_08025A54(Entity* this) {
|
||||
u32 layer = this->collisionLayer;
|
||||
|
||||
+4
-10
@@ -240,14 +240,13 @@ void sub_08028528(Entity* this) {
|
||||
}
|
||||
}
|
||||
|
||||
#if NON_MATCHING
|
||||
void sub_08028604(Entity* this) {
|
||||
NONMATCH("asm/non_matching/spearMoblin/sub_08028604.inc", void sub_08028604(Entity* this)) {
|
||||
this->field_0xf = 0;
|
||||
if (this->field_0x82.HALF.LO == 1) {
|
||||
this->actionDelay = gUnk_080CC7BC[Random() & 3];
|
||||
this->speed = 0x80;
|
||||
if (sub_08049FA0(this) != 0) {
|
||||
this->direction = gUnk_080CC7D0[Random() & 7] + 0x18 + this->direction & 0x18;
|
||||
this->direction = gUnk_080CC7D0[Random() & 7] + 0x18 + (this->direction & 0x18);
|
||||
} else {
|
||||
u32 iVar3 = sub_08049EE4(this);
|
||||
u32 uVar1;
|
||||
@@ -258,7 +257,7 @@ void sub_08028604(Entity* this) {
|
||||
this->actionDelay = this->actionDelay + 0x10;
|
||||
this->field_0x82.HALF.HI--;
|
||||
}
|
||||
this->direction = iVar3 + uVar1 + 4U & 0x18;
|
||||
this->direction = iVar3 + uVar1 + (4U & 0x18);
|
||||
}
|
||||
} else {
|
||||
this->actionDelay = 0xc;
|
||||
@@ -270,12 +269,7 @@ void sub_08028604(Entity* this) {
|
||||
sub_080287E0(this);
|
||||
}
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
void sub_08028604(Entity* this) {
|
||||
asm(".include \"asm/non_matching/spearMoblin/sub_08028604.inc\"");
|
||||
}
|
||||
#endif
|
||||
END_NONMATCH
|
||||
|
||||
bool32 sub_080286CC(Entity* this) {
|
||||
if (this->field_0x80.HALF.HI == 0) {
|
||||
|
||||
@@ -160,10 +160,7 @@ void sub_0802CF64(Entity* this) {
|
||||
sub_0802CF8C(this);
|
||||
}
|
||||
|
||||
NAKED
|
||||
void sub_0802CF8C(Entity* this) {
|
||||
asm(".include \"asm/non_matching/wallMaster2/sub_0802CF8C.inc\"");
|
||||
}
|
||||
ASM_FUNC("asm/non_matching/wallMaster2/sub_0802CF8C.inc", void sub_0802CF8C(Entity* this))
|
||||
|
||||
void sub_0802CFD8(Entity* this) {
|
||||
u32 unk = gUnk_080CD740[(this->field_0x7a.HALF.LO++ >> 3) & 7];
|
||||
|
||||
Reference in New Issue
Block a user