diff --git a/asm/nonmatchings/code_13870_len_6980/create_partner_npc.s b/asm/nonmatchings/code_13870_len_6980/create_partner_npc.s deleted file mode 100644 index 5644418f6e..0000000000 --- a/asm/nonmatchings/code_13870_len_6980/create_partner_npc.s +++ /dev/null @@ -1,12 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel create_partner_npc -/* 13C80 80038880 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* 13C84 80038884 0000282D */ daddu $a1, $zero, $zero -/* 13C88 80038888 AFBF0010 */ sw $ra, 0x10($sp) -/* 13C8C 8003888C 0C00E166 */ jal _create_npc -/* 13C90 80038890 24060001 */ addiu $a2, $zero, 1 -/* 13C94 80038894 8FBF0010 */ lw $ra, 0x10($sp) -/* 13C98 80038898 03E00008 */ jr $ra -/* 13C9C 8003889C 27BD0018 */ addiu $sp, $sp, 0x18 diff --git a/include/map.h b/include/map.h index 44d64610d5..df27b20267 100644 --- a/include/map.h +++ b/include/map.h @@ -54,6 +54,13 @@ typedef struct Area { /* 0x0C */ char* name; ///< JP debug name. } Area; // size = 0x10 +typedef struct NpcBlueprint { + /* 0x00 */ s32 flags; + /* 0x04 */ NpcAnimID initialAnim; + /* 0x08 */ UNK_FUN_PTR(onUpdate); + /* 0x0C */ UNK_FUN_PTR(onRender); +} NpcBlueprint; // size = 0x10 + typedef struct NpcAISettings { /* 0x00 */ f32 moveSpeed; /* 0x04 */ s32 moveTime; diff --git a/src/code_13870_len_6980.c b/src/code_13870_len_6980.c index 858526275b..306f3d8d97 100644 --- a/src/code_13870_len_6980.c +++ b/src/code_13870_len_6980.c @@ -18,13 +18,15 @@ INCLUDE_ASM(s32, "code_13870_len_6980", init_npc_list); INCLUDE_ASM(s32, "code_13870_len_6980", func_8003857C); -INCLUDE_ASM(s32, "code_13870_len_6980", _create_npc); +INCLUDE_ASM(s32, "code_13870_len_6980", _create_npc, NpcBlueprint* blueprint, s32 animList[], s32 skipLoadingAnims); INCLUDE_ASM(s32, "code_13870_len_6980", create_basic_npc); INCLUDE_ASM(s32, "code_13870_len_6980", create_standard_npc); -INCLUDE_ASM(s32, "code_13870_len_6980", create_partner_npc); +void create_partner_npc(NpcBlueprint* blueprint) { + _create_npc(blueprint, NULL, TRUE); +} INCLUDE_ASM(s32, "code_13870_len_6980", free_npc_by_index);