Decompile Object69

This commit is contained in:
octorock 2022-02-27 21:35:21 +01:00
parent 754b3eb760
commit 05111993bc
3 changed files with 24 additions and 41 deletions

View File

@ -1,40 +0,0 @@
.include "asm/macros.inc"
.include "constants/constants.inc"
.syntax unified
.text
thumb_func_start Object69
Object69: @ 0x08094A0C
push {lr}
adds r2, r0, #0
ldrb r1, [r2, #0x10]
movs r0, #2
ands r0, r1
cmp r0, #0
beq _08094A3E
ldrb r0, [r2, #0xc]
cmp r0, #0
bne _08094A34
movs r0, #1
strb r0, [r2, #0xc]
ldr r0, _08094A30 @ =gHitbox_2
str r0, [r2, #0x48]
adds r0, r2, #0
bl sub_0807DD50
b _08094A42
.align 2, 0
_08094A30: .4byte gHitbox_2
_08094A34:
adds r0, r2, #0
movs r1, #0
bl sub_0807DD94
b _08094A42
_08094A3E:
movs r0, #1
strb r0, [r2, #0xc]
_08094A42:
pop {pc}

View File

@ -751,7 +751,7 @@ SECTIONS {
asm/object/object66.o(.text);
asm/object/object67.o(.text);
asm/object/object68.o(.text);
asm/object/object69.o(.text);
src/object/object69.o(.text);
src/object/object6A.o(.text);
src/object/crenelBeanSprout.o(.text);
src/object/minecartDoor.o(.text);

23
src/object/object69.c Normal file
View File

@ -0,0 +1,23 @@
/**
* @file object69.c
* @ingroup Objects
*
* @brief Object69 object
*/
#include "entity.h"
#include "hitbox.h"
#include "functions.h"
void Object69(Entity* this) {
if ((this->flags & ENT_SCRIPTED) != 0) {
if (this->action == 0) {
this->action = 1;
this->hitbox = (Hitbox*)&gHitbox_2;
sub_0807DD50(this);
} else {
sub_0807DD94(this, NULL);
}
} else {
this->action = 1;
}
}