Renaming Juju
This commit is contained in:
@@ -1364,7 +1364,7 @@ enum sfx_e
|
||||
SFX_3F2_UNKNOWN, //gold_chest_ttc
|
||||
|
||||
SFX_3F5_UNKNOWN = 0x3F5, //RBB/code_5F80
|
||||
SFX_3F6_UNKNOWN, //lair/code_0 func_803880BC
|
||||
SFX_3F6_RUBBING, //lair/code_0 func_803880BC
|
||||
SFX_3F7_UNKNOWN, //gv/histup
|
||||
SFX_3F8_UNKNOWN, //gv/histup
|
||||
SFX_3F9_UNKNOWN, //chmole
|
||||
@@ -2299,7 +2299,7 @@ enum mm_specific_flags {
|
||||
MM_SPECIFIC_FLAG_6_UNKNOWN = 0x6,
|
||||
|
||||
MM_SPECIFIC_FLAG_8_HIT_WITH_ORANGE = 0x8,
|
||||
MM_SPECIFIC_FLAG_9_UNKNOWN,
|
||||
MM_SPECIFIC_FLAG_9_JUJU_HAS_HALF_TURNED,
|
||||
MM_SPECIFIC_FLAG_A_UNKNOWN
|
||||
};
|
||||
|
||||
|
@@ -393,7 +393,7 @@ void func_8030E0FC(u8, f32, f32, f32);
|
||||
f32 func_8030E200(u8);
|
||||
void func_8030E2C4(u8);
|
||||
void func_8030E394(u8 indx);
|
||||
void func_8030E484(enum sfx_e uid);
|
||||
void sfxsource_playHighPriority(enum sfx_e uid);
|
||||
void func_8030E4E4(enum sfx_e uid);
|
||||
void sfxsource_play(enum sfx_e uid, s32 sample_rate);
|
||||
void func_8030E540(enum sfx_e uid);
|
||||
|
@@ -260,7 +260,7 @@ typedef struct actor_s{
|
||||
u32 unk138_28:1;
|
||||
u32 unk138_27:2;
|
||||
u32 unk138_25:1;
|
||||
u32 is_first_encounter:TRUE;
|
||||
u32 has_met_before:1;
|
||||
u32 unk138_23:1;
|
||||
u32 unk138_22:1;
|
||||
u32 unk138_21:1;
|
||||
|
@@ -205,7 +205,7 @@ sfxsource_setSfxId = 0x8030dc20;
|
||||
sfxsource_setSampleRate = 0x8030dc5c;
|
||||
func_8030DBB4 = 0x8030dd54;
|
||||
func_8030E2C4 = 0x8030e464;
|
||||
func_8030E484 = 0x8030e624;
|
||||
sfxsource_playHighPriority = 0x8030e624;
|
||||
func_8030E58C = 0x8030e72c;
|
||||
func_8030E624 = 0x8030e7c4;
|
||||
func_8030E6A4 = 0x8030e844;
|
||||
|
@@ -143,8 +143,8 @@ void BGS_func_803888E4(Actor *this, s32 arg1){
|
||||
skeletalAnim_set(this->unk148, ASSET_12B_ANIM_TIPTUP_IDLE, 1.0f, 9.0f);
|
||||
unqPtr->unkC = randf2(5.0f, 15.0f);
|
||||
|
||||
if (!this->is_first_encounter) {
|
||||
this->is_first_encounter = TRUE;
|
||||
if (!this->has_met_before) {
|
||||
this->has_met_before = TRUE;
|
||||
|
||||
if (unqPtr->unkA == 0) {
|
||||
gcdialog_showText(ASSET_C72_TEXT_UNKNOWN, 0xe, this->position, this->marker, func_80388784, 0);
|
||||
|
@@ -111,7 +111,7 @@ void func_8038F6A4(Actor *this)
|
||||
{
|
||||
nodeprop_getPosition(temp_v0, local->unk18);
|
||||
}
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
this->initialized = TRUE;
|
||||
}
|
||||
if (!this->volatile_initialized)
|
||||
@@ -138,12 +138,12 @@ void func_8038F6A4(Actor *this)
|
||||
case 1:
|
||||
func_8038F610(this);
|
||||
player_getPosition(sp48);
|
||||
if (!this->is_first_encounter)
|
||||
if (!this->has_met_before)
|
||||
{
|
||||
if ((((ml_distance_vec3f(local->unk18, sp48) < 250.0f) && (ml_distance_vec3f(local->unk18, sp48) > 80.0f)) && (!func_8028ECAC())) && (player_getTransformation() == TRANSFORM_1_BANJO))
|
||||
{
|
||||
gcdialog_showText(0xC7E, 0, 0, 0, 0, 0);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
if (local->unk10)
|
||||
|
@@ -43,7 +43,7 @@ void func_803897F0(Actor *this, s32 next_state){
|
||||
|
||||
if(next_state == 2){
|
||||
func_8025A6EC(COMUSIC_2D_PUZZLE_SOLVED_FANFARE, -1);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.9f, 29000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.9f, 29000);
|
||||
local->unk4 = 0.0f;
|
||||
}
|
||||
|
||||
|
@@ -89,7 +89,7 @@ void __chgrublinhood_die(ActorMarker* marker, s32 arg1) {
|
||||
__chgrublinhood_emitHat(pCtrl, actor, ASSET_52D_MODEL_GRUBLIN_HOOD_HAT);
|
||||
__spawnQueue_add_4((GenFunction_4)func_802C4140, ACTOR_4C_STEAM, reinterpret_cast(s32,actor->position_x), reinterpret_cast(s32,actor->position_y), reinterpret_cast(s32,actor->position_z));
|
||||
actor_collisionOff(actor);
|
||||
actor->is_first_encounter = TRUE;
|
||||
actor->has_met_before = TRUE;
|
||||
}
|
||||
|
||||
Actor *chgrublinhood_draw(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
|
||||
@@ -109,7 +109,7 @@ Actor *chgrublinhood_draw(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
|
||||
func_8033A45C(11, (local->season < AUTUMN) ? 0 : (local->season == AUTUMN) ? 1 : 2);
|
||||
func_8033A45C(12, (local->season == WINTER) ? 2 : 1);
|
||||
func_8033A45C(13, (local->season == WINTER) ? 1 : 0);
|
||||
func_8033A45C(14, (this->is_first_encounter)? FALSE : TRUE);
|
||||
func_8033A45C(14, (this->has_met_before)? FALSE : TRUE);
|
||||
return actor_draw(marker, gfx, mtx, vtx);
|
||||
}
|
||||
|
||||
|
@@ -137,7 +137,7 @@ void chGobiCCW_update(Actor *this) {
|
||||
this->volatile_initialized = TRUE;
|
||||
this->marker->propPtr->unk8_3 = TRUE;
|
||||
this->marker->actorFreeFunc = chGobiCCW_free;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
local->unk4 = skeletalAnim_new();
|
||||
local->spit_model = assetcache_get(ASSET_3F3_MODEL_GOBI_SPIT);
|
||||
marker_setCollisionScripts(this->marker, 0, func_8038894C, 0);
|
||||
@@ -159,13 +159,13 @@ void chGobiCCW_update(Actor *this) {
|
||||
return;
|
||||
}
|
||||
if(this->state == 1){
|
||||
if (!this->is_first_encounter) {
|
||||
if (!this->has_met_before) {
|
||||
player_getPosition(sp48);
|
||||
if (ml_distance_vec3f(this->position, sp48) < 600.0f) {
|
||||
if (local->unk0->unk2 != 0) {
|
||||
gcdialog_showText((s32) local->unk0->unk2, 4, NULL, NULL, NULL, NULL);
|
||||
}
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -214,7 +214,7 @@ void CCW_func_80389BFC(Actor *this) {
|
||||
if (!this->volatile_initialized) {
|
||||
this->volatile_initialized = TRUE;
|
||||
this->marker->propPtr->unk8_3 = TRUE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
this->position[0] = -4900.0f;
|
||||
this->position[1] = 4619.0f;
|
||||
this->position[2] = 0.0f;
|
||||
@@ -253,12 +253,12 @@ void CCW_func_80389BFC(Actor *this) {
|
||||
}
|
||||
if (this->state == 1) {
|
||||
player_getPosition(sp4C);
|
||||
if( !this->is_first_encounter
|
||||
if( !this->has_met_before
|
||||
&& (local->unkC[2] >= 6500)
|
||||
&& (sp4C[2] < 6500.0f)
|
||||
&& (local->unk0->unk28 != 0)
|
||||
){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
func_80324E38(0.0f, 3);
|
||||
timed_setStaticCameraToNode(0.0f, local->unk0->unk24);
|
||||
func_80324DBC(0.0f, local->unk0->unk28, 6, NULL, this->marker, func_80389700, NULL);
|
||||
|
@@ -61,7 +61,7 @@ void func_8038B19C(Actor *this) {
|
||||
|
||||
if (!this->volatile_initialized) {
|
||||
this->volatile_initialized = TRUE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
func_8038B0F0(this, 1);
|
||||
}
|
||||
|
||||
@@ -88,8 +88,8 @@ void func_8038B19C(Actor *this) {
|
||||
func_8038B0F0(this, 1);
|
||||
}
|
||||
}
|
||||
if (!this->is_first_encounter && func_803292E0(this)) {
|
||||
this->is_first_encounter = TRUE;
|
||||
if (!this->has_met_before && func_803292E0(this)) {
|
||||
this->has_met_before = TRUE;
|
||||
gcdialog_showText(0xCC8, 0, NULL, NULL, NULL, NULL);
|
||||
}
|
||||
func_8028E668(this->position, 300.0f, -50.0f, 120.0f);
|
||||
|
@@ -87,11 +87,11 @@ void func_8038B814(Actor *this, s32 next_state) {
|
||||
void func_8038B87C(Actor *this) {
|
||||
if (!this->volatile_initialized) {
|
||||
this->volatile_initialized = TRUE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
func_8038B814(this, 1);
|
||||
}
|
||||
if (!this->is_first_encounter && func_803292E0(this)) {
|
||||
this->is_first_encounter = TRUE;
|
||||
if (!this->has_met_before && func_803292E0(this)) {
|
||||
this->has_met_before = TRUE;
|
||||
gcdialog_showText(0xCC9, 0, NULL, NULL, NULL, NULL);
|
||||
}
|
||||
func_8028E668(this->position, 300.0f, -50.0f, 120.0f);
|
||||
|
@@ -121,7 +121,7 @@ void chnabnut_update(Actor *this) {
|
||||
D_8038F350[1] = this->position[1];
|
||||
D_8038F350[2] = this->position[2];
|
||||
if (this->state == 0) {
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
local->returned_acorn_count = NULL;
|
||||
}
|
||||
chnabnut_setState(this, 1);
|
||||
@@ -133,15 +133,15 @@ void chnabnut_update(Actor *this) {
|
||||
|
||||
if (this->state == NABNUT_STATE_1_SAD) {
|
||||
player_getPosition(sp30);
|
||||
if (!this->is_first_encounter && (ml_distance_vec3f(this->position, sp30) < 400.0f)) {
|
||||
this->is_first_encounter = TRUE;
|
||||
if (!this->has_met_before && (ml_distance_vec3f(this->position, sp30) < 400.0f)) {
|
||||
this->has_met_before = TRUE;
|
||||
gcdialog_showText(0xCCA, 0xE, this->position, NULL, NULL, NULL);
|
||||
}
|
||||
if (item_getCount(ITEM_23_ACORNS) > 0) {
|
||||
func_80258A4C(this->position, this->yaw - 90.0f, sp30, &sp2C, &sp28, &sp24);
|
||||
this->yaw += sp24 * 10.0f;
|
||||
}
|
||||
if (this->is_first_encounter && !func_803114B0()) {
|
||||
if (this->has_met_before && !func_803114B0()) {
|
||||
func_8028F364(this->position, 500.0f, 200.0f, ACTOR_2A9_ACORN, &this);
|
||||
if ((carriedObj_getActorId() == ACTOR_2A9_ACORN) && (ml_distance_vec3f(this->position, sp30) < 300.0f) && player_throwCarriedObject()) {
|
||||
func_8028FA54(D_8038F350);
|
||||
|
@@ -93,7 +93,7 @@ void func_8038C41C(Actor *this) {
|
||||
if (!this->volatile_initialized) {
|
||||
this->marker->propPtr->unk8_3 = TRUE;
|
||||
this->volatile_initialized = TRUE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -114,8 +114,8 @@ void func_8038C41C(Actor *this) {
|
||||
|
||||
if ((this->marker->id == 0x1CB) && (this->state == 2)) {
|
||||
player_getPosition(sp2C);
|
||||
if (!this->is_first_encounter && (ml_distance_vec3f(this->position, sp2C) < 400.0f)) {
|
||||
this->is_first_encounter = TRUE;
|
||||
if (!this->has_met_before && (ml_distance_vec3f(this->position, sp2C) < 400.0f)) {
|
||||
this->has_met_before = TRUE;
|
||||
gcdialog_showText(0xCCD, 0, NULL, NULL, NULL, NULL);
|
||||
}
|
||||
}
|
||||
|
@@ -91,7 +91,7 @@ void func_8038CC4C(Actor *this) {
|
||||
if (!this->volatile_initialized) {
|
||||
this->marker->propPtr->unk8_3 = TRUE;
|
||||
this->volatile_initialized = TRUE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
local->unk0 = &D_8038F490[0];
|
||||
while(local->unk0->map_id != 0 && map_get() != local->unk0->map_id){
|
||||
local->unk0++;
|
||||
@@ -113,12 +113,12 @@ void func_8038CC4C(Actor *this) {
|
||||
this->yaw += 30.0f * sp44;
|
||||
}
|
||||
}
|
||||
if (!this->is_first_encounter) {
|
||||
if (!this->has_met_before) {
|
||||
player_getPosition(sp38);
|
||||
if (ml_distance_vec3f(this->position, sp38) < 900.0f) {
|
||||
if (local->unk0->map_id != MAP_46_CCW_WINTER || func_8028F2FC()) {
|
||||
gcdialog_showText(local->unk0->unk4, 4, NULL, NULL, NULL, NULL);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -82,7 +82,7 @@ void func_8038CFB4(Actor *this) {
|
||||
if (!this->volatile_initialized) {
|
||||
this->marker->propPtr->unk8_3 = TRUE;
|
||||
this->volatile_initialized = TRUE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
func_8038CEB0(this, 1);
|
||||
if (jiggyscore_isCollected(JIGGY_4B_CCW_GNAWTY) != 0) {
|
||||
levelSpecificFlags_set(0x25, 1);
|
||||
@@ -114,11 +114,11 @@ void func_8038CFB4(Actor *this) {
|
||||
}
|
||||
|
||||
if (this->state == 1) {
|
||||
if (!this->is_first_encounter) {
|
||||
if (!this->has_met_before) {
|
||||
player_getPosition(sp60);
|
||||
if (ml_distance_vec3f(this->position, sp60) < 900.0f) {
|
||||
gcdialog_showText(0xCCF, 4, NULL, NULL, NULL, NULL);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
if (levelSpecificFlags_get(0x25) != 0) {
|
||||
|
@@ -53,7 +53,7 @@ void func_8038D368(Actor *this) {
|
||||
if (!this->volatile_initialized) {
|
||||
this->marker->propPtr->unk8_3 = TRUE;
|
||||
this->volatile_initialized = TRUE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
local->unk0 = D_8038F600;
|
||||
while (local->unk0->map != 0 && map_get() != local->unk0->map) {
|
||||
local->unk0++;
|
||||
@@ -66,7 +66,7 @@ void func_8038D368(Actor *this) {
|
||||
return;
|
||||
}
|
||||
|
||||
if(!this->is_first_encounter){
|
||||
if(!this->has_met_before){
|
||||
player_getPosition(plyr_pos);
|
||||
if (ml_distance_vec3f(this->position, plyr_pos) < 600.0f) {
|
||||
if (!jiggyscore_isCollected(JIGGY_4B_CCW_GNAWTY)) {
|
||||
@@ -76,7 +76,7 @@ void func_8038D368(Actor *this) {
|
||||
gcdialog_showText(local->unk0->unk4, 4, NULL, NULL, NULL, NULL);
|
||||
}
|
||||
}
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -137,7 +137,7 @@ void func_8038794C(Actor *this){
|
||||
switch(this->state){
|
||||
case 1://L80387AB0
|
||||
if(mapSpecificFlags_get(0xb))
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
|
||||
if(mapSpecificFlags_get(0x1)){
|
||||
func_8028F94C(1, this->position);
|
||||
@@ -147,13 +147,13 @@ void func_8038794C(Actor *this){
|
||||
break;
|
||||
}//L80387B38
|
||||
|
||||
if(!this->is_first_encounter && func_80329530(this, 0x1f4)){
|
||||
if(!this->has_met_before && func_80329530(this, 0x1f4)){
|
||||
if(!func_8028ECAC() || func_8028ECAC() == BSGROUP_8_TROT){
|
||||
if (gcdialog_showText(ASSET_BFF_TEXT_UNKNOWN, 0x2a, this->position, NULL, NULL, NULL)) {
|
||||
for (i = 0; i < 5; i++) {
|
||||
timedFunc_set_1(D_80391BEC[i], (GenFunction_1) func_8038787C, (s32) this->marker);
|
||||
}
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -69,7 +69,7 @@ void func_80390388(Actor *this){
|
||||
|| jiggyscore_isCollected(JIGGY_2E_FP_PRESENTS)
|
||||
|| func_80390334()
|
||||
){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
|
||||
if( func_80329530(this, 0xFA)
|
||||
@@ -77,14 +77,14 @@ void func_80390388(Actor *this){
|
||||
){
|
||||
if(0.0f == this->unk1C[0] && func_80390334()){
|
||||
if(gcdialog_showText(ASSET_C1F_TEXT_UNKNOWN, 0xb, this->position, NULL, NULL, NULL)){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
this->unk1C[0] = 1.0f;
|
||||
}
|
||||
}
|
||||
else{
|
||||
if( !this->is_first_encounter ){
|
||||
if( !this->has_met_before ){
|
||||
if(gcdialog_showText(ASSET_C1E_TEXT_UNKNOWN, 0x2b, this->position, NULL, NULL, NULL)){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -299,10 +299,10 @@ void FP_func_8038F7AC(Actor *this){
|
||||
break;
|
||||
}
|
||||
|
||||
if(func_80329530(this, 500) && !this->is_first_encounter){
|
||||
if(func_80329530(this, 500) && !this->has_met_before){
|
||||
if(gcdialog_showText(0xc1c, 0xAA, this->position, this->marker, func_8038F330, func_8038F3C4)){
|
||||
timed_setStaticCameraToNode(0.0f, 0x2E);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
break;
|
||||
}//L8038FD40
|
||||
|
@@ -176,13 +176,13 @@ void chGobi1_update(Actor *this){
|
||||
}
|
||||
|
||||
if(this->state == 1 || this->state == 2){
|
||||
if( !this->is_first_encounter
|
||||
if( !this->has_met_before
|
||||
&& func_80329530(this, 250)
|
||||
&& !func_80329530(this, 80)
|
||||
&& func_8028F2A0()
|
||||
&& gcdialog_showText(0xa73, 0, NULL, NULL, NULL, NULL)
|
||||
){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}//L803877A4
|
||||
|
||||
|
@@ -200,11 +200,11 @@ void chGobi2_update(Actor *this){
|
||||
}//L80388114
|
||||
|
||||
if(this->state == 2){
|
||||
if(!this->is_first_encounter){
|
||||
if(!this->has_met_before){
|
||||
if(func_80329530(this, 0xFA) && !func_80329530(this, 0x50)){
|
||||
if(func_8028F2A0()){
|
||||
if(gcdialog_showText(ASSET_A75_TEXT_GOBI2_MEET, 0, this->position, NULL, NULL, NULL))
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -69,9 +69,9 @@ void __chMazeCtrl_setState(Actor *this, s32 next_state){
|
||||
item_set(ITEM_0_HOURGLASS_TIMER, 0xdd3);
|
||||
item_set(ITEM_6_HOURGLASS, TRUE);
|
||||
func_8038F520(1.0f);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.8f, 25000);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.7f, 25000);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.5f, 25000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.8f, 25000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.7f, 25000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.5f, 25000);
|
||||
if(1500.0f < plyr_pos[0]){
|
||||
func_80324E38(0.0f, 3);
|
||||
timed_setStaticCameraToNode(0.0f, 8);
|
||||
@@ -104,10 +104,10 @@ void __chMazeCtrl_setState(Actor *this, s32 next_state){
|
||||
}//L8038F850
|
||||
|
||||
if(next_state == 4){
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 1.0f, 30000);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.8f, 29000);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.7f, 28000);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.5f, 31000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 1.0f, 30000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.8f, 29000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.7f, 28000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.5f, 31000);
|
||||
func_8030E6D4(SFX_52_BANJO_YAH_OH);
|
||||
tmp_v0 = func_8034C528(400);
|
||||
if(tmp_v0){
|
||||
|
@@ -74,7 +74,7 @@ void chSarcophagus_update(Actor *this){
|
||||
if(func_80329530(this, 500) && func_8038957C(this)){
|
||||
subaddie_set_state_with_direction(this, 2, 0.01f, 1);
|
||||
FUNC_8030E8B4(SFX_6B_LOCKUP_OPENING, 1.0f, 32000, this->position, 1250, 2500);
|
||||
FUNC_8030E8B4(SFX_3F6_UNKNOWN, 1.0f, 32000, this->position, 1250, 2500);
|
||||
FUNC_8030E8B4(SFX_3F6_RUBBING, 1.0f, 32000, this->position, 1250, 2500);
|
||||
|
||||
}
|
||||
break;
|
||||
@@ -96,7 +96,7 @@ void chSarcophagus_update(Actor *this){
|
||||
if(!func_80329530(this, 700)){
|
||||
subaddie_set_state_with_direction(this, 4, 0.5f, 1);
|
||||
FUNC_8030E8B4(SFX_6B_LOCKUP_OPENING, 1.0f, 32000, this->position, 1250, 2500);
|
||||
FUNC_8030E8B4(SFX_3F6_UNKNOWN, 1.0f, 32000, this->position, 1250, 2500);
|
||||
FUNC_8030E8B4(SFX_3F6_RUBBING, 1.0f, 32000, this->position, 1250, 2500);
|
||||
}
|
||||
break;
|
||||
case 4: //L803897E4
|
||||
@@ -134,7 +134,7 @@ void chSarcophagus_updateSNS(Actor *this){
|
||||
if(this->unk1C[0] == 0.0f){
|
||||
subaddie_set_state_with_direction(this, 5, 0.01f, 1);
|
||||
FUNC_8030E8B4(SFX_6B_LOCKUP_OPENING, 0.5f, 32000, this->position, 1250, 2500);
|
||||
FUNC_8030E8B4(SFX_3F6_UNKNOWN, 0.5f, 32000, this->position, 1250, 2500);
|
||||
FUNC_8030E8B4(SFX_3F6_RUBBING, 0.5f, 32000, this->position, 1250, 2500);
|
||||
}
|
||||
}
|
||||
else{//L803899C0
|
||||
|
@@ -69,13 +69,13 @@ void chTrucker_update(Actor *this){
|
||||
}
|
||||
}//L803891D8
|
||||
if( this->state == 1
|
||||
&& !this->is_first_encounter
|
||||
&& !this->has_met_before
|
||||
&& func_80329530(this, 250)
|
||||
&& !func_80329530(this, 80)
|
||||
&& func_8028F2A0()
|
||||
){
|
||||
gcdialog_showText(ASSET_A71_TEXT_TRUNKER_MEET, 0xe, this->position, NULL, NULL, NULL);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}//L80389254
|
||||
|
||||
if(this->state == 1 && mapSpecificFlags_get(0xC)){
|
||||
|
@@ -30,7 +30,7 @@ void func_80389A20(ActorMarker *caller, enum asset_e text_id, s32 arg2){
|
||||
|
||||
void func_80389A60(Actor *this){
|
||||
gcdialog_showText(ASSET_A70_TEXT_CHARMER_HELPED, 4, NULL, this->marker, func_80389A20, NULL);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
subaddie_set_state(this, 5);
|
||||
}
|
||||
|
||||
@@ -48,7 +48,7 @@ void func_80389ABC(Actor *this){
|
||||
void func_80389B1C(Actor *this){
|
||||
if(!this->volatile_initialized){
|
||||
this->lifetime_value = (f32) func_8038E184();
|
||||
this->is_first_encounter = jiggyscore_isCollected(JIGGY_43_GV_HISTUP) || mapSpecificFlags_get(0);
|
||||
this->has_met_before = jiggyscore_isCollected(JIGGY_43_GV_HISTUP) || mapSpecificFlags_get(0);
|
||||
this->unk138_23 = jiggyscore_isCollected(JIGGY_43_GV_HISTUP) || mapSpecificFlags_get(2);
|
||||
this->volatile_initialized = TRUE;
|
||||
}
|
||||
@@ -62,9 +62,9 @@ void func_80389B1C(Actor *this){
|
||||
animctrl_setTransitionDuration(this->animctrl, 0.15f);
|
||||
|
||||
if(this->state == 1 || this->state == 2){
|
||||
if(! this->is_first_encounter && func_80329530(this, 250) && !func_80329530(this, 0x50)){
|
||||
if(! this->has_met_before && func_80329530(this, 250) && !func_80329530(this, 0x50)){
|
||||
gcdialog_showText(ASSET_A6F_TEXT_CHARMER_MEET, 0xe, this->position, NULL, NULL, NULL);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
mapSpecificFlags_set(0, TRUE);
|
||||
}
|
||||
}
|
||||
|
@@ -244,9 +244,9 @@ void GV_func_8038BEA0(Actor *this){
|
||||
}
|
||||
}
|
||||
else{
|
||||
if(!this->is_first_encounter){
|
||||
if(!this->has_met_before){
|
||||
if(gcdialog_showText(ASSET_A78_TEXT_GRABBA_MEET, 0, NULL, NULL, NULL, NULL)){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -44,9 +44,9 @@ ActorInfo D_8039123C = { 0xBB, 0x287, 0x3E6,
|
||||
void func_8038C760(Actor *this, s32 arg1){
|
||||
ActorLocal_GV_6370 *local = (ActorLocal_GV_6370 *)&this->local;
|
||||
chBuriedPyramid_setRaisedAmount(local->unk14, arg1);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.7f, 28000);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.9f, 29000);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 1.0f, 30000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.7f, 28000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.9f, 29000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 1.0f, 30000);
|
||||
timed_setStaticCameraToNode(0.0f, 8);
|
||||
if(arg1 < 3){
|
||||
timed_setStaticCameraToNode(3.5f, arg1 + 0x15);
|
||||
@@ -95,7 +95,7 @@ void func_8038C8A0(Actor *this, s32 next_state){
|
||||
local->unk18[2] = this->position_z;
|
||||
if(this->state == 1){
|
||||
rumbleManager_80250E94(0.0f, 0.6f, 1.0f, 0, 1.3f, 0.0f);
|
||||
timed_playSfx(1.0f, SFX_3F6_UNKNOWN, 0.8f, 30000);
|
||||
timed_playSfx(1.0f, SFX_3F6_RUBBING, 0.8f, 30000);
|
||||
}
|
||||
}//L8038CA6C
|
||||
|
||||
@@ -126,7 +126,7 @@ void func_8038C8A0(Actor *this, s32 next_state){
|
||||
local->unk18[1] = this->position_y;
|
||||
local->unk18[2] = this->position_z;
|
||||
rumbleManager_80250D94(0.7f, 0.5f, 1.3f);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.8f, 30000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.8f, 30000);
|
||||
}
|
||||
|
||||
if(next_state == 8){
|
||||
|
@@ -53,7 +53,7 @@ Struct_GV_9DB0_1 * func_803901A0(s32 arg0){
|
||||
}
|
||||
|
||||
void func_803901F0(void *arg0){
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 1.0f, 30000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 1.0f, 30000);
|
||||
}
|
||||
|
||||
void func_80390218(void *arg0){
|
||||
|
@@ -29,9 +29,9 @@ void __waterCtrl_setState(s32 arg0){
|
||||
func_80324E38(6.0f, 0);
|
||||
tmp_v0 = func_8034C528(400);
|
||||
if(tmp_v0){
|
||||
func_8030E760(SFX_3F6_UNKNOWN, 0.7f, 28000);
|
||||
func_8030E760(SFX_3F6_UNKNOWN, 0.9f, 29000);
|
||||
func_8030E760(SFX_3F6_UNKNOWN, 1.0f, 30000);
|
||||
func_8030E760(SFX_3F6_RUBBING, 0.7f, 28000);
|
||||
func_8030E760(SFX_3F6_RUBBING, 0.9f, 29000);
|
||||
func_8030E760(SFX_3F6_RUBBING, 1.0f, 30000);
|
||||
func_8034DE60(tmp_v0, 0.0f, 400.0f, 2.5f, 1);
|
||||
}
|
||||
}
|
||||
|
@@ -255,9 +255,9 @@ void func_803876D0(Actor *this){
|
||||
mapSpecificFlags_set(MM_SPECIFIC_FLAG_A_UNKNOWN, TRUE);
|
||||
}//L803878F8
|
||||
|
||||
if( sp3C && !this->is_first_encounter){
|
||||
if( sp3C && !this->has_met_before){
|
||||
if(gcdialog_showText((player_getTransformation()== TRANSFORM_2_TERMITE) ? ASSET_B3E_TEXT_CONGA_MEET_AS_TERMITE : ASSET_B3C_TEXT_CONGA_MEET, 0, this->position, 0,0,0)){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
} //L80387968
|
||||
|
||||
|
@@ -79,7 +79,7 @@ void chhut_update(Actor *this) {
|
||||
diff_pos[2] = this->position_z;
|
||||
diff_pos[1] += 125.0;
|
||||
|
||||
func_8030E484(SFX_5B_HEAVY_STUFF_FALLING);
|
||||
sfxsource_playHighPriority(SFX_5B_HEAVY_STUFF_FALLING);
|
||||
subaddie_set_state(this, HUT_STATE_1_DAMAGED);
|
||||
actor_playAnimationOnce(this);
|
||||
__spawnQueue_add_1((GenFunction_1) __chhut_spawnExplosion, (s32) this->marker);
|
||||
|
283
src/MM/ch/juju.c
283
src/MM/ch/juju.c
@@ -3,91 +3,106 @@
|
||||
#include "variables.h"
|
||||
|
||||
/* extern functions */
|
||||
int func_80353064(f32*, f32);
|
||||
void func_802BB3DC(s32, f32, f32);
|
||||
int func_80353064(f32 *, f32);
|
||||
void func_802BB3DC(s32, f32, f32);
|
||||
|
||||
typedef struct{
|
||||
s32 unk0;
|
||||
s32 unk4;
|
||||
TUPLE(f32, unk8);
|
||||
f32 unk14;
|
||||
s32 unk18;
|
||||
}ActorLocal_Juju_2;
|
||||
typedef struct {
|
||||
s32 animation_state;
|
||||
s32 animation_countdown;
|
||||
TUPLE(f32, next_pos);
|
||||
f32 scale;
|
||||
s32 unk18;
|
||||
} ActorLocal_Juju_2;
|
||||
|
||||
/* public functions */
|
||||
void func_80389598(Actor *this);
|
||||
Actor* func_80389014(ActorMarker *, Gfx **, Mtx**, Vtx** );
|
||||
void chjuju_update(Actor *this);
|
||||
Actor *chjuju_draw(ActorMarker *, Gfx **, Mtx **, Vtx **);
|
||||
|
||||
/* .bss */
|
||||
u8 MM_pad_80389C80[0x10];
|
||||
s32 MM_D_80389C90;
|
||||
s32 mm_juju_count;
|
||||
|
||||
/* .data */
|
||||
ActorInfo chjujuInfo = { MARKER_67_JUJU, ACTOR_59_JUJU, ASSET_2E6_MODEL_JUJU,
|
||||
enum chjuju_animation_state_e {
|
||||
JUJU_ANIMATION_STATE_1_YAWING = 1,
|
||||
JUJU_ANIMATION_STATE_2_DESPAWNED,
|
||||
JUJU_ANIMATION_STATE_3_WAITING_TO_FALL,
|
||||
JUJU_ANIMATION_STATE_4_FALLING,
|
||||
JUJU_ANIMATION_STATE_5_DISAPPEARING
|
||||
};
|
||||
|
||||
ActorInfo chjujuInfo = {
|
||||
MARKER_67_JUJU, ACTOR_59_JUJU, ASSET_2E6_MODEL_JUJU,
|
||||
0, NULL,
|
||||
func_80389598, func_80326224, func_80389014,
|
||||
chjuju_update, func_80326224, chjuju_draw,
|
||||
0, 0, 0.0f, 0
|
||||
};
|
||||
|
||||
void func_80388FD0(Actor *this, f32 *arg1, f32 *arg2, s32 arg3){
|
||||
/* .code */
|
||||
void __chjuju_initialize(Actor *this, f32 *arg1, f32 *arg2, s32 animationState) {
|
||||
ActorLocal_Juju_2 *local;
|
||||
|
||||
local = (ActorLocal_Juju_2 *)&this->local;
|
||||
local->unk0 = arg3;
|
||||
local->unk14 = 1.0f;
|
||||
local = (ActorLocal_Juju_2 *) &this->local;
|
||||
local->animation_state = animationState;
|
||||
local->scale = 1.0f;
|
||||
|
||||
this->position_x = arg1[0];
|
||||
this->position_y = arg1[1];
|
||||
this->position_z = arg1[2];
|
||||
|
||||
local->unk8_x = arg2[0];
|
||||
local->unk8_y = arg2[1];
|
||||
local->unk8_z = arg2[2];
|
||||
|
||||
local->next_pos_x = arg2[0];
|
||||
local->next_pos_y = arg2[1];
|
||||
local->next_pos_z = arg2[2];
|
||||
}
|
||||
|
||||
Actor* func_80389014(ActorMarker *this, Gfx **dl, Mtx **mPtr, Vtx **arg2){
|
||||
Actor *chjuju_draw(ActorMarker *this, Gfx **dl, Mtx **mPtr, Vtx **arg2) {
|
||||
f32 rotation[3];
|
||||
Actor * actorPtr;
|
||||
Actor *actorPtr;
|
||||
ActorLocal_Juju_2 *jujuPtr;
|
||||
|
||||
actorPtr = marker_getActorAndRotation(this, rotation);
|
||||
jujuPtr = (ActorLocal_Juju_2 *)&actorPtr->local;
|
||||
if(jujuPtr->unk0 != 2){
|
||||
jujuPtr = (ActorLocal_Juju_2 *) &actorPtr->local;
|
||||
|
||||
if (jujuPtr->animation_state != JUJU_ANIMATION_STATE_2_DESPAWNED) {
|
||||
modelRender_setDepthMode(MODEL_RENDER_DEPTH_FULL);
|
||||
modelRender_draw(dl, mPtr, actorPtr->position, rotation, jujuPtr->unk14, NULL, marker_loadModelBin(this));
|
||||
modelRender_draw(dl, mPtr, actorPtr->position, rotation, jujuPtr->scale, NULL, marker_loadModelBin(this));
|
||||
}
|
||||
|
||||
return actorPtr;
|
||||
}
|
||||
|
||||
void func_803890A0(ActorMarker *marker, s32 arg1){
|
||||
int s1;
|
||||
Actor* actorPtr = marker_getActor(marker);
|
||||
void __chjuju_initialize_all(ActorMarker *marker, s32 count) {
|
||||
int should_spawn;
|
||||
Actor *actorPtr = marker_getActor(marker);
|
||||
f32 position[3];
|
||||
s32 i;
|
||||
Actor* jujuPtr;
|
||||
Actor *jujuPtr;
|
||||
|
||||
position[0] = actorPtr->position_x;
|
||||
position[1] = actorPtr->position_y;
|
||||
position[2] = actorPtr->position_z;
|
||||
for(i = 0; i < 4; i++){
|
||||
|
||||
for (i = 0; i < 4; i++) {
|
||||
jujuPtr = spawn_actor_f32(ACTOR_59_JUJU, actorPtr->position, actorPtr->yaw);
|
||||
jujuPtr->marker->collidable = FALSE;
|
||||
|
||||
actorPtr = marker_getActor(marker);
|
||||
func_80388DE8(actorPtr, i, jujuPtr);
|
||||
chjujuhitbox_setJuju(actorPtr, i, jujuPtr);
|
||||
|
||||
s1 = (i >= arg1);
|
||||
func_80388FD0(jujuPtr, position, actorPtr->position, (s1)? 1 : 2);
|
||||
should_spawn = (i >= count);
|
||||
__chjuju_initialize(jujuPtr, position, actorPtr->position, should_spawn ? JUJU_ANIMATION_STATE_1_YAWING : JUJU_ANIMATION_STATE_2_DESPAWNED);
|
||||
|
||||
if(s1){
|
||||
if (should_spawn) {
|
||||
position[1] += 250.0f;
|
||||
}
|
||||
if(i == arg1){
|
||||
((ActorLocal_Juju_2 *)&jujuPtr->local)->unk18 = 1;
|
||||
|
||||
if (i == count) {
|
||||
((ActorLocal_Juju_2 *) &jujuPtr->local)->unk18 = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void func_803891E8(s32 x, s32 y, s32 z, s32 yaw){
|
||||
void __chjuju_spawnJiggy(s32 x, s32 y, s32 z, s32 yaw) {
|
||||
f32 sp1C[3];
|
||||
sp1C[0] = x;
|
||||
sp1C[1] = y + 0x14;
|
||||
@@ -95,13 +110,13 @@ void func_803891E8(s32 x, s32 y, s32 z, s32 yaw){
|
||||
jiggy_spawn(JIGGY_4_MM_JUJU, sp1C);
|
||||
}
|
||||
|
||||
void func_80389244(s32 x, s32 y, s32 z, s32 yaw){
|
||||
__spawnQueue_add_4((GenFunction_4)func_803891E8, x, y, z, yaw);
|
||||
void __chjuju_solvePuzzle(s32 x, s32 y, s32 z, s32 yaw) {
|
||||
__spawnQueue_add_4((GenFunction_4) __chjuju_spawnJiggy, x, y, z, yaw);
|
||||
func_802BB3DC(0, 10.0f, 0.8f);
|
||||
gcpausemenu_80314AC8(1);
|
||||
}
|
||||
|
||||
void func_803892A8(ActorMarker **ptr){
|
||||
void func_803892A8(ActorMarker **ptr) {
|
||||
s32 i;
|
||||
s32 j;
|
||||
s32 s2;
|
||||
@@ -109,123 +124,141 @@ void func_803892A8(ActorMarker **ptr){
|
||||
Actor *actorPtr;
|
||||
ActorLocal_Juju_2 *jujuPtr;
|
||||
|
||||
for(i = 0; i < 4; i++){
|
||||
for (i = 0; i < 4; i++) {
|
||||
actorPtr = marker_getActor(ptr[i]);
|
||||
jujuPtr = (ActorLocal_Juju_2 *)&actorPtr->local;
|
||||
if(jujuPtr->unk0 != 2){
|
||||
jujuPtr->unk0 = 5;
|
||||
jujuPtr->unk4 = 0xC;
|
||||
func_8030E484(0x3f6);
|
||||
if(i == 3){
|
||||
jujuPtr = (ActorLocal_Juju_2 *) &actorPtr->local;
|
||||
|
||||
if (jujuPtr->animation_state != JUJU_ANIMATION_STATE_2_DESPAWNED) {
|
||||
jujuPtr->animation_state = JUJU_ANIMATION_STATE_5_DISAPPEARING;
|
||||
jujuPtr->animation_countdown = 12;
|
||||
sfxsource_playHighPriority(0x3f6);
|
||||
|
||||
if (i == 3) {
|
||||
gcpausemenu_80314AC8(0);
|
||||
timedFunc_set_4(1.25f, func_80389244, jujuPtr->unk8_x, jujuPtr->unk8_y, jujuPtr->unk8_z, actorPtr->yaw);
|
||||
timedFunc_set_4(1.25f, __chjuju_solvePuzzle, jujuPtr->next_pos_x, jujuPtr->next_pos_y, jujuPtr->next_pos_z, actorPtr->yaw);
|
||||
func_8025A6EC(COMUSIC_2D_PUZZLE_SOLVED_FANFARE, 0x6d60);
|
||||
}
|
||||
else{//L80389384
|
||||
else {//L80389384
|
||||
func_8025A6EC(COMUSIC_2B_DING_B, 0x7fff);
|
||||
}
|
||||
for(s2 = 3, j = i + 1; j < 4; s2+=5, j++){
|
||||
actorPtr = marker_getActor(ptr[j]);
|
||||
jujuPtr = (ActorLocal_Juju_2 *)&actorPtr->local;
|
||||
if(j == i+1){
|
||||
jujuPtr->unk18 = 1;
|
||||
}
|
||||
jujuPtr->unk4 = s2;
|
||||
jujuPtr->unk0 = 3;
|
||||
|
||||
for (s2 = 3, j = i + 1; j < 4; s2 += 5, j++) {
|
||||
actorPtr = marker_getActor(ptr[j]);
|
||||
jujuPtr = (ActorLocal_Juju_2 *) &actorPtr->local;
|
||||
|
||||
if (j == i + 1) {
|
||||
jujuPtr->unk18 = TRUE;
|
||||
}
|
||||
|
||||
jujuPtr->animation_countdown = s2;
|
||||
jujuPtr->animation_state = JUJU_ANIMATION_STATE_3_WAITING_TO_FALL;
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int func_8038941C(ActorMarker **ptr){
|
||||
bool __chjuju_isEveryJujuDespawned(ActorMarker **ptr) {
|
||||
s32 i;
|
||||
ActorLocal_Juju_2 *jujuPtr;
|
||||
|
||||
for(i = 0; i < 4; i++){
|
||||
jujuPtr = (ActorLocal_Juju_2 *)&marker_getActor(ptr[i])->local;
|
||||
if(jujuPtr->unk0 != 2)
|
||||
return 0;
|
||||
for (i = 0; i < 4; i++) {
|
||||
jujuPtr = (ActorLocal_Juju_2 *) &marker_getActor(ptr[i])->local;
|
||||
|
||||
if (jujuPtr->animation_state != JUJU_ANIMATION_STATE_2_DESPAWNED) {
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
return 1;
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
int func_8038948C(ActorMarker **ptr){
|
||||
bool __chjuju_isEveryJujuStable(ActorMarker **ptr) {
|
||||
s32 i;
|
||||
ActorLocal_Juju_2 *jujuPtr;
|
||||
|
||||
for(i = 0; i < 4; i++){
|
||||
jujuPtr = (ActorLocal_Juju_2 *)&marker_getActor(ptr[i])->local;
|
||||
if(jujuPtr->unk0 != 1 && jujuPtr->unk0 != 2)
|
||||
return 0;
|
||||
for (i = 0; i < 4; i++) {
|
||||
jujuPtr = (ActorLocal_Juju_2 *) &marker_getActor(ptr[i])->local;
|
||||
|
||||
if (jujuPtr->animation_state != JUJU_ANIMATION_STATE_1_YAWING && jujuPtr->animation_state != JUJU_ANIMATION_STATE_2_DESPAWNED) {
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
return 1;
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void func_80389514(ActorMarker **ptr){
|
||||
void __chjuju_updateCount(ActorMarker **ptr) {
|
||||
s32 i;
|
||||
MM_D_80389C90 = 0;
|
||||
for(i = 0; i < 4; i++){
|
||||
if(((ActorLocal_Juju_2 *)&marker_getActor(ptr[i])->local)->unk0 != 2){
|
||||
MM_D_80389C90++;
|
||||
};
|
||||
mm_juju_count = 0;
|
||||
|
||||
for (i = 0; i < 4; i++) {
|
||||
if (((ActorLocal_Juju_2 *) &marker_getActor(ptr[i])->local)->animation_state != JUJU_ANIMATION_STATE_2_DESPAWNED) {
|
||||
mm_juju_count++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void func_80389598(Actor *this){
|
||||
ActorLocal_Juju_2 *jujuPtr = (ActorLocal_Juju_2 *)&this->local;
|
||||
s32 sp38 = 0;
|
||||
f32 sp34;
|
||||
f32 sp28[3];
|
||||
|
||||
this->marker->propPtr->unk8_3 = (jujuPtr->unk0 != 2) && (jujuPtr->unk0 != 5);
|
||||
void chjuju_update(Actor *this) {
|
||||
ActorLocal_Juju_2 *jujuPtr = (ActorLocal_Juju_2 *) &this->local;
|
||||
s32 has_completed_full_turn = FALSE;
|
||||
f32 previous_yaw;
|
||||
f32 pos_offset[3];
|
||||
|
||||
switch(jujuPtr->unk0){
|
||||
case 1: //L80389624
|
||||
sp34 = this->yaw;
|
||||
this->yaw += ((0xb - MM_D_80389C90*2)*time_getDelta()*60.0f)/2;
|
||||
if(360.0f < this->yaw){
|
||||
sp38 = 1;
|
||||
this->marker->propPtr->unk8_3 = (jujuPtr->animation_state != JUJU_ANIMATION_STATE_2_DESPAWNED) && (jujuPtr->animation_state != JUJU_ANIMATION_STATE_5_DISAPPEARING);
|
||||
|
||||
switch (jujuPtr->animation_state) {
|
||||
case JUJU_ANIMATION_STATE_1_YAWING: //L80389624
|
||||
previous_yaw = this->yaw;
|
||||
this->yaw += ((11 - mm_juju_count * 2) * time_getDelta() * 60.0f) / 2;
|
||||
|
||||
if (360.0f < this->yaw) {
|
||||
has_completed_full_turn = TRUE;
|
||||
this->yaw -= 360.0f;
|
||||
}//L803896B4
|
||||
if(jujuPtr->unk18){
|
||||
if(sp38 || (sp34 < 180.0f && 180.0f <= this->yaw)){
|
||||
mapSpecificFlags_set(MM_SPECIFIC_FLAG_9_UNKNOWN, TRUE);
|
||||
|
||||
if (jujuPtr->unk18 && (has_completed_full_turn || (previous_yaw < 180.0f && 180.0f <= this->yaw))) {
|
||||
mapSpecificFlags_set(MM_SPECIFIC_FLAG_9_JUJU_HAS_HALF_TURNED, TRUE);
|
||||
}
|
||||
break;
|
||||
|
||||
case JUJU_ANIMATION_STATE_3_WAITING_TO_FALL: //L80389700
|
||||
if (--jujuPtr->animation_countdown == 0) {
|
||||
jujuPtr->animation_state = JUJU_ANIMATION_STATE_4_FALLING;
|
||||
jujuPtr->next_pos_y = this->position_y - 250.0f;
|
||||
}
|
||||
break;
|
||||
|
||||
case JUJU_ANIMATION_STATE_5_DISAPPEARING: //L80389738
|
||||
jujuPtr->animation_countdown--;
|
||||
jujuPtr->scale *= 0.85;
|
||||
|
||||
pos_offset[0] = 100.0f;
|
||||
pos_offset[1] = 0.0f;
|
||||
pos_offset[2] = 0.0f;
|
||||
ml_vec3f_yaw_rotate_copy(pos_offset, pos_offset, this->yaw + 90.0);
|
||||
|
||||
this->position_x += pos_offset[0];
|
||||
this->position_y += pos_offset[1];
|
||||
this->position_z += pos_offset[2];
|
||||
|
||||
if (!jujuPtr->animation_countdown) {
|
||||
jujuPtr->animation_state = JUJU_ANIMATION_STATE_2_DESPAWNED;
|
||||
}
|
||||
break;
|
||||
|
||||
case JUJU_ANIMATION_STATE_4_FALLING: //L803897F8
|
||||
this->position_y -= 25.0;
|
||||
|
||||
if (jujuPtr->next_pos_y == this->position_y) {
|
||||
jujuPtr->animation_state = JUJU_ANIMATION_STATE_1_YAWING;
|
||||
sfxsource_playHighPriority(SFX_3_DULL_CANNON_SHOT);
|
||||
func_802BB3DC(0, 10.0f, 0.8f);
|
||||
|
||||
if (jujuPtr->unk18) {
|
||||
func_80353064(this->position, 24.0f);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 3: //L80389700
|
||||
if(--jujuPtr->unk4 == 0){
|
||||
jujuPtr->unk0 = 4;
|
||||
jujuPtr->unk8_y = this->position_y - 250.0f;
|
||||
}
|
||||
break;
|
||||
case 5: //L80389738
|
||||
jujuPtr->unk4--;
|
||||
jujuPtr->unk14 *= 0.85;
|
||||
{sp28[0] = 100.0f;
|
||||
sp28[1] = 0.0f;
|
||||
sp28[2] = 0.0f;}
|
||||
ml_vec3f_yaw_rotate_copy(sp28, sp28, this->yaw + 90.0);
|
||||
this->position_x += sp28[0];
|
||||
this->position_y += sp28[1];
|
||||
this->position_z += sp28[2];
|
||||
if(!jujuPtr->unk4){
|
||||
jujuPtr->unk0 = 2;
|
||||
}
|
||||
break;
|
||||
case 4: //L803897F8
|
||||
this->position_y -= 25.0;
|
||||
if(jujuPtr->unk8_y == this->position_y){
|
||||
jujuPtr->unk0 = 1;
|
||||
func_8030E484(SFX_3_DULL_CANNON_SHOT);
|
||||
func_802BB3DC(0, 10.0f, 0.8f);
|
||||
if(jujuPtr->unk18)
|
||||
func_80353064(this->position, 24.0f);
|
||||
}
|
||||
break;
|
||||
|
||||
}//L8038987C
|
||||
}
|
||||
|
||||
|
@@ -4,161 +4,164 @@
|
||||
#include "variables.h"
|
||||
|
||||
/* extern functions */
|
||||
void func_80388DFC(ActorMarker *, s32);
|
||||
s32 func_80329784(Actor *);
|
||||
void __chjujuhitbox_initialize_all(ActorMarker *, s32);
|
||||
s32 func_80329784(Actor *);
|
||||
void func_80353580(ActorMarker *);
|
||||
|
||||
typedef struct juju_hitbox_s{
|
||||
u8 pad0[0x4];
|
||||
s32 unk4;
|
||||
ActorMarker *unk8[4];
|
||||
f32 unk18;
|
||||
}ActorLocal_JujuHitbox;
|
||||
typedef struct juju_hitbox_s {
|
||||
u8 pad0[0x4];
|
||||
s32 unk4;
|
||||
ActorMarker *jujus[4];
|
||||
f32 unk18;
|
||||
} ActorLocal_JujuHitbox;
|
||||
|
||||
/* public functions */
|
||||
void func_80388E20(Actor *this);
|
||||
Actor* func_80388DC0(ActorMarker *, Gfx **, Mtx**, Vtx **);
|
||||
void func_80388DE8(Actor* this, s32 slave_id, Actor *slavePtr);
|
||||
void chjujuhitbox_update(Actor *this);
|
||||
Actor *chjujuhitbox_draw(ActorMarker *, Gfx **, Mtx **, Vtx **);
|
||||
void chjujuhitbox_setJuju(Actor *this, s32 slave_id, Actor *slavePtr);
|
||||
|
||||
/* .data */
|
||||
ActorInfo chjujuhitboxInfo = { MARKER_67_JUJU, ACTOR_11_JUJU_CTRL, 0,
|
||||
ActorInfo chjujuhitboxInfo = {
|
||||
MARKER_67_JUJU, ACTOR_11_JUJU_CTRL, 0,
|
||||
3, NULL,
|
||||
func_80388E20, func_80326224, func_80388DC0,
|
||||
chjujuhitbox_update, func_80326224, chjujuhitbox_draw,
|
||||
0, 0, 0.0f, 0
|
||||
};
|
||||
|
||||
int func_80388B30(Actor *this, float arg1){
|
||||
/* code */
|
||||
bool func_80388B30(Actor *this, float arg1) {
|
||||
f32 yaw;
|
||||
|
||||
yaw = this->yaw - func_80329784(this);
|
||||
|
||||
if(180.0f <= yaw){
|
||||
if (180.0f <= yaw) {
|
||||
yaw -= 360.0f;
|
||||
}
|
||||
else if(yaw < -180.0f){
|
||||
else if (yaw < -180.0f) {
|
||||
yaw += 360.0f;
|
||||
}
|
||||
|
||||
if (yaw < 0.0f){
|
||||
if (yaw < 0.0f) {
|
||||
yaw = -yaw;
|
||||
}
|
||||
|
||||
if (yaw < arg1){
|
||||
return 1;
|
||||
if (yaw < arg1) {
|
||||
return TRUE;
|
||||
}
|
||||
return 0;
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
void func_80388BEC(NodeProp *node, ActorMarker *marker){
|
||||
void func_80388BEC(NodeProp *node, ActorMarker *marker) {
|
||||
f32 distance_to_closest_actor;
|
||||
Actor *closest_actor;
|
||||
Actor *temp_v0;
|
||||
f32 position[3];
|
||||
|
||||
|
||||
position[0] = (f32)node->x;
|
||||
position[1] = (f32)node->y;
|
||||
position[2] = (f32)node->z;
|
||||
position[0] = (f32) node->x;
|
||||
position[1] = (f32) node->y;
|
||||
position[2] = (f32) node->z;
|
||||
|
||||
closest_actor = actorArray_findClosestActorFromActorId(position, 0x11, -1, &distance_to_closest_actor);
|
||||
closest_actor = actorArray_findClosestActorFromActorId(position, ACTOR_11_JUJU_CTRL, -1, &distance_to_closest_actor);
|
||||
|
||||
if( closest_actor != NULL
|
||||
&& !( distance_to_closest_actor > 500.0f )
|
||||
&& (closest_actor->state ==3)
|
||||
){
|
||||
temp_v0 = marker_getActor(((ActorLocal_JujuHitbox *)&closest_actor->local)->unk8[((ActorLocal_JujuHitbox *)&closest_actor->local)->unk4]);
|
||||
if (closest_actor != NULL
|
||||
&& !(distance_to_closest_actor > 500.0f)
|
||||
&& (closest_actor->state == 3)
|
||||
) {
|
||||
temp_v0 = marker_getActor(((ActorLocal_JujuHitbox *) &closest_actor->local)->jujus[((ActorLocal_JujuHitbox *) &closest_actor->local)->unk4]);
|
||||
|
||||
if(temp_v0 != NULL){
|
||||
if(func_80388B30(temp_v0, 90.0f)){
|
||||
if (temp_v0 != NULL) {
|
||||
if (func_80388B30(temp_v0, 90.0f)) {
|
||||
closest_actor->state = 1;
|
||||
((ActorLocal_JujuHitbox *)&closest_actor->local)->unk4++;
|
||||
func_803892A8(((ActorLocal_JujuHitbox *)&closest_actor->local)->unk8);
|
||||
((ActorLocal_JujuHitbox *) &closest_actor->local)->unk4++;
|
||||
func_803892A8(((ActorLocal_JujuHitbox *) &closest_actor->local)->jujus);
|
||||
func_80353580(marker);
|
||||
__spawnQueue_add_4((GenFunction_4)func_802C4140, 0x58, *(s32 *)&position[0], *(s32 *)&position[1], *(s32 *)&position[2]);
|
||||
__spawnQueue_add_4((GenFunction_4) func_802C4140, 0x58, *(s32 * ) & position[0], *(s32 * ) & position[1], *(s32 * ) & position[2]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void func_80388D14(Actor *this){
|
||||
void __chjujuhitbox_playRubbingSfx(Actor *this) {
|
||||
ActorLocal_JujuHitbox *jujuCtlPtr;
|
||||
|
||||
jujuCtlPtr = (ActorLocal_JujuHitbox *)&this->local;
|
||||
func_8030E878(0x3F6, jujuCtlPtr->unk18, 20000, this->position, 300.0f, 2000.0f);
|
||||
jujuCtlPtr = (ActorLocal_JujuHitbox *) &this->local;
|
||||
func_8030E878(SFX_3F6_RUBBING, jujuCtlPtr->unk18, 20000, this->position, 300.0f, 2000.0f);
|
||||
}
|
||||
|
||||
void func_80388D60(Actor *this){
|
||||
void func_80388D60(Actor *this) {
|
||||
ActorLocal_JujuHitbox *jujuCtlPtr;
|
||||
|
||||
jujuCtlPtr = (ActorLocal_JujuHitbox *)&this->local;
|
||||
if(!func_8038941C(jujuCtlPtr->unk8)){
|
||||
jujuCtlPtr = (ActorLocal_JujuHitbox *) &this->local;
|
||||
|
||||
if (!__chjuju_isEveryJujuDespawned(jujuCtlPtr->jujus)) {
|
||||
jujuCtlPtr->unk18 *= 1.05;
|
||||
}
|
||||
|
||||
this->state = 3;
|
||||
}
|
||||
|
||||
Actor* func_80388DC0(ActorMarker *this, Gfx **dl, Mtx**mPtr, Vtx **arg3){
|
||||
Actor *chjujuhitbox_draw(ActorMarker *this, Gfx **dl, Mtx **mPtr, Vtx **arg3) {
|
||||
return marker_getActor(this);
|
||||
}
|
||||
|
||||
void func_80388DE8(Actor *this, s32 child_id, Actor *childPtr){
|
||||
void chjujuhitbox_setJuju(Actor *this, s32 child_id, Actor *childPtr) {
|
||||
ActorLocal_JujuHitbox *jujuCtlPtr;
|
||||
|
||||
jujuCtlPtr = (ActorLocal_JujuHitbox *)&this->local;
|
||||
jujuCtlPtr->unk8[child_id] = childPtr->marker;
|
||||
jujuCtlPtr = (ActorLocal_JujuHitbox *) &this->local;
|
||||
jujuCtlPtr->jujus[child_id] = childPtr->marker;
|
||||
}
|
||||
|
||||
void func_80388DFC(ActorMarker *arg0, s32 arg1){
|
||||
func_803890A0(arg0, arg1);
|
||||
void __chjujuhitbox_initialize_all(ActorMarker *marker, s32 count) {
|
||||
__chjuju_initialize_all(marker, count);
|
||||
|
||||
if(arg0 && arg1); //for args to save
|
||||
if (marker && count); //for args to save
|
||||
}
|
||||
|
||||
void func_80388E20(Actor *this){
|
||||
void chjujuhitbox_update(Actor *this) {
|
||||
ActorLocal_JujuHitbox *jujuCtlPtr;
|
||||
s32 i;
|
||||
|
||||
jujuCtlPtr = (ActorLocal_JujuHitbox *)&this->local;
|
||||
if(!this->initialized){
|
||||
jujuCtlPtr = (ActorLocal_JujuHitbox *) &this->local;
|
||||
|
||||
if (!this->initialized) {
|
||||
this->initialized = TRUE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
jujuCtlPtr->unk18 = 0.5f;
|
||||
}
|
||||
if(!this->volatile_initialized){
|
||||
|
||||
if (!this->volatile_initialized) {
|
||||
this->volatile_initialized = TRUE;
|
||||
__spawnQueue_add_2((GenFunction_2)func_80388DFC,this->marker, jujuCtlPtr->unk4);
|
||||
func_80388D14(this);
|
||||
}else{
|
||||
if( func_80329530(this, 0xfa)
|
||||
&& !func_80329530(this, 0x50)
|
||||
&& !func_8028ECAC()
|
||||
){
|
||||
if( !this->is_first_encounter ){
|
||||
if(gcdialog_showText(ASSET_B44_TEXT_JUJU_MEET, 0, 0, 0, NULL, NULL)){
|
||||
this->is_first_encounter = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
__spawnQueue_add_2((GenFunction_2) __chjujuhitbox_initialize_all, this->marker, jujuCtlPtr->unk4);
|
||||
__chjujuhitbox_playRubbingSfx(this);
|
||||
return;
|
||||
}
|
||||
|
||||
if(this->state == 1){
|
||||
if(func_8038948C(jujuCtlPtr->unk8)){
|
||||
func_80388D60(this);
|
||||
}
|
||||
if(func_8038941C(jujuCtlPtr->unk8)){
|
||||
marker_despawn(this->marker);
|
||||
for(i = 0; i < 4; i++){
|
||||
marker_despawn(jujuCtlPtr->unk8[i]);
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
else{
|
||||
func_80389514(jujuCtlPtr->unk8);
|
||||
}
|
||||
|
||||
if (mapSpecificFlags_get(MM_SPECIFIC_FLAG_9_UNKNOWN)) {
|
||||
func_80388D14(this);
|
||||
mapSpecificFlags_set(MM_SPECIFIC_FLAG_9_UNKNOWN, FALSE);
|
||||
if (func_80329530(this, 0xfa) && !func_80329530(this, 0x50) && !func_8028ECAC()) {
|
||||
if (!this->has_met_before && gcdialog_showText(ASSET_B44_TEXT_JUJU_MEET, 0, 0, 0, NULL, NULL)) {
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
if (this->state == 1) {
|
||||
if (__chjuju_isEveryJujuStable(jujuCtlPtr->jujus)) {
|
||||
func_80388D60(this);
|
||||
}
|
||||
|
||||
if (__chjuju_isEveryJujuDespawned(jujuCtlPtr->jujus)) {
|
||||
marker_despawn(this->marker);
|
||||
for (i = 0; i < 4; i++) {
|
||||
marker_despawn(jujuCtlPtr->jujus[i]);
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
else {
|
||||
__chjuju_updateCount(jujuCtlPtr->jujus);
|
||||
}
|
||||
|
||||
if (mapSpecificFlags_get(MM_SPECIFIC_FLAG_9_JUJU_HAS_HALF_TURNED)) {
|
||||
__chjujuhitbox_playRubbingSfx(this);
|
||||
mapSpecificFlags_set(MM_SPECIFIC_FLAG_9_JUJU_HAS_HALF_TURNED, FALSE);
|
||||
}
|
||||
}
|
||||
|
@@ -48,7 +48,7 @@ void __chlmonkey_updateBringOrange(Actor **this_ptr) {
|
||||
player_throwCarriedObject()) {
|
||||
|
||||
func_8028FA34(0xc6, *this_ptr);
|
||||
(*this_ptr)->is_first_encounter = TRUE;
|
||||
(*this_ptr)->has_met_before = TRUE;
|
||||
timed_setStaticCameraToNode(1.2f, 0xF);
|
||||
func_80324E38(1.2f, 3);
|
||||
}
|
||||
@@ -120,10 +120,10 @@ void chlmonkey_update(Actor *this) {
|
||||
if (func_80329530(this, 345) &&
|
||||
!func_80329530(this, 150) &&
|
||||
!item_getCount(ITEM_19_ORANGE) &&
|
||||
!this->is_first_encounter) {
|
||||
!this->has_met_before) {
|
||||
|
||||
gcdialog_showText(ASSET_B3F_DIALOG_CHIMPY_MEET, 0xe, this->position, NULL, NULL, NULL);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}//L80388774
|
||||
|
||||
actor_loopAnimation(this);
|
||||
|
@@ -42,11 +42,11 @@ void __chnapper_setState(Actor *this, s32 next_state){
|
||||
if(next_state == 3){
|
||||
skeletalAnim_set(this->unk148, ASSET_A5_ANIM_NAPPER_WALK, 0.2f, 1.5f);
|
||||
skeletalAnim_setBehavior(this->unk148, SKELETAL_ANIM_2_ONCE);
|
||||
func_8030E484(SFX_41_MUMBO_ERGHHH);
|
||||
sfxsource_playHighPriority(SFX_41_MUMBO_ERGHHH);
|
||||
}
|
||||
|
||||
if(next_state == 4){
|
||||
func_8030E484(SFX_C_TAKING_FLIGHT_LIFTOFF);
|
||||
sfxsource_playHighPriority(SFX_C_TAKING_FLIGHT_LIFTOFF);
|
||||
func_803895B0(0);
|
||||
}
|
||||
|
||||
@@ -62,9 +62,9 @@ void __chnapper_setState(Actor *this, s32 next_state){
|
||||
void func_80386ACC(ActorMarker *this_marker, ActorMarker *other_marker){
|
||||
Actor *this = marker_getActor(this_marker);
|
||||
|
||||
if(!this->is_first_encounter){
|
||||
if(!this->has_met_before){
|
||||
if(gcdialog_showText(0xad8, 0, NULL, NULL, NULL, NULL)){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -42,7 +42,7 @@ void __chAnchorCtrl_setState(Actor *this, s32 new_state){
|
||||
func_80324E38(0.0f, 3);
|
||||
timedFunc_set_0(1.0f, func_8038C000);
|
||||
timedFunc_set_2(1.0f, (GenFunction_2)mapSpecificFlags_set, 8, TRUE);
|
||||
timed_playSfx(2.1f, SFX_3F6_UNKNOWN, 0.6f, 32700);
|
||||
timed_playSfx(2.1f, SFX_3F6_RUBBING, 0.6f, 32700);
|
||||
timedFunc_set_2(2.7f, (GenFunction_2)mapSpecificFlags_set, 4, TRUE);
|
||||
timedFunc_set_0(3.0f, func_8038C058);
|
||||
func_80324DBC(3.0f, 0xb9C, 7, NULL, this->marker, __chAnchorCtrl_spawnJiggy, NULL);
|
||||
|
@@ -85,12 +85,12 @@ void func_8038B900(Actor *this){
|
||||
}
|
||||
|
||||
if(this->state == 1){
|
||||
if( !this->is_first_encounter
|
||||
if( !this->has_met_before
|
||||
&& func_80329530(this, 0x258)
|
||||
&& !func_8028ECAC()
|
||||
){
|
||||
gcdialog_showText(0xb9b, 4, 0, 0, 0, 0);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -223,7 +223,7 @@ void func_80387DCC(ActorMarker *marker, ActorMarker *other_marker){
|
||||
Actor *func_80387DF4(ActorMarker *marker, Gfx **gdl, Mtx **mptr, Vtx **arg3){
|
||||
Actor *actor = marker_getActor(marker);
|
||||
|
||||
if(actor->is_first_encounter)
|
||||
if(actor->has_met_before)
|
||||
func_8033A470(3, 7);
|
||||
else
|
||||
func_8033A45C(3, 0);
|
||||
@@ -320,7 +320,7 @@ void func_80388080(Actor *this){
|
||||
this->velocity_x = temp_velX;
|
||||
this->velocity_y = (local->unkC == 3) ? 90.0f : 70.0f;
|
||||
this->velocity_z = temp_velZ;
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
this->unk138_23 = 0;
|
||||
this->unk38_0 = 0;
|
||||
this->initialized = TRUE;
|
||||
@@ -483,7 +483,7 @@ void func_80388080(Actor *this){
|
||||
sp54[2] = this->position_z;
|
||||
if(local->unkC == 1)
|
||||
sp54[1] += 150.0f;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
func_80387A80(partEmitMgr_newEmitter(3), sp54, 3, (local->unkC == 1)? 0x4f0: 0x4f1);
|
||||
}//L80388CC4
|
||||
|
||||
|
@@ -233,7 +233,7 @@ void func_803892C8(ActorMarker *marker, enum asset_e text_id, s32 arg2){
|
||||
break;
|
||||
|
||||
case ASSET_E1D_TEXT_BOTTLES_TUTORIAL_OFFER_WAIT: /* 2FFC 803893EC 920B0138 */
|
||||
actor->is_first_encounter = FALSE;
|
||||
actor->has_met_before = FALSE;
|
||||
actor->lifetime_value = 0.0f;
|
||||
break;
|
||||
|
||||
@@ -572,9 +572,9 @@ void chsmmole_Update(Actor * this){
|
||||
chsmmole_skipIntroTutorial(); //give all SM moves
|
||||
}
|
||||
this->unk38_0 = 0;
|
||||
}else if(!this->is_first_encounter && 5.0 < this->lifetime_value){
|
||||
}else if(!this->has_met_before && 5.0 < this->lifetime_value){
|
||||
gcdialog_showText(0xe1d, 0x86, this->position, this->marker, func_803892C8, NULL);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
@@ -117,7 +117,7 @@ void func_80387774(Actor **this_ptr){
|
||||
&& player_throwCarriedObject()
|
||||
){
|
||||
func_8028FA34(!mapSpecificFlags_get(0)? 0x149 : 0x14a, *this_ptr);
|
||||
(*this_ptr)->is_first_encounter = TRUE;
|
||||
(*this_ptr)->has_met_before = TRUE;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -146,11 +146,11 @@ void func_803878CC(Actor * this){
|
||||
}//L80387970
|
||||
|
||||
if(func_80329530(this, 250) && !func_80329530(this, 80)
|
||||
&& !this->is_first_encounter
|
||||
&& !this->has_met_before
|
||||
&& item_getCount(ITEM_18_GOLD_BULLIONS) == 0
|
||||
){
|
||||
gcdialog_showText(ASSET_A0B_TEXT_UNKNOWN, 0xe, this->position, this->marker, func_80387520, NULL);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
subaddie_set_state_forward(this, 3);
|
||||
}
|
||||
|
||||
@@ -162,7 +162,7 @@ void func_803878CC(Actor * this){
|
||||
}
|
||||
|
||||
this->unk138_23 = TRUE;
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
|
||||
}//L80387A54
|
||||
|
||||
|
@@ -54,12 +54,12 @@ void chLeaky_update(Actor *this) {
|
||||
}
|
||||
}
|
||||
if( this->state == 1
|
||||
&& !this->is_first_encounter
|
||||
&& !this->has_met_before
|
||||
&& func_80329530(this, 250) && !func_80329530(this, 160)
|
||||
&& !func_8028ECAC()
|
||||
&& gcdialog_showText(0xA1A, 0, NULL, NULL, NULL, NULL)
|
||||
){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
if (func_803114B0() == 0) {
|
||||
if (actor_animationIsAt(this, 0.83f)) {
|
||||
|
@@ -75,7 +75,7 @@ void func_80389600(Actor *this){
|
||||
s32 tmp_v1;
|
||||
int i;
|
||||
|
||||
if( !this->is_first_encounter
|
||||
if( !this->has_met_before
|
||||
&& this->unkF4_8 == 0xA
|
||||
&& !jiggyscore_isCollected(JIGGY_13_TTC_LOCKUP)
|
||||
&& func_80329530(this, 320)
|
||||
@@ -83,7 +83,7 @@ void func_80389600(Actor *this){
|
||||
&& !func_8028ECAC()
|
||||
&& gcdialog_showText(0xA15, 0, NULL, NULL, NULL, NULL)
|
||||
){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}//L803896AC
|
||||
|
||||
if(!this->volatile_initialized){
|
||||
|
@@ -167,7 +167,7 @@ void func_80388344(ActorMarker * this_marker, ActorMarker *other_marker){
|
||||
if(other_marker->id == 1){
|
||||
this = marker_getActor(this_marker);
|
||||
if( !mapSpecificFlags_get(7)
|
||||
&& this->is_first_encounter
|
||||
&& this->has_met_before
|
||||
&& gcdialog_showText(0xa0f, 0, NULL, NULL, NULL, NULL)
|
||||
){
|
||||
mapSpecificFlags_set(7, TRUE);
|
||||
@@ -178,7 +178,7 @@ void func_80388344(ActorMarker * this_marker, ActorMarker *other_marker){
|
||||
void func_803883C8(ActorMarker * this_marker, ActorMarker *other_marker){
|
||||
Actor *this = marker_getActor(this_marker);
|
||||
if( !this->unk138_23
|
||||
&& this->is_first_encounter
|
||||
&& this->has_met_before
|
||||
&& gcdialog_showText(0xa11, 0, NULL, NULL, NULL, NULL)
|
||||
){
|
||||
this->unk138_23 = TRUE;
|
||||
@@ -229,13 +229,13 @@ void func_80388434(Actor *this){
|
||||
}//L8038860C
|
||||
if(func_8038812C(this)){
|
||||
temp_v0 = func_8028ECAC();
|
||||
if( !this->is_first_encounter
|
||||
if( !this->has_met_before
|
||||
&& temp_v0 != 1
|
||||
&& temp_v0 != 10
|
||||
){
|
||||
subaddie_set_state_with_direction(this, 5, 0.01f, 1);
|
||||
if(gcdialog_showText(0xa0e, 0xf, this->position, this->marker, TTC_func_80387FB0, NULL)){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
comusic_8025AB44(COMUSIC_12_TTC_NIPPER, 5000, 300);
|
||||
ncStaticCamera_setToNode(11);
|
||||
|
@@ -321,7 +321,7 @@ void __baMarker_resolveCollision(Prop *other_prop){
|
||||
|
||||
case 0x28: //L8028BF74
|
||||
if( plyr_hitbox_type == HITBOX_6_WONDERWING){
|
||||
func_8030E484(SFX_20_METAL_CLANK_1);
|
||||
sfxsource_playHighPriority(SFX_20_METAL_CLANK_1);
|
||||
}
|
||||
else{
|
||||
func_8030E6D4(SFX_65_METALLIC_SCRATCH);
|
||||
|
@@ -513,7 +513,7 @@ void func_802A4664(void){
|
||||
func_80299E90();
|
||||
next_state = bs_getNextState();
|
||||
if(next_state == BS_20_LANDING || next_state == BS_24_FLY || next_state == BS_2D_SWIM_IDLE){
|
||||
func_8030E484(SFX_3EA_UNKNOWN);
|
||||
sfxsource_playHighPriority(SFX_3EA_UNKNOWN);
|
||||
}
|
||||
func_802A34C8();
|
||||
func_8029E070(0);
|
||||
|
@@ -58,7 +58,7 @@ int bslongleg_inSet(s32 move_indx){
|
||||
void func_802A531C(void){
|
||||
func_80299650(stateTimer_getPrevious(STATE_TIMER_2_LONGLEG), stateTimer_get(STATE_TIMER_2_LONGLEG));
|
||||
if(stateTimer_isAt(STATE_TIMER_2_LONGLEG, 0.01f))
|
||||
func_8030E484(SFX_3EB_UNKNOWN);
|
||||
sfxsource_playHighPriority(SFX_3EB_UNKNOWN);
|
||||
}
|
||||
|
||||
void func_802A5374(void){
|
||||
|
@@ -145,7 +145,7 @@ void bsbshock_init(void){
|
||||
baphysics_set_horizontal_velocity(yaw_getIdeal(), baphysics_get_target_horizontal_velocity());
|
||||
baphysics_set_vertical_velocity(D_80364A70);
|
||||
baphysics_set_gravity(D_80364A74);
|
||||
func_8030E484(SFX_E_SHOCKSPRING_BOING);
|
||||
sfxsource_playHighPriority(SFX_E_SHOCKSPRING_BOING);
|
||||
func_8029E064(1);
|
||||
func_8029E070(1);
|
||||
ability_use(9);
|
||||
@@ -162,7 +162,7 @@ void bsbshock_update(void){
|
||||
func_802B6FA8();
|
||||
baphysics_get_velocity(sp20);
|
||||
if(animctrl_isAt(aCtrl, 0.7f))
|
||||
func_8030E484(SFX_53_BANJO_HUIII);
|
||||
sfxsource_playHighPriority(SFX_53_BANJO_HUIII);
|
||||
|
||||
if(button_released(BUTTON_A) && 0.0f < sp20[1])
|
||||
baphysics_reset_gravity();
|
||||
|
@@ -123,7 +123,7 @@ void func_802A8AD8(void){
|
||||
if(func_8029DFE0()){
|
||||
func_8029E0DC(0);
|
||||
if(miscFlag_isFalse(MISC_FLAG_14_LOSE_BOGGY_RACE))
|
||||
func_8030E484(0x3eb);
|
||||
sfxsource_playHighPriority(0x3eb);
|
||||
func_803219F4(1);
|
||||
}
|
||||
}else{
|
||||
@@ -365,7 +365,7 @@ void bsbtrot_jump_init(void){
|
||||
baphysics_set_horizontal_velocity(yaw_getIdeal(), baphysics_get_target_horizontal_velocity());
|
||||
baphysics_set_vertical_velocity(D_80364ABC);
|
||||
baphysics_set_gravity(D_80364AC0);
|
||||
func_8030E484(SFX_48_KAZOOIE_RUUH);
|
||||
sfxsource_playHighPriority(SFX_48_KAZOOIE_RUUH);
|
||||
D_8037D3A4 = 0;
|
||||
}
|
||||
|
||||
|
@@ -581,7 +581,7 @@ void bscroc_eat_bad_update(void){
|
||||
}
|
||||
|
||||
if(animctrl_isAt(aCtrl, 0.6671f)){
|
||||
func_8030E484(SFX_C6_SHAKING_MOUTH);
|
||||
sfxsource_playHighPriority(SFX_C6_SHAKING_MOUTH);
|
||||
}
|
||||
|
||||
if(animctrl_isStopped(aCtrl)){
|
||||
|
@@ -71,7 +71,7 @@ void bsjig_jiggy_update(void){
|
||||
}
|
||||
|
||||
if(animctrl_isAt(aCtrl, 0.94f))
|
||||
func_8030E484(0x3ea);
|
||||
sfxsource_playHighPriority(0x3ea);
|
||||
|
||||
if(animctrl_isStopped(aCtrl)){
|
||||
if(D_8037D4B1)
|
||||
|
@@ -121,7 +121,7 @@ void func_802C6240(Actor *this){
|
||||
this->marker->dieFunc = func_802C61C0;
|
||||
this->marker->collisionFunc = func_802C60AC;
|
||||
this->marker->collision2Func = func_802C6150;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
this->unk16C_0 = 1;
|
||||
this->initialized = TRUE;
|
||||
return;
|
||||
@@ -265,7 +265,7 @@ void func_802C6240(Actor *this){
|
||||
subaddie_set_state_with_direction(this, 1, 0.65f, 1);
|
||||
func_8030DA44(this->unk44_31);
|
||||
this->unk44_31 = 0;
|
||||
func_8030E484(SFX_19_BANJO_LANDING_08);
|
||||
sfxsource_playHighPriority(SFX_19_BANJO_LANDING_08);
|
||||
}
|
||||
}//L802C6B1C
|
||||
break;
|
||||
|
@@ -320,7 +320,7 @@ void chBottlesBonusCursor_update(Actor *this) {
|
||||
held_piece = &D_8037E248[D_8037E5C0.unk0];
|
||||
held_piece->state = 2;
|
||||
chBottlesBonusCursor_func_802DF928(D_8037E5C0.unk0);
|
||||
func_8030E484(SFX_112_TINKER_ATTENTION);
|
||||
sfxsource_playHighPriority(SFX_112_TINKER_ATTENTION);
|
||||
subaddie_set_state_with_direction(this, 2, 0.0f, 1);
|
||||
}
|
||||
}
|
||||
|
@@ -239,7 +239,7 @@ void chCrab_update(Actor *this) {
|
||||
marker_setCollisionScripts(this->marker, __chCrab_touch, __chCrab_ow, __chCrab_die);
|
||||
func_803300C0(this->marker, &__chCrab_802CB76C);
|
||||
this->unk124_0 = this->unk138_31 = FALSE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
this->volatile_initialized = TRUE;
|
||||
animctrl_setTransitionDuration(this->animctrl, 0.25f);
|
||||
if (map_get() == MAP_A_TTC_SANDCASTLE) {
|
||||
@@ -273,7 +273,7 @@ void chCrab_update(Actor *this) {
|
||||
gcdialog_showText(ASSET_D32_DIALOG_MUTANT_CRAB_MEET, 0xF, this->position, NULL, __chCrab_mutantTextCallback, NULL);
|
||||
mapSpecificFlags_set(0, TRUE);
|
||||
levelSpecificFlags_set(0xE, TRUE);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
if (map_get() == MAP_A_TTC_SANDCASTLE) {
|
||||
@@ -292,8 +292,8 @@ void chCrab_update(Actor *this) {
|
||||
}
|
||||
if (levelSpecificFlags_get(0xE)) {
|
||||
if ((this->state != 8) && (this->state != 9)) {
|
||||
subaddie_set_state_with_direction(this, (this->is_first_encounter) ? 8 : 9, 0.0f, 1);
|
||||
this->is_first_encounter = FALSE;
|
||||
subaddie_set_state_with_direction(this, (this->has_met_before) ? 8 : 9, 0.0f, 1);
|
||||
this->has_met_before = FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -454,7 +454,7 @@ void func_802C4C14(Actor *this){
|
||||
break;
|
||||
case 2://L802C5364
|
||||
timedFunc_set_2(0.15f, (GenFunction_2)sfxsource_play, SFX_32_BANJO_EGHEE, 28000);
|
||||
sfxsource_play(SFX_3F6_UNKNOWN, 28000);
|
||||
sfxsource_play(SFX_3F6_RUBBING, 28000);
|
||||
func_8030E540(SFX_8F_SNOWBALL_FLYING);
|
||||
break;
|
||||
}//L802C5394
|
||||
@@ -462,7 +462,7 @@ void func_802C4C14(Actor *this){
|
||||
levelSpecificFlags_set(sp84 + 0x35, 1);
|
||||
}
|
||||
else{//L802C53B4
|
||||
func_8030E484(SFX_3EA_UNKNOWN);
|
||||
sfxsource_playHighPriority(SFX_3EA_UNKNOWN);
|
||||
subaddie_set_state(this, 3);
|
||||
}
|
||||
}else{//L802C53D0
|
||||
|
@@ -163,9 +163,9 @@ void chmole_healthRefill(ActorMarker *marker, enum asset_e arg1, s32 arg2){
|
||||
gcdialog_showText(chmole_learnedAllGameAbilities()? 0xa87 : chmole_learnedAllLevelAbilitiesDialog(), 7, 0, actor->marker, chmole_healthRefill, NULL);
|
||||
}
|
||||
else{//L802D97BC
|
||||
if(actor->is_first_encounter){
|
||||
if(actor->has_met_before){
|
||||
func_80347A14(1);
|
||||
actor->is_first_encounter = FALSE;
|
||||
actor->has_met_before = FALSE;
|
||||
}
|
||||
timed_exitStaticCamera(0.0f);
|
||||
if(actor->state == 5){
|
||||
@@ -229,7 +229,7 @@ int chmole_learnAbility(Actor *this){
|
||||
// New Ability: Learn Dialog & Misc Actions
|
||||
else{
|
||||
func_80347A14(0);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
sp2C = moleTable[this->unkF4_8-9].learn_text;
|
||||
ability_unlock(moleTable[this->unkF4_8-9].ability);
|
||||
switch(moleTable[this->unkF4_8-9].ability){
|
||||
|
@@ -79,12 +79,12 @@ static void __chsnacker_start_dialog(Actor *this) {
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
if (level_get() == LEVEL_2_TREASURE_TROVE_COVE) {
|
||||
text_index = mapSpecificFlags_getN(8, 3);
|
||||
if( !this->is_first_encounter ) {
|
||||
if( !this->has_met_before ) {
|
||||
if(text_index < 4) {
|
||||
if(gcdialog_showText(0xA1B + text_index, 0, NULL, NULL, NULL, NULL)){
|
||||
text_index++;
|
||||
mapSpecificFlags_setN(8, text_index, 3);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -146,7 +146,7 @@ void __chTermite_testCallback(ActorMarker *caller, enum asset_e text_id, s32 arg
|
||||
Actor *this;
|
||||
|
||||
this = marker_getActor(caller);
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
levelSpecificFlags_set(0xd, FALSE);
|
||||
}
|
||||
|
||||
@@ -159,7 +159,7 @@ void chTermite_update(Actor *this) {
|
||||
if (!this->volatile_initialized) {
|
||||
marker_setCollisionScripts(this->marker, NULL, __chTermite_ow, __chTermite_die);
|
||||
this->unk124_0 = this->unk138_31 = FALSE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
this->unk16C_0 = TRUE;
|
||||
this->volatile_initialized = TRUE;
|
||||
}
|
||||
@@ -173,7 +173,7 @@ void chTermite_update(Actor *this) {
|
||||
gcdialog_showText(ASSET_B43_DIALOG_TERMITE_MEET_AS_BEAR, 7, this->position, this->marker, __chTermite_testCallback, NULL);
|
||||
mapSpecificFlags_set(0, TRUE);
|
||||
levelSpecificFlags_set(0xD, TRUE);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
|
||||
if( func_80329530(this, 300)
|
||||
|
@@ -160,7 +160,7 @@ static void __chMumbo_textCallback(ActorMarker *caller, enum asset_e text_id, s3
|
||||
break;
|
||||
|
||||
case ASSET_DAF_DIALOG_MUMBO_TREX_MISTAKE: //L802D1A98
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
if(this->unk38_31 != 0){
|
||||
func_8025A6EC(COMUSIC_2B_DING_B, 28000);
|
||||
item_adjustByDiffWithHud(ITEM_1C_MUMBO_TOKEN, -this->unk38_31);
|
||||
@@ -249,7 +249,7 @@ void chMumbo_update(Actor *this) {
|
||||
}
|
||||
this->unk38_0 = (item_getCount(ITEM_1C_MUMBO_TOKEN) >= this->unk38_31);
|
||||
this->unk10_12 = 0;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
this->volatile_initialized = TRUE;
|
||||
}
|
||||
|
||||
@@ -273,7 +273,7 @@ void chMumbo_update(Actor *this) {
|
||||
|
||||
case 2: //L802D1F90
|
||||
if (actor_animationIsAt(this, 0.25f) != 0) {
|
||||
func_8030E484(0x41);
|
||||
sfxsource_playHighPriority(0x41);
|
||||
}
|
||||
actor_playAnimationOnce(this);
|
||||
if (actor_animationIsAt(this, 0.999f)) {
|
||||
@@ -333,7 +333,7 @@ void chMumbo_update(Actor *this) {
|
||||
) {
|
||||
gcdialog_showText(ASSET_DAE_DIALOG_MUMBO_TREX_START, 6, NULL, this->marker, __chMumbo_textCallback, NULL);
|
||||
fileProgressFlag_set(FILEPROG_BA_HAS_SEEN_TREX_TEXT, 1);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
subaddie_set_state(this, 3);
|
||||
} else if (
|
||||
sp44
|
||||
@@ -385,7 +385,7 @@ void chMumbo_update(Actor *this) {
|
||||
}
|
||||
if (actor_animationIsAt(this, 0.01f)) {
|
||||
|
||||
if ( this->is_first_encounter
|
||||
if ( this->has_met_before
|
||||
|| (this->unk10_12 == 0
|
||||
&& (player_getTransformation() != TRANSFORM_1_BANJO)
|
||||
&& (player_getTransformation() != TRANSFORM_7_WISHWASHY))
|
||||
@@ -407,7 +407,7 @@ void chMumbo_update(Actor *this) {
|
||||
func_8025A58C(-1, 1000);
|
||||
}
|
||||
if (actor_animationIsAt(this, 0.999f)) {
|
||||
if (!this->is_first_encounter) {
|
||||
if (!this->has_met_before) {
|
||||
func_8028F918(0);
|
||||
}
|
||||
func_8025A7DC(COMUSIC_1D_MUMBO_TRANSFORMATION);
|
||||
@@ -416,7 +416,7 @@ void chMumbo_update(Actor *this) {
|
||||
chMumbo_func_802D1B8C(this, D_8037DDF0);
|
||||
break;
|
||||
}
|
||||
if (this->is_first_encounter) {
|
||||
if (this->has_met_before) {
|
||||
subaddie_set_state(this, 3);
|
||||
gcdialog_showText(ASSET_DAF_DIALOG_MUMBO_TREX_MISTAKE, 6, NULL, this->marker, __chMumbo_textCallback, NULL);
|
||||
break;
|
||||
|
@@ -67,7 +67,7 @@ void func_802DAA14(Actor *this){
|
||||
return;
|
||||
}
|
||||
|
||||
if(!this->is_first_encounter){
|
||||
if(!this->has_met_before){
|
||||
if(level_get() == LEVEL_A_MAD_MONSTER_MANSION){
|
||||
text_id = 0xadc;
|
||||
}
|
||||
@@ -79,6 +79,6 @@ void func_802DAA14(Actor *this){
|
||||
text_id = tmp;
|
||||
}
|
||||
gcdialog_showText(text_id, 4, NULL, this->marker, func_802DA9A0, NULL);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
|
@@ -838,7 +838,7 @@ int func_8030E3FC(u8 indx){
|
||||
}
|
||||
}
|
||||
|
||||
void func_8030E484(enum sfx_e uid){
|
||||
void sfxsource_playHighPriority(enum sfx_e uid){
|
||||
func_8030D6C4(uid, 1.0f, 22000, 0, 2);
|
||||
}
|
||||
|
||||
|
@@ -104,7 +104,7 @@ void func_8031A678(Actor *this){
|
||||
|
||||
void __chMinigame_textCallback1(ActorMarker *marker, enum asset_e text_id, s32 arg2){
|
||||
Actor *this = marker_getActor(marker);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
|
||||
void __chMinigame_transformToCroc(ActorMarker *marker, enum asset_e text_id, s32 arg2){
|
||||
@@ -164,7 +164,7 @@ void chMinigame_update(Actor *this){
|
||||
func_8028FAB0(this->position);
|
||||
this->unk1C[0] = 0.0f; this->unk1C[1] = this->yaw; this->unk1C[2] = 0.0f;
|
||||
func_8028FAEC(this->unk1C);
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
if(this->unk10_12 >= 7){
|
||||
marker_despawn(this->marker);
|
||||
return;
|
||||
@@ -177,7 +177,7 @@ void chMinigame_update(Actor *this){
|
||||
if(volatileFlag_get(VOLATILE_FLAG_2_FF_IN_MINIGAME)){
|
||||
switch(this->state){
|
||||
case MINIGAME_STATE_1_INTRODUCE_GAME://L8031AB2C
|
||||
if(this->is_first_encounter)
|
||||
if(this->has_met_before)
|
||||
__chMinigame_setState(this, MINIGAME_STATE_2_IN_PROGESS);
|
||||
break;
|
||||
case MINIGAME_STATE_2_IN_PROGESS://L8031AB50
|
||||
|
@@ -883,7 +883,7 @@ Actor *actor_new(s32 position[3], s32 yaw, ActorInfo* actorInfo, u32 flags){
|
||||
suLastBaddie->unk14C[0] = NULL;
|
||||
suLastBaddie->unk14C[1] = NULL;
|
||||
suLastBaddie->unk138_27 = 0;
|
||||
suLastBaddie->is_first_encounter = FALSE;
|
||||
suLastBaddie->has_met_before = FALSE;
|
||||
suLastBaddie->unk138_23 = 0;
|
||||
suLastBaddie->unk138_22 = 0;
|
||||
suLastBaddie->unk138_21 = 0;
|
||||
|
@@ -46,21 +46,21 @@ void func_80361870(Actor *this){
|
||||
this->volatile_initialized = TRUE;
|
||||
}
|
||||
|
||||
if(!this->is_first_encounter && func_80329530(this, 400) && !func_80329530(this, 50)){
|
||||
if(!this->has_met_before && func_80329530(this, 400) && !func_80329530(this, 50)){
|
||||
if(this->unkF4_8 == 1 && !fileProgressFlag_get(FILEPROG_31_MM_OPEN) && level_get() == LEVEL_6_LAIR){
|
||||
text_id = fileProgressFlag_get(FILEPROG_A7_NEAR_PUZZLE_PODIUM_TEXT)? 0xF80 : 0xF7F;
|
||||
if(gcdialog_showText(text_id, 0, 0, 0, 0, 0)){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
}
|
||||
else if(func_803616F0(this)){
|
||||
sp28 = (volatileFlag_get(VOLATILE_FLAG_16)?0xf6e:0xf68) + this->unkF4_8 - 1;
|
||||
if(!volatileFlag_get(VOLATILE_FLAG_16) && level_get() == LEVEL_6_LAIR){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
else{
|
||||
if(gcdialog_showText(sp28, 0, 0, 0, 0, 0)){
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
volatileFlag_set(VOLATILE_FLAG_16, 0);
|
||||
}
|
||||
}
|
||||
|
@@ -233,7 +233,7 @@ void fxhoneycarrierscore_update(s32 arg0, struct8s *arg1){
|
||||
timedFunc_set_2(0.25f, (GenFunction_2)func_8025A6EC, COMUSIC_2B_DING_B, 28000);
|
||||
item_adjustByDiffWithHud(ITEM_14_HEALTH, 0);
|
||||
timedFunc_set_1(1.25f, (GenFunction_1)item_inc, ITEM_15_HEALTH_TOTAL);
|
||||
timedFunc_set_1(1.25f, (GenFunction_1)func_8030E484, SFX_3EA_UNKNOWN);
|
||||
timedFunc_set_1(1.25f, (GenFunction_1)sfxsource_playHighPriority, SFX_3EA_UNKNOWN);
|
||||
timedFunc_set_2(1.25f, (GenFunction_2)item_set, ITEM_14_HEALTH, item_getCount(ITEM_15_HEALTH_TOTAL)+1);
|
||||
timedFunc_set_1(1.5f, (GenFunction_1)gcpausemenu_80314AC8, 1);
|
||||
}
|
||||
|
@@ -282,7 +282,7 @@ void chBossJinjo_update(Actor *this){
|
||||
if(actor_animationIsAt(this, 0.85f)){
|
||||
if(func_8030E3FC(this->unk44_31))
|
||||
func_8030E394(this->unk44_31);
|
||||
func_8030E484(SFX_19_BANJO_LANDING_08);
|
||||
sfxsource_playHighPriority(SFX_19_BANJO_LANDING_08);
|
||||
func_8025A7DC(COMUSIC_43_ENTER_LEVEL_GLITTER);
|
||||
}//L8038CD20
|
||||
}
|
||||
|
@@ -126,7 +126,7 @@ void chBossJinjoBase_update(Actor *this) {
|
||||
func_8030DD14(local->unk0, 2);
|
||||
func_8030DBB4(local->unk0, 0.7f);
|
||||
sfxsource_setSampleRate(local->unk0, 12000);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.6f, 20000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.6f, 20000);
|
||||
func_8038D3DC(this, 0x19a, 0.0f, -200.0f, 0.0f);
|
||||
TUPLE_COPY(this->unk1C, this->position);
|
||||
this->position_y = -400.0f;
|
||||
|
@@ -145,7 +145,7 @@ void chjinjonatorbase_update(Actor *this){
|
||||
this->unk1C[1] = this->position_y;
|
||||
this->unk1C[2] = this->position_z;
|
||||
this->position_y = -600.0f;
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.6f, 25000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.6f, 25000);
|
||||
if(0.0f != this->lifetime_value){
|
||||
this->velocity_y = 600.0f/this->lifetime_value;
|
||||
}else{
|
||||
|
@@ -143,10 +143,10 @@ void chBrentilda_update(Actor *this) {
|
||||
if (phi_f2 < 500.0) {
|
||||
if (sp74 < 0xFF) {
|
||||
sp74 = (sp74 + 0xC < 0xFF) ? sp74 + 0xC : 0xFF;
|
||||
if (!this->is_first_encounter) {
|
||||
if (!this->has_met_before) {
|
||||
comusic_playTrack(COMUSIC_81_ACTIVATING_BRENTILDA);
|
||||
func_80324D2C(1.0f, COMUSIC_81_ACTIVATING_BRENTILDA);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
this->unk138_23 = FALSE;
|
||||
}
|
||||
}
|
||||
@@ -159,7 +159,7 @@ void chBrentilda_update(Actor *this) {
|
||||
comusic_playTrack(COMUSIC_8B_DEACTIVATE_BRENTILDA);
|
||||
func_80324D2C(1.0f, COMUSIC_8B_DEACTIVATE_BRENTILDA);
|
||||
this->unk138_23 = TRUE;
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -382,7 +382,7 @@ void func_803867A8(Actor *this) {
|
||||
this->velocity[0] += 1.0f;
|
||||
if((this->velocity[0] < 0.0f) || (this->velocity[0] > 19.0f)) {
|
||||
this->velocity[0] = 0.0f;
|
||||
func_8030E6A4(SFX_3F6_UNKNOWN, 0.5f, this->alpha_124_19*0x25 + 0x3840);
|
||||
func_8030E6A4(SFX_3F6_RUBBING, 0.5f, this->alpha_124_19*0x25 + 0x3840);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -390,7 +390,7 @@ void func_803867A8(Actor *this) {
|
||||
this->velocity[0] += 1.0f;
|
||||
if ((this->velocity[0] < 0.0f) || (this->velocity[0] > 19.0f)) {
|
||||
this->velocity[0] = 0.0f;
|
||||
FUNC_8030E8B4(SFX_3F6_UNKNOWN, 0.5f, 24000, this->position, 100, 2300);
|
||||
FUNC_8030E8B4(SFX_3F6_RUBBING, 0.5f, 24000, this->position, 100, 2300);
|
||||
|
||||
}
|
||||
}
|
||||
@@ -873,7 +873,7 @@ void func_803880BC(Actor *this)
|
||||
__spawnQueue_add_1((GenFunction_1)func_80387E94, reinterpret_cast(s32, this->marker));
|
||||
|
||||
if (volatileFlag_get(VOLATILE_FLAG_BC_WITCH_SWITCH_PRESSED_CC) && !fileProgressFlag_get(FILEPROG_9A_CC_WITCH_SWITCH_PRESSED))
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.75f, 30000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.75f, 30000);
|
||||
}
|
||||
|
||||
if (fileProgressFlag_get(FILEPROG_9B_LAIR_CC_WITCH_SWITCH_EYES_ACTIVE))
|
||||
@@ -1628,7 +1628,7 @@ void func_80389934(Actor *this)
|
||||
{
|
||||
subaddie_set_state_forward(this, 0x17);
|
||||
actor_playAnimationOnce(this);
|
||||
FUNC_8030E624(SFX_3F6_UNKNOWN, 0.6f, 32000);
|
||||
FUNC_8030E624(SFX_3F6_RUBBING, 0.6f, 32000);
|
||||
func_8025A6EC(COMUSIC_3D_JIGGY_SPAWN, 0x7FFF);
|
||||
}
|
||||
|
||||
|
@@ -197,7 +197,7 @@ void func_8038EFD8(Actor *this) {
|
||||
f32 sp30[3];
|
||||
f32 sp24[3];
|
||||
|
||||
this->is_first_encounter = FALSE;
|
||||
this->has_met_before = FALSE;
|
||||
player_getPosition(sp30);
|
||||
sp24[0] = this->position[0];
|
||||
sp24[1] = this->position[1];
|
||||
@@ -421,7 +421,7 @@ void lair_func_8038F924(Actor *this) {
|
||||
local->unk0 = 0;
|
||||
local->unk4 = 0;
|
||||
local->unk8 = (func_8038ECA8(this->marker)) ? 0xff : 1;
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
for(phi_v1 = 0; phi_v1 < sp64; phi_v1 ++){
|
||||
local->unk4++;
|
||||
local->unk0 |= (1 << func_8038F0EC(this));
|
||||
@@ -473,8 +473,8 @@ void lair_func_8038F924(Actor *this) {
|
||||
func_8038EDBC(this);
|
||||
switch(this->state){
|
||||
case 1://L8038FCD0
|
||||
if (!this->is_first_encounter && (!func_8028F20C() || !func_8028FB48(0x08000000))) {
|
||||
this->is_first_encounter = TRUE;
|
||||
if (!this->has_met_before && (!func_8028F20C() || !func_8028FB48(0x08000000))) {
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
if (func_80329530(this, 300)) {
|
||||
if ((this->unkF4_8 == 0xA) && !fileProgressFlag_get(FILEPROG_F6_SEEN_DOOR_OF_GRUNTY_PUZZLE_PODIUM)) {
|
||||
@@ -486,7 +486,7 @@ void lair_func_8038F924(Actor *this) {
|
||||
func_8035644C(FILEPROG_A7_NEAR_PUZZLE_PODIUM_TEXT);
|
||||
}
|
||||
}
|
||||
if (func_8038ECA8(this->marker) && this->is_first_encounter && !func_8038EB58(this) && (func_8028ECAC() == 0 || func_8028ECAC() == BSGROUP_8_TROT)) {
|
||||
if (func_8038ECA8(this->marker) && this->has_met_before && !func_8038EB58(this) && (func_8028ECAC() == 0 || func_8028ECAC() == BSGROUP_8_TROT)) {
|
||||
func_8038F350(this, 2);
|
||||
}
|
||||
break;
|
||||
|
@@ -91,11 +91,11 @@ void func_803902B8(Actor *this) {
|
||||
sp54 = this->marker->id - 0x16D;
|
||||
if (!this->initialized) {
|
||||
marker_setFreeMethod(this->marker, func_80390298);
|
||||
this->is_first_encounter = volatileFlag_get(VOLATILE_FLAG_1F_IN_CHARACTER_PARADE);
|
||||
this->has_met_before = volatileFlag_get(VOLATILE_FLAG_1F_IN_CHARACTER_PARADE);
|
||||
this->initialized = TRUE;
|
||||
}
|
||||
_player_getPosition(sp5C);
|
||||
sp58 = func_80259384(this->position, sp5C, 1750.0f) && !this->is_first_encounter;
|
||||
sp58 = func_80259384(this->position, sp5C, 1750.0f) && !this->has_met_before;
|
||||
if (sp58 && !this->unk38_0) {
|
||||
func_8032BB88(this, 0, 0x1F4);
|
||||
func_8025A6EC(COMUSIC_79_CHEATO, 0);
|
||||
|
@@ -56,7 +56,7 @@ void func_80390890(ActorMarker *marker, ActorMarker *other_marker) {
|
||||
func_8030E878(SFX_C2_GRUBLIN_EGH, local->unkC_27*0.1 + 0.8, 32000, this->position, 1250.0f, 2500.0f);
|
||||
__spawnQueue_add_4((GenFunction_4)func_802C4140, ACTOR_4C_STEAM, reinterpret_cast(s32, this->position[0]), reinterpret_cast(s32, this->position[1]), reinterpret_cast(s32, this->position[2]));
|
||||
actor_collisionOff(this);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
|
||||
void func_80390994(Actor *this) {
|
||||
|
@@ -263,9 +263,9 @@ void func_80391B04(Actor *this) {
|
||||
func_80391810(this, 2);
|
||||
}
|
||||
}
|
||||
if ((local->unk8 < this->position[1]) && !this->is_first_encounter) {
|
||||
if ((local->unk8 < this->position[1]) && !this->has_met_before) {
|
||||
FUNC_8030E8B4(SFX_14E_SOFT_EXPLOSION, 1.0f, 20000, this->position, 1500, 3000);
|
||||
this->is_first_encounter = TRUE;
|
||||
this->has_met_before = TRUE;
|
||||
}
|
||||
break;
|
||||
case 3:
|
||||
|
@@ -104,8 +104,8 @@ void func_80392918(Actor *this) {
|
||||
return;
|
||||
}
|
||||
func_80326224(this);
|
||||
if ((this->unk48 > 0.5) && !this->is_first_encounter) {
|
||||
this->is_first_encounter = TRUE;
|
||||
if ((this->unk48 > 0.5) && !this->has_met_before) {
|
||||
this->has_met_before = TRUE;
|
||||
ncStaticCamera_setToNode(0x1E);
|
||||
}
|
||||
if ((0.999 < this->unk48) && !this->unk38_0) {
|
||||
|
Reference in New Issue
Block a user