Decompile object75

This commit is contained in:
Tal Hayon 2022-03-14 11:58:03 +02:00
parent 5bb51e0047
commit 5035a3cc39
4 changed files with 16 additions and 31 deletions

View File

@ -1,20 +0,0 @@
.include "asm/macros.inc"
.include "constants/constants.inc"
.syntax unified
.text
thumb_func_start Object75
Object75: @ 0x0808C934
push {lr}
ldr r2, _0808C948 @ =gUnk_08121670
ldrb r1, [r0, #0xc]
lsls r1, r1, #2
adds r1, r1, r2
ldr r1, [r1]
bl _call_via_r1
pop {pc}
.align 2, 0
_0808C948: .4byte gUnk_08121670

View File

@ -1,9 +0,0 @@
.include "asm/macros.inc"
.include "constants/constants.inc"
.section .rodata
.align 2
gUnk_08121670:: @ 08121670
.4byte sub_0808C964
.4byte sub_0808CA10

View File

@ -680,7 +680,7 @@ SECTIONS {
src/object/bossDoor.o(.text);
src/object/object3A.o(.text);
src/object/macroMushroomStalks.o(.text);
asm/object/object75.o(.text); /* 75 and 76 are mislocated in object table */
src/object/object75.o(.text); /* 75 and 76 are mislocated in object table */
asm/object/object76.o(.text);
asm/object/code_0808C964.o(.text);
src/object/macroPlayer.o(.text);
@ -1413,7 +1413,7 @@ SECTIONS {
data/animations/object/bossDoor.o(.rodata);
src/object/object3A.o(.rodata);
src/object/macroMushroomStalks.o(.rodata);
data/const/object/object75.o(.rodata);
src/object/object75.o(.rodata);
data/const/object/object76.o(.rodata);
src/object/macroPlayer.o(.rodata);
src/object/object3D.o(.rodata);

14
src/object/object75.c Normal file
View File

@ -0,0 +1,14 @@
#define NENT_DEPRECATED
#include "entity.h"
extern void sub_0808C964(Entity*);
extern void sub_0808CA10(Entity*);
void Object75(Entity* this) {
static void (*const actionFuncs[])(Entity*) = {
sub_0808C964,
sub_0808CA10,
};
actionFuncs[this->action](this);
}