mirror of
https://github.com/zeldaret/tmc
synced 2026-08-19 13:54:04 -04:00
decomp vaati reborn npc
This commit is contained in:
@@ -241,10 +241,7 @@ bool32 sub_0803E4A0(Entity* this) {
|
||||
if (this->parent->currentHealth == 0) {
|
||||
return TRUE;
|
||||
} else {
|
||||
ret = FALSE;
|
||||
if (this->parent->next == NULL) {
|
||||
ret = TRUE;
|
||||
}
|
||||
ret = this->parent->next == NULL;
|
||||
}
|
||||
} else {
|
||||
return TRUE;
|
||||
|
||||
@@ -4,134 +4,134 @@
|
||||
|
||||
//clang-format off
|
||||
void (*const gNPCFunctions[][3])(Entity* ent) = {
|
||||
/*0x00*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x01*/ { Gentari, NULL, Gentari_Fusion },
|
||||
/*0x02*/ { Festari, NULL, Festari_Fusion },
|
||||
/*0x03*/ { ForestMinish, ForestMinish_Head, ForestMinish_Fusion },
|
||||
/*0x04*/ { Postman, NULL, Postman_Fusion },
|
||||
/*0x05*/ { NPC5, NULL, NULL },
|
||||
/*0x06*/ { Townsperson, Townsperson_Head, Townsperson_Fusion },
|
||||
/*0x07*/ { Kid, Kid_Head, Kid_Fusion },
|
||||
/*0x08*/ { Guard, Guard_Head, NULL },
|
||||
/*0x09*/ { NPC9, NULL, NULL },
|
||||
/*0x0a*/ { Stamp, NULL, NULL },
|
||||
/*0x0b*/ { Maid, Maid_Head, NULL },
|
||||
/*0x0c*/ { Marcy, NULL, NULL },
|
||||
/*0x0d*/ { Wheaton, NULL, NULL },
|
||||
/*0x0e*/ { Pita, NULL, NULL },
|
||||
/*0x0f*/ { MinishEzlo, MinishEzlo_Head, NULL },
|
||||
/*0x10*/ { Mailbox, NULL, NULL },
|
||||
/*0x11*/ { Beedle, Beedle_Head, NULL },
|
||||
/*0x12*/ { Brocco, NULL, Brocco_Fusion },
|
||||
/*0x13*/ { SittingPerson, SittingPerson_Head, SittingPerson_Fusion },
|
||||
/*0x14*/ { Pina, NULL, Pina_Fusion },
|
||||
/*0x15*/ { Guard, Guard_Head, NULL },
|
||||
/*0x16*/ { Maid, Maid_Head, NULL },
|
||||
/*0x17*/ { Din, NULL, Din_Fusion },
|
||||
/*0x18*/ { Nayru, NULL, Nayru_Fusion },
|
||||
/*0x19*/ { Farore, NULL, Farore_Fusion },
|
||||
/*0x1a*/ { Sturgeon, Sturgeon_Head, Sturgeon_Fusion },
|
||||
/*0x1b*/ { TingleSiblings, NULL, TingleSiblings_Fusion },
|
||||
/*0x1c*/ { Stockwell, NULL, NULL },
|
||||
/*0x1d*/ { Talon, Talon_Head, Talon_Fusion },
|
||||
/*0x1e*/ { Malon, NULL, Malon_Fusion },
|
||||
/*0x1f*/ { Epona, NULL, Epona_Fusion },
|
||||
/*0x20*/ { MilkCart, NULL, NULL },
|
||||
/*0x21*/ { GhostBrothers, NULL, GhostBrothers_Fusion },
|
||||
/*0x22*/ { Smith, Smith_Head, Smith_Fusion },
|
||||
/*0x23*/ { NPC23, NULL, NULL },
|
||||
/*0x24*/ { KingDaltus, NULL, KingDaltus_Fusion },
|
||||
/*0x25*/ { MinisterPotho, NULL, MinisterPotho_Fusion },
|
||||
/*0x26*/ { NPC26, NULL, NULL },
|
||||
/*0x27*/ { Vaati, NULL, NULL },
|
||||
/*0x28*/ { Zelda, NULL, NULL },
|
||||
/*0x29*/ { Mutoh, Mutoh_Head, Mutoh_Fusion },
|
||||
/*0x2a*/ { Carpenter, Carpenter_Head, Carpenter_Fusion },
|
||||
/*0x2b*/ { CastorWildsStatue, NULL, CastorWildsStatue_Fusion },
|
||||
/*0x2c*/ { Cat, NULL, Cat_Fusion },
|
||||
/*0x2d*/ { MountainMinish, MountainMinish_Head, MountainMinish_Fusion },
|
||||
/*0x2e*/ { ZeldaFollower, NULL, NULL },
|
||||
/*0x2f*/ { Melari, Melari_Head, Melari_Fusion },
|
||||
/*0x30*/ { BladeBrothers, NULL, BladeBrothers_Fusion },
|
||||
/*0x31*/ { Cow, NULL, Cow_Fusion },
|
||||
/*0x32*/ { Goron, NULL, Goron_Fusion },
|
||||
/*0x33*/ { GoronMerchant, NULL, NULL },
|
||||
/*0x34*/ { Gorman, Gorman_Head, NULL },
|
||||
/*0x35*/ { Dog, Dog_Head, Dog_Fusion },
|
||||
/*0x36*/ { Syrup, Syrup_Head, NULL },
|
||||
/*0x37*/ { Rem, NULL, NULL },
|
||||
/*0x38*/ { TownMinish, TownMinish_Head, TownMinish_Fusion },
|
||||
/*0x39*/ { Librari, NULL, Librari_Fusion },
|
||||
/*0x3a*/ { Percy, Percy_Head, Percy_Fusion },
|
||||
/*0x3b*/ { VaatiReborn, NULL, NULL },
|
||||
/*0x3c*/ { MoblinLady, NULL, NULL },
|
||||
/*0x3d*/ { Librarians, NULL, NULL },
|
||||
/*0x3e*/ { Farmers, Farmers_Head, Farmers_Fusion },
|
||||
/*0x3f*/ { Carlov, NULL, NULL },
|
||||
/*0x40*/ { Dampe, NULL, Dampe_Fusion },
|
||||
/*0x41*/ { DrLeft, NULL, NULL },
|
||||
/*0x42*/ { KingGustaf, NULL, NULL },
|
||||
/*0x43*/ { Gina, NULL, Gina_Fusion },
|
||||
/*0x44*/ { Simon, NULL, NULL },
|
||||
/*0x45*/ { Anju, NULL, Anju_Fusion },
|
||||
/*0x46*/ { Mama, Mama_Head, Mama_Fusion },
|
||||
/*0x47*/ { Emma, NULL, NULL },
|
||||
/*0x48*/ { Teachers, Teachers_Head, Teachers_Fusion },
|
||||
/*0x49*/ { WindTribespeople, WindTribespeople_Head, WindTribespeople_Fusion },
|
||||
/*0x4a*/ { Gregal, NULL, Gregal_Fusion },
|
||||
/*0x4b*/ { MayorHagen, NULL, MayorHagen_Fusion },
|
||||
/*0x4c*/ { BigGoron, NULL, NULL },
|
||||
/*0x4d*/ { EzloCap, NULL, NULL },
|
||||
/*0x4e*/ { NPC4E, NULL, NPC4E_Fusion },
|
||||
/*0x4f*/ { NPC4F, NULL, NULL },
|
||||
/*0x50*/ { ClothesRack, NULL, NULL },
|
||||
/*0x51*/ { PicolyteBottle, NULL, NULL },
|
||||
/*0x52*/ { SmallTownMinish, NULL, NULL },
|
||||
/*0x53*/ { HurdyGurdyMan, HurdyGurdyMan_Head, HurdyGurdyMan_Fusion },
|
||||
/*0x54*/ { Cucco, NULL, Cucco_Fusion },
|
||||
/*0x55*/ { CuccoChick, NULL, CuccoChick_Fusion },
|
||||
/*0x56*/ { FusionMenuNPC, FusionMenuNPC_Head, NULL },
|
||||
/*0x57*/ { Phonograph, NULL, NULL },
|
||||
/*0x58*/ { NPC58, NPC58_Head, NULL },
|
||||
/*0x59*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x5a*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x5b*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x5c*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x5d*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x5e*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x5f*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x60*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x61*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x62*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x63*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x64*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x65*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x66*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x67*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x68*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x69*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x6a*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x6b*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x6c*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x6d*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x6e*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x6f*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x70*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x71*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x72*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x73*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x74*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x75*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x76*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x77*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x78*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x79*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x7a*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x7b*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x7c*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x7d*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x7e*/ { DeleteEntity, NULL, NULL },
|
||||
/*0x7f*/ { DeleteEntity, NULL, NULL }
|
||||
[NPC_NONE_0] = { DeleteEntity, NULL, NULL },
|
||||
[GENTARI] = { Gentari, NULL, Gentari_Fusion },
|
||||
[FESTARI] = { Festari, NULL, Festari_Fusion },
|
||||
[FOREST_MINISH] = { ForestMinish, ForestMinish_Head, ForestMinish_Fusion },
|
||||
[POSTMAN] = { Postman, NULL, Postman_Fusion },
|
||||
[NPC_UNK_5] = { NPC5, NULL, NULL },
|
||||
[TPWNSPERSON] = { Townsperson, Townsperson_Head, Townsperson_Fusion },
|
||||
[KID] = { Kid, Kid_Head, Kid_Fusion },
|
||||
[GUARD] = { Guard, Guard_Head, NULL },
|
||||
[NPC_UNK_9] = { NPC9, NULL, NULL },
|
||||
[STAMP] = { Stamp, NULL, NULL },
|
||||
[MAID] = { Maid, Maid_Head, NULL },
|
||||
[MARCY] = { Marcy, NULL, NULL },
|
||||
[WHEATON] = { Wheaton, NULL, NULL },
|
||||
[PITA] = { Pita, NULL, NULL },
|
||||
[MINISH_EZLO] = { MinishEzlo, MinishEzlo_Head, NULL },
|
||||
[MAILBOX] = { Mailbox, NULL, NULL },
|
||||
[BEEDLE] = { Beedle, Beedle_Head, NULL },
|
||||
[BROCCO] = { Brocco, NULL, Brocco_Fusion },
|
||||
[SITTING_PERSON] = { SittingPerson, SittingPerson_Head, SittingPerson_Fusion },
|
||||
[PINA] = { Pina, NULL, Pina_Fusion },
|
||||
[GUARD_1] = { Guard, Guard_Head, NULL },
|
||||
[MAID_1] = { Maid, Maid_Head, NULL },
|
||||
[DIN] = { Din, NULL, Din_Fusion },
|
||||
[NAYRU] = { Nayru, NULL, Nayru_Fusion },
|
||||
[FARORE] = { Farore, NULL, Farore_Fusion },
|
||||
[STURGEON] = { Sturgeon, Sturgeon_Head, Sturgeon_Fusion },
|
||||
[TINGLE_SIBLINGS] = { TingleSiblings, NULL, TingleSiblings_Fusion },
|
||||
[STOCKWELL] = { Stockwell, NULL, NULL },
|
||||
[TALON] = { Talon, Talon_Head, Talon_Fusion },
|
||||
[MALON] = { Malon, NULL, Malon_Fusion },
|
||||
[EPONA] = { Epona, NULL, Epona_Fusion },
|
||||
[MILK_CART] = { MilkCart, NULL, NULL },
|
||||
[GHOST_BROTHERS] = { GhostBrothers, NULL, GhostBrothers_Fusion },
|
||||
[SMITH] = { Smith, Smith_Head, Smith_Fusion },
|
||||
[NPC_UNK_23] = { NPC23, NULL, NULL },
|
||||
[KING_DALTUS] = { KingDaltus, NULL, KingDaltus_Fusion },
|
||||
[MINISTER_POTHO] = { MinisterPotho, NULL, MinisterPotho_Fusion },
|
||||
[NPC_UNK_26] = { NPC26, NULL, NULL },
|
||||
[VAATI] = { Vaati, NULL, NULL },
|
||||
[ZELDA] = { Zelda, NULL, NULL },
|
||||
[MUTOH] = { Mutoh, Mutoh_Head, Mutoh_Fusion },
|
||||
[CARPENTER] = { Carpenter, Carpenter_Head, Carpenter_Fusion },
|
||||
[CASTOR_WILDS_STATUE] = { CastorWildsStatue, NULL, CastorWildsStatue_Fusion },
|
||||
[CAT] = { Cat, NULL, Cat_Fusion },
|
||||
[MOUNTAIN_MINISH] = { MountainMinish, MountainMinish_Head, MountainMinish_Fusion },
|
||||
[ZELDA_FOLLOWER] = { ZeldaFollower, NULL, NULL },
|
||||
[MELARI] = { Melari, Melari_Head, Melari_Fusion },
|
||||
[BLADE_BROTHERS] = { BladeBrothers, NULL, BladeBrothers_Fusion },
|
||||
[COW] = { Cow, NULL, Cow_Fusion },
|
||||
[GORON] = { Goron, NULL, Goron_Fusion },
|
||||
[GORON_MERCHANT] = { GoronMerchant, NULL, NULL },
|
||||
[GORMAN] = { Gorman, Gorman_Head, NULL },
|
||||
[DOG] = { Dog, Dog_Head, Dog_Fusion },
|
||||
[SYRUP] = { Syrup, Syrup_Head, NULL },
|
||||
[REM] = { Rem, NULL, NULL },
|
||||
[TOWN_MINISH] = { TownMinish, TownMinish_Head, TownMinish_Fusion },
|
||||
[LIBRARI] = { Librari, NULL, Librari_Fusion },
|
||||
[PERCY] = { Percy, Percy_Head, Percy_Fusion },
|
||||
[VAATI_REBORN] = { VaatiReborn, NULL, NULL },
|
||||
[MOBLIN_LADY] = { MoblinLady, NULL, NULL },
|
||||
[LIBRARIANS] = { Librarians, NULL, NULL },
|
||||
[FARMERS] = { Farmers, Farmers_Head, Farmers_Fusion },
|
||||
[CARLOV] = { Carlov, NULL, NULL },
|
||||
[DAMPE] = { Dampe, NULL, Dampe_Fusion },
|
||||
[DR_LEFT] = { DrLeft, NULL, NULL },
|
||||
[KING_GUSTAF] = { KingGustaf, NULL, NULL },
|
||||
[GINA] = { Gina, NULL, Gina_Fusion },
|
||||
[SIMON] = { Simon, NULL, NULL },
|
||||
[ANJU] = { Anju, NULL, Anju_Fusion },
|
||||
[MAMA] = { Mama, Mama_Head, Mama_Fusion },
|
||||
[EMMA] = { Emma, NULL, NULL },
|
||||
[TEACHERS] = { Teachers, Teachers_Head, Teachers_Fusion },
|
||||
[WIND_TRIBESPEOPLE] = { WindTribespeople, WindTribespeople_Head, WindTribespeople_Fusion },
|
||||
[GREGAL] = { Gregal, NULL, Gregal_Fusion },
|
||||
[MAYOR_HAGEN] = { MayorHagen, NULL, MayorHagen_Fusion },
|
||||
[BIG_GORON] = { BigGoron, NULL, NULL },
|
||||
[EZLO_CAP] = { EzloCap, NULL, NULL },
|
||||
[NPC_UNK_4E] = { NPC4E, NULL, NPC4E_Fusion },
|
||||
[NPC_UNK_4F] = { NPC4F, NULL, NULL },
|
||||
[CLOTHES_RACK] = { ClothesRack, NULL, NULL },
|
||||
[PICOLYTE_BOTTLE] = { PicolyteBottle, NULL, NULL },
|
||||
[SMALL_TOWN_MINISH] = { SmallTownMinish, NULL, NULL },
|
||||
[HURDY_GURDY_MAN] = { HurdyGurdyMan, HurdyGurdyMan_Head, HurdyGurdyMan_Fusion },
|
||||
[CUCCO] = { Cucco, NULL, Cucco_Fusion },
|
||||
[CUCCO_CHICK] = { CuccoChick, NULL, CuccoChick_Fusion },
|
||||
[FUSION_MENU_NPC] = { FusionMenuNPC, FusionMenuNPC_Head, NULL },
|
||||
[PHONOGRAPH] = { Phonograph, NULL, NULL },
|
||||
[NPC_UNK_58] = { NPC58, NPC58_Head, NULL },
|
||||
[NPC_NONE_1] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_2] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_3] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_4] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_5] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_6] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_7] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_8] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_9] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_10] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_11] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_12] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_13] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_14] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_15] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_16] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_17] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_18] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_19] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_20] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_21] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_22] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_23] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_24] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_25] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_26] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_27] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_28] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_29] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_30] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_31] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_32] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_33] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_34] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_35] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_36] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_37] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_38] = { DeleteEntity, NULL, NULL },
|
||||
[NPC_NONE_39] = { DeleteEntity, NULL, NULL }
|
||||
};
|
||||
//clang-format on
|
||||
const u8 npc_unk[] = { 0x04, 0x05, 0x06, 0x06 };
|
||||
|
||||
@@ -0,0 +1,115 @@
|
||||
#include "global.h"
|
||||
#include "npc.h"
|
||||
#include "coord.h"
|
||||
#include "flags.h"
|
||||
#include "audio.h"
|
||||
#include "textbox.h"
|
||||
#include "functions.h"
|
||||
|
||||
void sub_0806B67C(Entity*);
|
||||
void sub_0806B7BC(Entity*);
|
||||
void sub_0806B96C(Entity*);
|
||||
Entity* sub_0806B9BC(Entity*);
|
||||
|
||||
typedef struct xy {
|
||||
s8 x;
|
||||
s8 y;
|
||||
} PACKED xy;
|
||||
|
||||
void (*const gUnk_08112F78[])(Entity*) = {
|
||||
sub_0806B67C,
|
||||
sub_0806B7BC,
|
||||
};
|
||||
const xy gUnk_08112F80[] = { { 10, -29 }, { -10, -29 }, { 15, -21 }, { -15, -21 } };
|
||||
|
||||
void VaatiReborn(Entity* this) {
|
||||
gUnk_08112F78[this->action](this);
|
||||
}
|
||||
|
||||
void sub_0806B67C(Entity* this) {
|
||||
Entity* entity;
|
||||
u32 i;
|
||||
|
||||
this->action = 1;
|
||||
this->subAction = 0;
|
||||
this->actionDelay = 0;
|
||||
switch (this->type) {
|
||||
case 0:
|
||||
this->y.HALF.HI -= 0xa0;
|
||||
this->actionDelay = 0xa0;
|
||||
this->field_0xf = 0x20;
|
||||
this->spriteOffsetY = 0x20;
|
||||
for (i = 0; i < 4; i++) {
|
||||
entity = CreateNPC(VAATI_REBORN, 2, i);
|
||||
if (entity != NULL) {
|
||||
entity->parent = this;
|
||||
}
|
||||
}
|
||||
entity = CreateNPC(VAATI_REBORN, 1, 0);
|
||||
entity->parent = this;
|
||||
entity->spriteOffsetY = -1;
|
||||
PositionRelative(this, entity, 0, 0x10000);
|
||||
InitAnimationForceUpdate(this, 0);
|
||||
break;
|
||||
case 1:
|
||||
case 5:
|
||||
InitAnimationForceUpdate(this, 0);
|
||||
break;
|
||||
case 2:
|
||||
if ((this->type2 & 2) != 0) {
|
||||
this->spriteSettings.b.flipX = 1;
|
||||
}
|
||||
sub_0806B96C(this);
|
||||
InitAnimationForceUpdate(this, 0);
|
||||
break;
|
||||
case 3:
|
||||
this->actionDelay = 1;
|
||||
this->field_0xf = 0x20;
|
||||
entity = CreateNPC(VAATI_REBORN, 4, 0);
|
||||
if (entity != NULL) {
|
||||
CopyPosition(this, entity);
|
||||
entity->parent = this;
|
||||
entity->spritePriority.b0 = this->spritePriority.b0 - 1;
|
||||
entity->frameIndex = 0;
|
||||
}
|
||||
entity = CreateNPC(VAATI_REBORN, 5, 0);
|
||||
if (entity != NULL) {
|
||||
CopyPosition(this, entity);
|
||||
entity->parent = this;
|
||||
entity->spritePriority.b0 = this->spritePriority.b0 + 1;
|
||||
}
|
||||
InitAnimationForceUpdate(this, 0);
|
||||
break;
|
||||
case 4:
|
||||
InitializeAnimation(this, 0);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
ASM_FUNC("asm/non_matching/vaati/sub_0806B7BC.inc", void sub_0806B7BC(Entity* this))
|
||||
|
||||
void sub_0806B96C(Entity* this) {
|
||||
Entity* entity;
|
||||
const xy* ptr;
|
||||
|
||||
entity = sub_0806B9BC(this);
|
||||
if (entity == NULL) {
|
||||
DeleteThisEntity();
|
||||
}
|
||||
ptr = &gUnk_08112F80[this->type2];
|
||||
this->spriteSettings.b.draw = entity->spriteSettings.b.draw;
|
||||
PositionRelative(entity, this, ptr->x << 0x10, (ptr->y + 0x21) << 0x10);
|
||||
UpdateAnimationSingleFrame(this);
|
||||
}
|
||||
|
||||
Entity* sub_0806B9BC(Entity* this) {
|
||||
Entity* entity;
|
||||
|
||||
entity = this->parent;
|
||||
if (entity != NULL && entity->next == NULL) {
|
||||
entity = NULL;
|
||||
}
|
||||
return entity;
|
||||
}
|
||||
Reference in New Issue
Block a user