mirror of https://github.com/zeldaret/tmc.git
Put const data in smoke
This commit is contained in:
parent
8b54665b49
commit
e6931831b6
|
|
@ -42304,11 +42304,6 @@
|
|||
"size": 40,
|
||||
"type": "animation"
|
||||
},
|
||||
{
|
||||
"path": "smoke/gUnk_08121068.bin",
|
||||
"start": 1183848,
|
||||
"size": 8
|
||||
},
|
||||
{
|
||||
"path": "animations/gSpriteAnimations_PushableRock_0.bin",
|
||||
"start": 1183888,
|
||||
|
|
|
|||
|
|
@ -1,16 +0,0 @@
|
|||
.include "asm/macros.inc"
|
||||
.include "constants/constants.inc"
|
||||
|
||||
.section .rodata
|
||||
.align 2
|
||||
|
||||
gUnk_08121060:: @ 08121060
|
||||
.4byte sub_0808A40C
|
||||
.4byte sub_0808A46C
|
||||
|
||||
gUnk_08121068:: @ 08121068
|
||||
.incbin "smoke/gUnk_08121068.bin"
|
||||
|
||||
gUnk_08121070:: @ 08121070
|
||||
.4byte sub_0808A484
|
||||
.4byte sub_0808A4D0
|
||||
|
|
@ -1384,7 +1384,7 @@ SECTIONS {
|
|||
data/animations/object/object2A.o(.rodata);
|
||||
src/object/beanstalk.o(.rodata);
|
||||
data/animations/object/beanstalk.o(.rodata);
|
||||
data/const/object/smoke.o(.rodata);
|
||||
src/object/smoke.o(.rodata);
|
||||
src/object/pushableRock.o(.rodata);
|
||||
data/animations/object/pushableRock.o(.rodata);
|
||||
src/object/hittableLever.o(.rodata);
|
||||
|
|
|
|||
|
|
@ -1,15 +1,22 @@
|
|||
#include "object.h"
|
||||
|
||||
extern void (*const gUnk_08121060[])(Entity*);
|
||||
extern void (*const gUnk_08121070[])(Entity*);
|
||||
|
||||
extern s8 gUnk_08121068[];
|
||||
void sub_0808A40C(Entity*);
|
||||
void sub_0808A46C(Entity*);
|
||||
void sub_0808A484(Entity*);
|
||||
void sub_0808A4D0(Entity*);
|
||||
|
||||
void Smoke(Entity* this) {
|
||||
gUnk_08121060[this->type](this);
|
||||
static void (*const typeFuncs[])(Entity*) = {
|
||||
sub_0808A40C,
|
||||
sub_0808A46C,
|
||||
};
|
||||
typeFuncs[this->type](this);
|
||||
}
|
||||
|
||||
void sub_0808A40C(Entity* this) {
|
||||
static const s8 gUnk_08121068[] = {
|
||||
-1, 1, -2, 2, 0, 0, 0, 0,
|
||||
};
|
||||
Entity* ent;
|
||||
|
||||
if (this->action == 0) {
|
||||
|
|
@ -27,7 +34,11 @@ void sub_0808A40C(Entity* this) {
|
|||
}
|
||||
|
||||
void sub_0808A46C(Entity* this) {
|
||||
gUnk_08121070[this->action](this);
|
||||
static void (*const actionFuncs[])(Entity*) = {
|
||||
sub_0808A484,
|
||||
sub_0808A4D0,
|
||||
};
|
||||
actionFuncs[this->action](this);
|
||||
}
|
||||
|
||||
void sub_0808A484(Entity* this) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue