finish player.c

This commit is contained in:
theo3
2021-12-27 17:14:52 -08:00
parent 079260dbd6
commit 24750a6bb5
89 changed files with 2566 additions and 4879 deletions
+10 -10
View File
@@ -138,7 +138,7 @@ u32 sub_08081D28(Entity* this) {
}
extern u32 sub_080002E0(u32, u32);
extern Entity* gUnk_03004040[3];
extern Entity* gPlayerClones[3];
u32 sub_08081E0C(Entity*);
Entity* sub_08081D74(Entity* this) {
@@ -152,13 +152,13 @@ Entity* sub_08081D74(Entity* this) {
ent = &gPlayerEntity;
}
} else {
if (gPlayerState.flags & 0x400000) {
if (EntityInRectRadius(this, gUnk_03004040[0], 5, 6)) {
ent = gUnk_03004040[0];
} else if (EntityInRectRadius(this, gUnk_03004040[1], 5, 6)) {
ent = gUnk_03004040[1];
} else if (EntityInRectRadius(this, gUnk_03004040[2], 5, 6)) {
ent = gUnk_03004040[2];
if (gPlayerState.flags & PL_CLONING) {
if (EntityInRectRadius(this, gPlayerClones[0], 5, 6)) {
ent = gPlayerClones[0];
} else if (EntityInRectRadius(this, gPlayerClones[1], 5, 6)) {
ent = gPlayerClones[1];
} else if (EntityInRectRadius(this, gPlayerClones[2], 5, 6)) {
ent = gPlayerClones[2];
}
}
}
@@ -272,8 +272,8 @@ void sub_08081FF8(Entity* this) {
direction = GetFacingDirection(this->child, this);
sub_080044AE(this->child, 0x200, direction);
for (i = 0; i < 3; i++) {
if (gUnk_03004040[i]) {
sub_080044AE(gUnk_03004040[i], 0x200, direction);
if (gPlayerClones[i]) {
sub_080044AE(gPlayerClones[i], 0x200, direction);
}
}
}