mirror of https://github.com/zeldaret/tmc.git
Put const data into stamp
This commit is contained in:
parent
51ee1d7028
commit
57cb7af7c4
|
|
@ -35784,11 +35784,6 @@
|
|||
"size": 7,
|
||||
"type": "animation"
|
||||
},
|
||||
{
|
||||
"path": "stamp/gUnk_0810C2E4.bin",
|
||||
"start": 1098468,
|
||||
"size": 16
|
||||
},
|
||||
{
|
||||
"path": "animations/gSpriteAnimations_Marcy_0.bin",
|
||||
"start": 1098592,
|
||||
|
|
|
|||
|
|
@ -1,18 +0,0 @@
|
|||
.include "asm/macros.inc"
|
||||
.include "constants/constants.inc"
|
||||
|
||||
.section .rodata
|
||||
.align 2
|
||||
|
||||
gStampBehaviors1:: @ 0810C2CC
|
||||
.4byte sub_08062BD4
|
||||
.4byte sub_08062BF8
|
||||
.4byte sub_08062C24
|
||||
.4byte sub_08062C54
|
||||
|
||||
gStampBehaviors2:: @ 0810C2DC
|
||||
.4byte sub_08062C7C
|
||||
.4byte sub_08062CA4
|
||||
|
||||
gUnk_0810C2E4:: @ 0810C2E4
|
||||
.incbin "stamp/gUnk_0810C2E4.bin"
|
||||
|
|
@ -30,7 +30,7 @@ u32 sub_0806EE20(Entity* ent);
|
|||
s32 sub_0806F078(Entity* ent, s32 a2);
|
||||
void sub_0806F118(Entity* ent);
|
||||
void sub_0806F188(Entity* ent);
|
||||
void ShowNPCDialogue(Entity* ent, Dialog* dia);
|
||||
void ShowNPCDialogue(Entity* ent, const Dialog* dia);
|
||||
|
||||
Entity* CreateNPC(u32 subtype, u32 form, u32 parameter);
|
||||
u32 UpdateFuseInteraction(Entity*);
|
||||
|
|
|
|||
|
|
@ -1165,7 +1165,7 @@ SECTIONS {
|
|||
data/animations/npc/kid.o(.rodata);
|
||||
src/npc/npc9.o(.rodata);
|
||||
data/animations/npc/npc9.o(.rodata);
|
||||
data/const/npc/stamp.o(.rodata);
|
||||
src/npc/stamp.o(.rodata);
|
||||
data/animations/npc/stamp.o(.rodata);
|
||||
data/const/npc/marcy.o(.rodata);
|
||||
data/animations/npc/marcy.o(.rodata);
|
||||
|
|
|
|||
|
|
@ -5,18 +5,28 @@
|
|||
#include "effects.h"
|
||||
#include "npc.h"
|
||||
|
||||
extern void sub_08062CA4(Entity*);
|
||||
|
||||
extern void (*gStampBehaviors1[4])(Entity*);
|
||||
extern void (*gStampBehaviors2[2])(Entity*);
|
||||
|
||||
extern Dialog gUnk_0810C2E4[2];
|
||||
void sub_08062CA4(Entity*);
|
||||
void sub_08062BD4(Entity*);
|
||||
void sub_08062BF8(Entity*);
|
||||
void sub_08062C24(Entity*);
|
||||
void sub_08062C54(Entity*);
|
||||
void sub_08062C7C(Entity*);
|
||||
|
||||
void Stamp(Entity* ent) {
|
||||
static void (*const actionFuncs[4])(Entity*) = {
|
||||
sub_08062BD4,
|
||||
sub_08062BF8,
|
||||
sub_08062C24,
|
||||
sub_08062C54,
|
||||
};
|
||||
static void (*const scriptedActionFuncs[2])(Entity*) = {
|
||||
sub_08062C7C,
|
||||
sub_08062CA4,
|
||||
};
|
||||
if ((ent->flags & ENT_SCRIPTED) != 0) {
|
||||
gStampBehaviors2[ent->action](ent);
|
||||
scriptedActionFuncs[ent->action](ent);
|
||||
} else {
|
||||
gStampBehaviors1[ent->action](ent);
|
||||
actionFuncs[ent->action](ent);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -69,8 +79,17 @@ void sub_08062CA4(Entity* ent) {
|
|||
}
|
||||
|
||||
void sub_08062CBC(Entity* ent) {
|
||||
u32 uVar1 = CheckKinstoneFused(44);
|
||||
ShowNPCDialogue(ent, &gUnk_0810C2E4[(-uVar1 | uVar1) >> 31]);
|
||||
static const Dialog gUnk_0810C2E4[2] = {
|
||||
{ 0, 0, 0x3, 1, { 0x4001, 0x4000 } },
|
||||
{ 0, 0, 0x3, 1, { 0x4003, 0x4002 } },
|
||||
};
|
||||
u32 uVar1;
|
||||
if (CheckKinstoneFused(44)) {
|
||||
uVar1 = 1;
|
||||
} else {
|
||||
uVar1 = 0;
|
||||
}
|
||||
ShowNPCDialogue(ent, &gUnk_0810C2E4[uVar1]);
|
||||
}
|
||||
|
||||
void sub_08062CE0(Entity* ent) {
|
||||
|
|
|
|||
|
|
@ -336,7 +336,7 @@ void sub_0806F188(Entity* ent) {
|
|||
gSave.unk1C1[idx] = 0xF3;
|
||||
}
|
||||
|
||||
void ShowNPCDialogue(Entity* ent, Dialog* dia) {
|
||||
void ShowNPCDialogue(Entity* ent, const Dialog* dia) {
|
||||
u32 uVar1;
|
||||
s32 temp;
|
||||
u32 uVar2;
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@ extern void (*const GreatFairy_Form1Behaviors[])(Entity*);
|
|||
extern void (*const GreatFairy_Form2Behaviors[])(Entity*);
|
||||
extern void (*const gUnk_081207A4[])(Entity*);
|
||||
|
||||
extern u32 gUnk_0810C2E4;
|
||||
extern const s16 GreatFairy_RippleOffsets[10];
|
||||
extern u8 gUnk_0812079C[8];
|
||||
extern s8 gUnk_081207AC[];
|
||||
|
|
|
|||
Loading…
Reference in New Issue