Merge branch 'master' into wip/pal_integration
This commit is contained in:
commit
1a240c651c
|
@ -4640,7 +4640,7 @@ enum common_particle_e{
|
|||
|
||||
enum bsgroup_e {
|
||||
BSGROUP_3_WONDERWING = 0x3,
|
||||
|
||||
BSGROUP_4_LOOK = 0x4,
|
||||
BSGROUP_5_CLIMB = 0x5,
|
||||
BSGROUP_6_TURBO_TALON_TRAINERS,
|
||||
BSGROUP_7_CROC_ATTACK,
|
||||
|
@ -4673,8 +4673,15 @@ enum misc_flag_e{
|
|||
//0x13 in difficult terrain (mud)
|
||||
MISC_FLAG_14_LOSE_BOGGY_RACE = 0x14,
|
||||
//0x15 touching loadzone?
|
||||
|
||||
MISC_FLAG_17_FPV = 0x17,
|
||||
MISC_FLAG_1B_TRANSFORMING = 0x1B
|
||||
};
|
||||
|
||||
enum nc_first_person_state{
|
||||
FIRSTPERSON_STATE_1_ENTER = 1,
|
||||
FIRSTPERSON_STATE_2_IDLE,
|
||||
FIRSTPERSON_STATE_3_EXIT,
|
||||
FIRSTPERSON_STATE_4_DONE
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
@ -397,7 +397,7 @@ void func_8030E2C4(u8);
|
|||
void func_8030E394(u8 indx);
|
||||
void func_8030E484(enum sfx_e uid);
|
||||
void func_8030E4E4(enum sfx_e uid);
|
||||
void func_8030E510(enum sfx_e uid, s32 arg1);
|
||||
void sfxsource_play(enum sfx_e uid, s32 sample_rate);
|
||||
void func_8030E540(enum sfx_e uid);
|
||||
void func_8030E560(enum sfx_e uid, s32 arg1);
|
||||
void func_8030E58C(enum sfx_e uid, f32 arg1);
|
||||
|
|
|
@ -84,7 +84,7 @@ void chpinkegg_collision(ActorMarker *this, ActorMarker *other_marker){
|
|||
|
||||
thisActor = marker_getActor(this);
|
||||
this->propPtr->unk8_3 = 0;
|
||||
func_8030E510(SFX_AA_BGS_EGG_BREAKING_1, 28000);
|
||||
sfxsource_play(SFX_AA_BGS_EGG_BREAKING_1, 28000);
|
||||
subaddie_set_state(thisActor, 3);
|
||||
actor_playAnimationOnce(thisActor);
|
||||
this->collidable = 0;
|
||||
|
|
|
@ -150,7 +150,7 @@ void func_80387CC0(void){
|
|||
return;
|
||||
|
||||
viewport_get_rotation_vec3f(sp1C);
|
||||
tmp_v0 = func_8023DB4C(0x7F);
|
||||
tmp_v0 = globalTimer_getTimeMasked(0x7F);
|
||||
if(tmp_v0 >= 0x40){
|
||||
tmp_v0 = 0x7F - tmp_v0;
|
||||
}
|
||||
|
|
|
@ -13,7 +13,7 @@ void func_80389440(Actor *this, s32 next_state) {
|
|||
void *temp_v0;
|
||||
|
||||
if (next_state == 2) {
|
||||
func_8030E510(SFX_AA_BGS_EGG_BREAKING_1, 28000);
|
||||
sfxsource_play(SFX_AA_BGS_EGG_BREAKING_1, 28000);
|
||||
this->marker->propPtr->unk8_3 = FALSE;
|
||||
fileProgressFlag_set(FILEPROG_E6_SPRING_EYRIE_HATCHED, TRUE);
|
||||
skeletalAnim_set(this->unk148, 0x187, 0.0f, 2.0f);
|
||||
|
|
|
@ -70,7 +70,7 @@ Actor *func_80388740(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
|
|||
|| this->state == 6
|
||||
|| this->state == 8
|
||||
){
|
||||
if(this->unk4C != 0.0f && (func_8023DB5C() & 1)){
|
||||
if(this->unk4C != 0.0f && (globalTimer_getTime() & 1)){
|
||||
if(-2.0 < this->roll){
|
||||
func_8034A174(func_80329934(), 6, sp2C);
|
||||
particleEmitter_setPosition(local->unk0, sp2C);
|
||||
|
|
|
@ -319,7 +319,7 @@ void func_8038D6C8(Actor *this){
|
|||
if(!func_80329530(this, 800))
|
||||
break;
|
||||
|
||||
if(!(func_8023DB5C() & 1))
|
||||
if(!(globalTimer_getTime() & 1))
|
||||
subaddie_set_state_with_direction(this, 2, 0.001f, 1);
|
||||
else
|
||||
subaddie_set_state_with_direction(this, 2, 0.999f, 0);
|
||||
|
|
|
@ -74,11 +74,11 @@ void func_80390EB0(Actor *this){
|
|||
|
||||
if(func_8024DB50(this->position, 150.0f) || func_80329530(this, 1200))
|
||||
{
|
||||
if( !(func_8023DB5C() & 3) && randf() < 0.2){
|
||||
if( !(globalTimer_getTime() & 3) && randf() < 0.2){
|
||||
func_80390C70(this->position);
|
||||
}
|
||||
|
||||
if( !(func_8023DB5C() & 3) && randf() < 0.7){
|
||||
if( !(globalTimer_getTime() & 3) && randf() < 0.7){
|
||||
func_80390D58(this->position);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -87,7 +87,7 @@ void func_80391040(Actor *this){
|
|||
|
||||
if( !this->marker->unk14_21 ) return;
|
||||
if( !func_80390FC0() ) return;
|
||||
if( func_8023DB5C() & 7 ) return;
|
||||
if( globalTimer_getTime() & 7 ) return;
|
||||
|
||||
if(randf() < 0.5){
|
||||
a1 = 8;
|
||||
|
|
|
@ -176,7 +176,7 @@ void chAncientOne_update(Actor *this){
|
|||
}
|
||||
}
|
||||
else{//L80386C64
|
||||
sp38 = func_8023DB5C() & 0xF;
|
||||
sp38 = globalTimer_getTime() & 0xF;
|
||||
sp34 = LOCAL_CH_ANCIENT_ONE(this)->unk1C + 40.0f;
|
||||
this->position_y += 18.0;
|
||||
this->position_x += (sp38 & 1) ? 0x17 : -0x17;
|
||||
|
|
|
@ -216,7 +216,7 @@ void func_8038DBDC(Actor *this){
|
|||
}
|
||||
else{
|
||||
if(actor_animationIsAt(this, 0.42f))
|
||||
func_8030E510(SFX_7C_CHEBOOF, 32000);
|
||||
sfxsource_play(SFX_7C_CHEBOOF, 32000);
|
||||
tmp = this->unk44_31;
|
||||
if(tmp && func_8030E3FC(tmp)){
|
||||
if(1.0 < this->unk1C[1]){
|
||||
|
|
|
@ -293,7 +293,7 @@ void GV_func_8038BEA0(Actor *this){
|
|||
else{
|
||||
func_8030E2C4(this->unk44_31);
|
||||
this->position_y -= 7.0;
|
||||
if(func_8023DB5C() & 1){
|
||||
if(globalTimer_getTime() & 1){
|
||||
sp38[0] = this->position_x;
|
||||
sp38[1] = this->position_y;
|
||||
sp38[2] = this->position_z;
|
||||
|
|
|
@ -27,8 +27,8 @@ void _chchimpystump_80386CA0(Actor *this){
|
|||
func_802BB3DC(1, 3.0f, 1.0f);
|
||||
func_80244BB0(0, 0x6A, 0x7FF8, 0.2f);
|
||||
}//L80386D0C
|
||||
this->position_x = ((func_8023DB5C() & 1) * 2) ^ (s32)this->position_x;
|
||||
this->position_z = ((func_8023DB5C() & 2) * 2) ^ (s32)this->position_z;
|
||||
this->position_x = ((globalTimer_getTime() & 1) * 2) ^ (s32)this->position_x;
|
||||
this->position_z = ((globalTimer_getTime() & 2) * 2) ^ (s32)this->position_z;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -57,7 +57,7 @@ void chchimpystump_update(Actor *this){
|
|||
func_802BB41C(1);
|
||||
func_80244C78(0);
|
||||
}
|
||||
if((func_8023DB5C() & 3) == 2)
|
||||
if((globalTimer_getTime() & 3) == 2)
|
||||
func_80353064(this->position, 40.0f);
|
||||
break;
|
||||
case 3:
|
||||
|
|
|
@ -83,7 +83,7 @@ void func_80386FB0(Actor *this){
|
|||
}
|
||||
|
||||
void func_80386FE8(void){
|
||||
if( (func_8023DB5C() & 0xF) == 0xB
|
||||
if( (globalTimer_getTime() & 0xF) == 0xB
|
||||
&& 0.85 < randf ()
|
||||
&& !func_803114B0()
|
||||
){
|
||||
|
|
|
@ -34,8 +34,8 @@ void func_8038B900(Actor *this){
|
|||
this->marker->propPtr->unk8_3 = 1;
|
||||
if(this->marker->unk14_21){
|
||||
sp54 = skeletalAnim_getProgress(this->unk148);
|
||||
if( ( func_8023DB5C() & (1 << 4) )
|
||||
&& ( func_8023DB5C() & (1 << 2) )
|
||||
if( ( globalTimer_getTime() & (1 << 4) )
|
||||
&& ( globalTimer_getTime() & (1 << 2) )
|
||||
&& ( randf() < 0.90 )
|
||||
){
|
||||
if( ( this->state == 3
|
||||
|
|
|
@ -14,7 +14,7 @@ void func_8023DFF0(s32);
|
|||
|
||||
s32 D_80275610 = 0;
|
||||
s32 D_80275614 = 0;
|
||||
u32 D_80275618 = 0;
|
||||
u32 gGlobalTimer = 0;
|
||||
u32 D_8027561C[] = {
|
||||
0x9, 0x4, 0xA, 0x3, 0xB, 0x2, 0xC, 0x5, 0x0,
|
||||
0x1, 0x6, 0xD, -1
|
||||
|
@ -70,16 +70,16 @@ void func_8023DA9C(s32 arg0){
|
|||
func_80255CD8();
|
||||
}
|
||||
|
||||
u32 func_8023DB4C(u32 arg0){
|
||||
return D_80275618 & arg0;
|
||||
u32 globalTimer_getTimeMasked(u32 mask){
|
||||
return gGlobalTimer & mask;
|
||||
}
|
||||
|
||||
s32 func_8023DB5C(void){
|
||||
return D_80275618;
|
||||
s32 globalTimer_getTime(void){
|
||||
return gGlobalTimer;
|
||||
}
|
||||
|
||||
void func_8023DB68(void){
|
||||
D_80275618 = 0;
|
||||
void globalTimer_reset(void){
|
||||
gGlobalTimer = 0;
|
||||
}
|
||||
|
||||
s32 func_8023DB74(void){
|
||||
|
@ -122,16 +122,16 @@ void core1_init(void){
|
|||
ml_init();
|
||||
gctransition_reset();
|
||||
D_8027A130 = 0;
|
||||
D_80275618 = 0;
|
||||
gGlobalTimer = 0;
|
||||
func_8023DA9C(3);
|
||||
}
|
||||
|
||||
void func_8023DCDC(void){
|
||||
D_80275618++;
|
||||
void globalTimer_incTimer(void){
|
||||
gGlobalTimer++;
|
||||
}
|
||||
|
||||
void func_8023DCF4(void){
|
||||
D_80275618--;
|
||||
void globalTimer_decTimer(void){
|
||||
gGlobalTimer--;
|
||||
}
|
||||
|
||||
void mainLoop(void){
|
||||
|
@ -141,12 +141,12 @@ void mainLoop(void){
|
|||
u16 rgba;
|
||||
s32 offset;
|
||||
|
||||
if((func_8023DB5C() & 0x7f) == 0x11)
|
||||
if((globalTimer_getTime() & 0x7f) == 0x11)
|
||||
sns_write_payload_over_heap();
|
||||
func_8023DA74();
|
||||
|
||||
if(D_8027A130 != 3 || getGameMode() != GAME_MODE_4_PAUSED)
|
||||
func_8023DCDC();
|
||||
globalTimer_incTimer();
|
||||
|
||||
if(!D_8027BEEC)
|
||||
pfsManager_update();
|
||||
|
@ -183,7 +183,7 @@ void mainLoop(void){
|
|||
//render weird CRC failure image
|
||||
for(y= 0x1e; y < framebuffer_height - 0x1e; y++){//L8023DEB4
|
||||
for(x = 0x14; x < 0xeb; x++){
|
||||
tmp = ((8 * func_8023DB5C()) + ((x*x) + (y*y)));
|
||||
tmp = ((8 * globalTimer_getTime()) + ((x*x) + (y*y)));
|
||||
|
||||
r = _SHIFTL(x>>3, 11, 5);
|
||||
g = _SHIFTL(y>>3, 6, 5);
|
||||
|
|
|
@ -133,7 +133,7 @@ s32 func_8024E67C(s32 controller_index){
|
|||
}
|
||||
|
||||
s32 func_8024E698(s32 controller_index){
|
||||
if(func_8023DB5C() < 2){
|
||||
if(globalTimer_getTime() < 2){
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -322,7 +322,7 @@ void func_8024F890(u8 arg0, enum comusic_e arg1){
|
|||
alCSPSetSeq(&D_80281720[arg0].cseqp, &D_80281720[arg0].cseq);
|
||||
alCSPPlay(&D_80281720[arg0].cseqp);
|
||||
alCSPSetVol(&D_80281720[arg0].cseqp, D_80281720[arg0].unk0);
|
||||
if(player_is_present() && func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_is_present() && player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8025F3F0(&D_80281720[arg0].cseqp, 0.0f, 1.0f);
|
||||
}
|
||||
else{
|
||||
|
@ -433,7 +433,7 @@ void func_8024FE44(u8 arg0, f32 arg1, f32 arg2){
|
|||
D_80281720[arg0].unk17C = arg1;
|
||||
D_80281720[arg0].unk180 = arg2;
|
||||
if(func_80250074(arg0) == 0){
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8025F3F0(&D_80281720[arg0].cseqp, 0.0f, 1.0f);
|
||||
}else{
|
||||
func_8025F3F0(&D_80281720[arg0].cseqp, arg1, arg2);
|
||||
|
|
|
@ -211,7 +211,7 @@ void sns_write_payload_over_heap(void)
|
|||
s32 val2;
|
||||
u32 i;
|
||||
|
||||
if (func_8023DB5C() <= 0x3B || snsToRestoreItems)
|
||||
if (globalTimer_getTime() <= 0x3B || snsToRestoreItems)
|
||||
return;
|
||||
|
||||
sns_generate_payload(snsBasePayloadPtr2);
|
||||
|
|
|
@ -197,12 +197,12 @@ void func_80247C20(void) {
|
|||
s32 i;
|
||||
|
||||
if (D_80275BE4 == 0) {
|
||||
D_80275BE4 = func_8023DB5C();
|
||||
D_80275BE4 = globalTimer_getTime();
|
||||
return;
|
||||
}
|
||||
if (func_8023DB5C() != D_80275BE4) {
|
||||
if (globalTimer_getTime() != D_80275BE4) {
|
||||
D_80275BE0 = FALSE;
|
||||
D_80275BE4 = func_8023DB5C();
|
||||
D_80275BE4 = globalTimer_getTime();
|
||||
}
|
||||
|
||||
if (D_80275BE0) {
|
||||
|
|
|
@ -170,7 +170,7 @@ void func_8024AED8(void){
|
|||
}
|
||||
|
||||
void func_8024AF00(s32 arg0, s32 arg1){
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(arg0);
|
||||
}
|
||||
else{
|
||||
|
@ -208,7 +208,7 @@ void func_8024AF48(void){
|
|||
|
||||
case MAP_7_TTC_TREASURE_TROVE_COVE: // L8024B094
|
||||
func_8024A9EC(0);
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(0x600);
|
||||
}
|
||||
else if(func_8024A8DC(-0x12C, 0x58c, 0x866)
|
||||
|
@ -228,7 +228,7 @@ void func_8024AF48(void){
|
|||
|
||||
case MAP_B_CC_CLANKERS_CAVERN: // L8024B158
|
||||
func_8024A9EC(0);
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(!(D_802806F8[1] < 0x28b)){
|
||||
func_8024A8AC(0x8180, 5.0f);
|
||||
}
|
||||
|
@ -242,7 +242,7 @@ void func_8024AF48(void){
|
|||
break;
|
||||
|
||||
case MAP_12_GV_GOBIS_VALLEY:// L8024B1BC
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(0x8020);
|
||||
}
|
||||
else if(func_8024A8DC(-0xf96, 0x1626, 0xe74)){
|
||||
|
@ -262,7 +262,7 @@ void func_8024AF48(void){
|
|||
break;
|
||||
|
||||
case MAP_1_SM_SPIRAL_MOUNTAIN: // L8024B23C
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(0x9000);
|
||||
}
|
||||
else{
|
||||
|
@ -360,7 +360,7 @@ void func_8024AF48(void){
|
|||
break;
|
||||
|
||||
case MAP_45_CCW_AUTUMN:// L8024B4D4
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(0x600);
|
||||
}
|
||||
else{
|
||||
|
@ -382,7 +382,7 @@ void func_8024AF48(void){
|
|||
break;
|
||||
|
||||
case MAP_27_FP_FREEZEEZY_PEAK:// L8024B538
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(0x400);
|
||||
}
|
||||
else if( mapSpecificFlags_get(0) && !jiggyscore_isCollected(JIGGY_2F_FP_XMAS_TREE)){
|
||||
|
@ -453,7 +453,7 @@ void func_8024AF48(void){
|
|||
break;
|
||||
|
||||
case MAP_6B_GL_180_NOTE_DOOR:// L8024B704
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(0x8800);
|
||||
}
|
||||
else if(func_8024A8DC(0x10eb, 0x4f5, 0x730)) {
|
||||
|
@ -476,7 +476,7 @@ void func_8024AF48(void){
|
|||
break;
|
||||
|
||||
case MAP_70_GL_CC_LOBBY:// L8024B7B4
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(0x8100);
|
||||
}
|
||||
else if(func_8024A8DC(-0x19d6, -0x1d3, 0x71e)){
|
||||
|
@ -520,7 +520,7 @@ void func_8024AF48(void){
|
|||
break;
|
||||
|
||||
case MAP_71_GL_STATUE_ROOM:// L8024B8C0
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(0x200);
|
||||
}
|
||||
else if(func_8024A8DC(-0xf0e, -0x15a, 0x302)){
|
||||
|
@ -570,7 +570,7 @@ void func_8024AF48(void){
|
|||
break;
|
||||
|
||||
case MAP_78_GL_RBB_AND_MMM_PUZZLE:// L8024BA98
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
func_8024A880(0x8200);
|
||||
}
|
||||
else if(0x15a <= D_802806F8[1] && func_8024A8DC(-0x89a, 0x21a, 0x368)){
|
||||
|
|
|
@ -124,7 +124,7 @@ void bafalldamage_init(void){
|
|||
void bafalldamage_update(void){
|
||||
s32 player_position;
|
||||
player_position = func_8028ECAC();
|
||||
if(func_8028B2E8() || (func_8028EE84() != BSWATERGROUP_0_NONE) || player_position == BSGROUP_A_FLYING){
|
||||
if(player_isStable() || (player_getWaterState() != BSWATERGROUP_0_NONE) || player_position == BSGROUP_A_FLYING){
|
||||
bafalldamage_start();
|
||||
bafalldamage_set_state(1);
|
||||
}
|
||||
|
|
|
@ -529,7 +529,7 @@ void __baMarker_resolveCollision(Prop *other_prop){
|
|||
player_getPosition(spA0);
|
||||
jiggy_id = chjiggy_getJiggyId(actor);
|
||||
if( jiggy_id != JIGGY_2F_FP_XMAS_TREE
|
||||
|| (func_8028B2E8() && !(3600.0f < ml_distanceSquared_vec3f(actor->position, spA0)))
|
||||
|| (player_isStable() && !(3600.0f < ml_distanceSquared_vec3f(actor->position, spA0)))
|
||||
){
|
||||
jiggyscore_setCollected(jiggy_id, TRUE);
|
||||
item_adjustByDiffWithoutHud(ITEM_26_JIGGY_TOTAL, 1);
|
||||
|
@ -686,7 +686,7 @@ void __baMarker_resolveCollision(Prop *other_prop){
|
|||
break;
|
||||
|
||||
case MARKER_6B_GLOOPBUBBLE: //L8028CD20
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER){
|
||||
item_adjustByDiffWithHud(ITEM_17_AIR, fxairscore_count_to_time(2));
|
||||
}
|
||||
break;
|
||||
|
|
|
@ -269,7 +269,7 @@ void baModel_setVisible(s32 arg0){
|
|||
}
|
||||
|
||||
void baModel_802921D4(f32 arg0[3]){
|
||||
if(func_8028EE84() == BSWATERGROUP_0_NONE){
|
||||
if(player_getWaterState() == BSWATERGROUP_0_NONE){
|
||||
D_8037C150.unk0 = 1;
|
||||
D_8037C150.unk4[0] = arg0[0];
|
||||
D_8037C150.unk4[1] = arg0[1];
|
||||
|
|
|
@ -96,7 +96,7 @@ void bsant_idle_update(void){
|
|||
if(func_8028B094())
|
||||
new_state = BS_38_ANT_FALL;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
new_state = badrone_look();
|
||||
|
||||
if(func_8029B300() > 0)
|
||||
|
@ -203,7 +203,7 @@ void bsant_jump_update(void){
|
|||
break;
|
||||
case 2://L8029EAF4
|
||||
func_80299628(0);
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029C5E8();
|
||||
bsant_substate = 3;
|
||||
}
|
||||
|
@ -213,7 +213,7 @@ void bsant_jump_update(void){
|
|||
sp2C = BS_35_ANT_IDLE;
|
||||
break;
|
||||
}//L8029EB38
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
baphysics_set_target_horizontal_velocity(0.0f);
|
||||
if(func_8029B300() > 0)
|
||||
sp2C = BS_ANT_WALK;
|
||||
|
@ -265,7 +265,7 @@ void bsant_fall_update(void){
|
|||
case 1:
|
||||
break;
|
||||
}
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if(miscflag_isTrue(0x19))
|
||||
sp2C = badrone_transform();
|
||||
else
|
||||
|
@ -329,7 +329,7 @@ static void __bsant_recoil_update(void){
|
|||
break;
|
||||
}
|
||||
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
sp1C = BS_35_ANT_IDLE;
|
||||
|
||||
bs_setState(sp1C);
|
||||
|
@ -411,7 +411,7 @@ void bsant_die_update(void){
|
|||
func_80299628(0);
|
||||
switch(bsant_substate){
|
||||
case 0://L8029F270
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
baanim_setEnd(1.0f);
|
||||
FUNC_8030E624(SFX_1F_HITTING_AN_ENEMY_3, 0.8f, 18000);
|
||||
FUNC_8030E624(SFX_39_BANJO_AYE_2, 1.8f, 18000);
|
||||
|
|
|
@ -154,7 +154,7 @@ void bsbarge_update(void){
|
|||
func_8029F4F0();
|
||||
break;
|
||||
case 4:
|
||||
if(!func_8028B2E8())
|
||||
if(!player_isStable())
|
||||
sp24 = BS_2F_FALL;
|
||||
if(animctrl_isAt(plyrMvmnt, 0.7f)){
|
||||
D_8037D2A0 = 0.0f;
|
||||
|
|
|
@ -169,7 +169,7 @@ void bsbflap_update(void){
|
|||
}
|
||||
break;
|
||||
case 4:
|
||||
if(func_8028B424())
|
||||
if(player_isFallTumbling())
|
||||
sp1c = BS_3D_FALL_TUMBLING;
|
||||
break;
|
||||
}//L802A2C94
|
||||
|
@ -180,7 +180,7 @@ void bsbflap_update(void){
|
|||
if(should_beak_bust())
|
||||
sp1c = BS_F_BBUSTER;
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029C5E8();
|
||||
sp1c = BS_2_WALK_SLOW;
|
||||
}
|
||||
|
|
|
@ -112,7 +112,7 @@ void bsbflip_update(void){
|
|||
}
|
||||
break;
|
||||
case 2://L802A3184
|
||||
if(func_8028B424())
|
||||
if(player_isFallTumbling())
|
||||
sp24 = BS_3D_FALL_TUMBLING;
|
||||
if(button_released(BUTTON_A)){
|
||||
animctrl_reset(aCtrl);
|
||||
|
@ -124,7 +124,7 @@ void bsbflip_update(void){
|
|||
baphysics_reset_terminal_velocity();
|
||||
D_8037D310 = 3;
|
||||
}//L802A320C
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
_bsbflip_802A2DC0();
|
||||
sp24 = func_8029C9C0(sp24);
|
||||
D_8037D310 = 4;
|
||||
|
@ -134,9 +134,9 @@ void bsbflip_update(void){
|
|||
}
|
||||
break;
|
||||
case 3://L802A3258
|
||||
if(func_8028B424())
|
||||
if(player_isFallTumbling())
|
||||
sp24 = BS_3D_FALL_TUMBLING;
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029E070(0);
|
||||
_bsbflip_802A2DC0();
|
||||
sp24 = func_8029C9C0(sp24);
|
||||
|
|
|
@ -25,7 +25,7 @@ u8 D_8037D347;
|
|||
|
||||
/* .code */
|
||||
int func_802A3350(void){
|
||||
if(!func_8028B2E8())
|
||||
if(!player_isStable())
|
||||
return 0;
|
||||
if(func_80294684() & 8){
|
||||
return 0;
|
||||
|
@ -217,7 +217,7 @@ void bsbfly_update(void){
|
|||
if(button_pressed(BUTTON_A))
|
||||
D_8037D347 = 1;
|
||||
|
||||
if(D_8037D347 && func_8023DB5C()%3 == 0){
|
||||
if(D_8037D347 && globalTimer_getTime()%3 == 0){
|
||||
D_8037D347 = 0;
|
||||
func_80346C10(&sp2C, 0, BS_1_IDLE, ITEM_F_RED_FEATHER, 1);
|
||||
}
|
||||
|
@ -389,7 +389,7 @@ void func_802A411C(void) {
|
|||
case 1:
|
||||
func_802A36D0();
|
||||
D_8037D324 += time_getDelta();
|
||||
sp40 = func_8028B2E8();
|
||||
sp40 = player_isStable();
|
||||
if (player_inWater()) {
|
||||
next_state = BS_4C_LANDING_IN_WATER;
|
||||
}
|
||||
|
@ -495,7 +495,7 @@ void func_802A4548(void){
|
|||
if(should_beak_bust())
|
||||
next_state = BS_F_BBUSTER;
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029C5E8();
|
||||
next_state = BS_20_LANDING;
|
||||
}
|
||||
|
@ -665,7 +665,7 @@ void func_802A4C34(s32 arg0) {
|
|||
if (animctrl_isStopped(baanim_getAnimCtrlPtr())) {
|
||||
next_state = BS_24_FLY;
|
||||
}
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
next_state = BS_2_WALK_SLOW;
|
||||
}
|
||||
bs_setState(next_state);
|
||||
|
@ -738,7 +738,7 @@ void func_802A4EC8(void) {
|
|||
|
||||
next_state = 0;
|
||||
sp18 = baanim_getAnimCtrlPtr();
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
next_state = BS_20_LANDING;
|
||||
}
|
||||
if (animctrl_isStopped(sp18) && (func_8028B094() || func_80294530())) {
|
||||
|
|
|
@ -167,7 +167,7 @@ void bsblongleg_stand_update(void){
|
|||
enum bs_e next_state = 0;
|
||||
func_802A531C();
|
||||
func_80299594(1, 0.5f);
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
if(button_pressed(BUTTON_B))
|
||||
|
@ -179,7 +179,7 @@ void bsblongleg_stand_update(void){
|
|||
if(player_shouldSlideTrot())
|
||||
next_state = BS_LONGLEG_SLIDE;
|
||||
|
||||
if(button_pressed(BUTTON_A) && func_8028B2E8())
|
||||
if(button_pressed(BUTTON_A) && player_isStable())
|
||||
next_state = BS_LONGLEG_JUMP;
|
||||
|
||||
if(stateTimer_isDone(STATE_TIMER_2_LONGLEG))
|
||||
|
@ -230,7 +230,7 @@ void bsblongleg_walk_update(void){
|
|||
if(player_shouldSlideTrot())
|
||||
next_state = BS_LONGLEG_SLIDE;
|
||||
|
||||
if(button_pressed(BUTTON_A) && func_8028B2E8())
|
||||
if(button_pressed(BUTTON_A) && player_isStable())
|
||||
next_state = BS_LONGLEG_JUMP;
|
||||
|
||||
if(stateTimer_isDone(STATE_TIMER_2_LONGLEG))
|
||||
|
@ -371,7 +371,7 @@ void bsblongleg_jump_update(void){
|
|||
case 2://L802A6020
|
||||
animctrl_setAnimTimer(aCtrl, ml_map_f(sp30, D_8037D354, 1.0f, D_8037D350, 0.6703f));
|
||||
func_80299594(1, 0.5f);
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029C5E8();
|
||||
animctrl_setSubRange(aCtrl, 0.0f, 1.0f);
|
||||
animctrl_setDuration(aCtrl, 1.3f);
|
||||
|
|
|
@ -118,7 +118,7 @@ void bsbpeck_update(void){
|
|||
break;
|
||||
}//L802A68D8
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029C5E8();
|
||||
sp24 = BS_1_IDLE;
|
||||
}
|
||||
|
|
|
@ -48,9 +48,10 @@ void bsbshock_charge_update(void){
|
|||
AnimCtrl *aCtrl = baanim_getAnimCtrlPtr();
|
||||
f32 sp1C[3];
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(func_8023DB5C() % 2)
|
||||
if(player_isStable()) {
|
||||
if(globalTimer_getTime() % 2) {
|
||||
func_8029C348();
|
||||
}
|
||||
}
|
||||
else
|
||||
{//L802A6B94
|
||||
|
@ -64,7 +65,7 @@ void bsbshock_charge_update(void){
|
|||
|
||||
switch(D_8037D381){
|
||||
case 0:
|
||||
if(func_8028B424())
|
||||
if(player_isFallTumbling())
|
||||
sp2C = BS_3D_FALL_TUMBLING;
|
||||
|
||||
if(func_8028B254(0x82)){
|
||||
|
@ -90,7 +91,7 @@ void bsbshock_charge_update(void){
|
|||
if(animctrl_getAnimTimer(aCtrl) < 0.3637 && button_released(8)){
|
||||
D_8037D380 = 0;
|
||||
}//L802A6CF4
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
baphysics_set_target_horizontal_velocity(0.0f);
|
||||
}
|
||||
else{//L802A6D18
|
||||
|
@ -172,8 +173,8 @@ void bsbshock_update(void){
|
|||
sp2C = BS_2F_FALL;
|
||||
}
|
||||
|
||||
if(!func_8028B2E8()){
|
||||
if(func_8028B424())
|
||||
if(!player_isStable()){
|
||||
if(player_isFallTumbling())
|
||||
sp2C = BS_3D_FALL_TUMBLING;
|
||||
|
||||
if(should_feathery_flap())
|
||||
|
|
|
@ -127,7 +127,7 @@ void func_802A7674() {
|
|||
func_802A71D8();
|
||||
func_802A7304();
|
||||
|
||||
if (func_80294F78()) {
|
||||
if (should_look_first_person_camera()) {
|
||||
state_id = badrone_look();
|
||||
}
|
||||
if (button_held(BUTTON_A)) {
|
||||
|
@ -428,7 +428,7 @@ void func_802A8098(void) {
|
|||
}
|
||||
switch (D_8037D396) {
|
||||
case 0:
|
||||
if (func_8023DB4C(1) == 0) {
|
||||
if (globalTimer_getTimeMasked(1) == 0) {
|
||||
_player_getPosition(plyr_pos);
|
||||
plyr_pos[1] += 60.0f;
|
||||
p_ctrl = func_8029B950(plyr_pos, 25.0f);
|
||||
|
@ -558,7 +558,7 @@ void func_802A85EC(void) {
|
|||
D_8037D398 += ml_max_f(mlAbsF(D_8037D398) * 0.1, 50.0f);
|
||||
baphysics_set_vertical_velocity(D_8037D398);
|
||||
}
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
next_state = BS_2D_SWIM_IDLE;
|
||||
}
|
||||
if (!player_inWater()) {
|
||||
|
|
|
@ -190,7 +190,7 @@ enum bs_e func_802A8D84(enum bs_e arg0){
|
|||
if( func_8029B300(arg0) > 0)
|
||||
arg0 = BS_16_BTROT_WALK;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
arg0 = badrone_look();
|
||||
|
||||
if(func_8028B094())
|
||||
|
@ -405,7 +405,7 @@ void bsbtrot_jump_update(void){
|
|||
break;
|
||||
case 2://L802A95C4
|
||||
func_80299628(1);
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029C5E8();
|
||||
animctrl_setSubRange(aCtrl, 0.0f, 0.8798f);
|
||||
animctrl_setDuration(aCtrl, 0.9f);
|
||||
|
@ -457,13 +457,13 @@ void bsbtrot_jump_update(void){
|
|||
if(should_peck())
|
||||
sp2C = BS_11_BPECK;
|
||||
|
||||
if(func_8028B424())
|
||||
if(player_isFallTumbling())
|
||||
sp2C = BS_3D_FALL_TUMBLING;
|
||||
|
||||
if(player_inWater())
|
||||
sp2C = BS_4C_LANDING_IN_WATER;
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if(button_pressed(BUTTON_A))
|
||||
sp2C = func_802A8D34(sp2C);
|
||||
|
||||
|
@ -540,7 +540,7 @@ void bsbtrot_slide_update(void){
|
|||
if(player_inWater())
|
||||
sp3C = BS_2D_SWIM_IDLE;
|
||||
|
||||
if(D_8037D3A0 == 0.0f && button_pressed(BUTTON_A) && func_8028B2E8())
|
||||
if(D_8037D3A0 == 0.0f && button_pressed(BUTTON_A) && player_isStable())
|
||||
sp3C = func_802A8D34(sp3C);
|
||||
|
||||
|
||||
|
@ -605,7 +605,7 @@ void bsbtrot_fall_update(void){
|
|||
break;
|
||||
case 1://L802A9DDC
|
||||
func_80299628(1);
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029C5E8();
|
||||
animctrl_setSubRange(aCtrl, 0.0f, 0.8798f);
|
||||
animctrl_setDuration(aCtrl, 0.9f);
|
||||
|
@ -660,10 +660,10 @@ void bsbtrot_fall_update(void){
|
|||
if(player_inWater())
|
||||
sp2C = BS_4C_LANDING_IN_WATER;
|
||||
|
||||
if(func_8028B424())
|
||||
if(player_isFallTumbling())
|
||||
sp2C = BS_3D_FALL_TUMBLING;
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if(button_pressed(BUTTON_A))
|
||||
sp2C = func_802A8D34(sp2C);
|
||||
|
||||
|
@ -736,10 +736,10 @@ void bsbtrot_ow_update(void){
|
|||
if(baanim_isAt(0.3f))
|
||||
func_80292EA4();
|
||||
|
||||
if(func_8028B424())
|
||||
if(player_isFallTumbling())
|
||||
sp1C = BS_3D_FALL_TUMBLING;
|
||||
|
||||
if(func_8028B2E8() && baanim_isStopped())
|
||||
if(player_isStable() && baanim_isStopped())
|
||||
sp1C = BS_15_BTROT_IDLE;
|
||||
|
||||
if(animctrl_isStopped(baanim_getAnimCtrlPtr()) && player_inWater())
|
||||
|
|
|
@ -56,7 +56,7 @@ enum bs_e func_802AA510(enum bs_e arg0){
|
|||
if(button_released(BUTTON_Z))
|
||||
arg0 = BS_1E_WONDERWING_EXIT;
|
||||
|
||||
if(button_pressed(BUTTON_A) && func_8028B2E8())
|
||||
if(button_pressed(BUTTON_A) && player_isStable())
|
||||
arg0 = BS_1D_WONDERWING_JUMP;
|
||||
|
||||
if(player_inWater())
|
||||
|
@ -151,7 +151,7 @@ void bsbwhirl_walk_update(void){
|
|||
if(button_released(BUTTON_Z))
|
||||
sp1C = BS_1E_WONDERWING_EXIT;
|
||||
|
||||
if(button_pressed(BUTTON_A) && func_8028B2E8())
|
||||
if(button_pressed(BUTTON_A) && player_isStable())
|
||||
sp1C = BS_1D_WONDERWING_JUMP;
|
||||
|
||||
if(player_inWater())
|
||||
|
@ -217,7 +217,7 @@ void bsbwhirl_jump_update(void){
|
|||
if(player_inWater())
|
||||
sp2C = BS_2D_SWIM_IDLE;
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
D_8037D3B4 = 2;
|
||||
func_8029C5E8();
|
||||
}
|
||||
|
|
|
@ -135,7 +135,7 @@ void bsbbuster_update(void){
|
|||
if(D_8037D2B7 == 2){
|
||||
D_8037D2B7 = 0;
|
||||
}
|
||||
if(func_8028B2E8() || D_8037D2B9 || !(D_8037D2BC < 4)){
|
||||
if(player_isStable() || D_8037D2B9 || !(D_8037D2BC < 4)){
|
||||
func_802BB3DC( 0, 45.0f, 0.71f);
|
||||
func_8029AE74(0);
|
||||
func_8029FB30();
|
||||
|
@ -183,7 +183,7 @@ void bsbbuster_update(void){
|
|||
animctrl_setDuration(aCtrl, 15.0f);
|
||||
animctrl_setPlaybackType(aCtrl, ANIMCTRL_ONCE);
|
||||
}
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
animctrl_setSubRange(aCtrl, 0.0f, 1.0f);
|
||||
animctrl_setDuration(aCtrl, 1.9f);
|
||||
animctrl_setPlaybackType(aCtrl, ANIMCTRL_ONCE);
|
||||
|
|
|
@ -253,7 +253,7 @@ void bsbeefly_update(void){
|
|||
sp38 += (f64)sp38;
|
||||
}
|
||||
baphysics_set_target_horizontal_velocity(sp38);
|
||||
if(func_8028B2E8() && !player_inWater())
|
||||
if(player_isStable() && !player_inWater())
|
||||
sp4C = BS_85_BEE_IDLE;
|
||||
func_8028FFF0();
|
||||
bs_setState(sp4C);
|
||||
|
|
|
@ -73,7 +73,7 @@ void func_802A10D4(void){
|
|||
if(func_8028B094())
|
||||
s0 = 0x88;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
s0 = badrone_look();
|
||||
|
||||
if(func_8029B300() > 0)
|
||||
|
@ -188,7 +188,7 @@ void func_802A1438(void){
|
|||
break;
|
||||
case 2:
|
||||
func_80299628(0);
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_802A0F90();
|
||||
baanim_setEndAndDuration(1.0f, 0.7f);
|
||||
D_8037D2D4 = 3;
|
||||
|
@ -202,7 +202,7 @@ void func_802A1438(void){
|
|||
}
|
||||
break;
|
||||
}
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if(func_8029B300() > 0)
|
||||
sp2c = BS_BEE_WALK;
|
||||
if(button_pressed(BUTTON_A)){
|
||||
|
@ -259,7 +259,7 @@ void func_802A170C(void){
|
|||
break;
|
||||
case 1:
|
||||
func_80299628(0);
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_802A0F90();
|
||||
baphysics_set_target_horizontal_velocity(0.0f);
|
||||
baanim_setEndAndDuration(1.0f, 0.7f);
|
||||
|
@ -274,7 +274,7 @@ void func_802A170C(void){
|
|||
}
|
||||
break;
|
||||
}
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if(miscflag_isTrue(0x19)){
|
||||
sp2c = badrone_transform();
|
||||
}else{
|
||||
|
@ -352,7 +352,7 @@ void func_802A1A50(void){
|
|||
case 1:
|
||||
break;
|
||||
}
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
sp1C = BS_85_BEE_IDLE;
|
||||
if(0.65 < baanim_getTimer() && player_inWater()){
|
||||
sp1C = 0x8C;
|
||||
|
@ -436,7 +436,7 @@ void func_802A1DD8(void){
|
|||
func_80299628(0);
|
||||
switch(D_8037D2D4){
|
||||
case 0:
|
||||
if(!func_8028B2E8())
|
||||
if(!player_isStable())
|
||||
break;
|
||||
baanim_setEnd(0.7453f);
|
||||
FUNC_8030E624(SFX_1F_HITTING_AN_ENEMY_3, 0.8f, 18000);
|
||||
|
@ -445,7 +445,7 @@ void func_802A1DD8(void){
|
|||
D_8037D2D4 = 1;
|
||||
break;
|
||||
case 1:
|
||||
if(!func_8028B2E8())
|
||||
if(!player_isStable())
|
||||
break;
|
||||
baanim_setEnd(1.0f);
|
||||
FUNC_8030E624(SFX_1F_HITTING_AN_ENEMY_3, 0.8f, 18000);
|
||||
|
|
|
@ -54,14 +54,14 @@ void bsclaw_update(void){
|
|||
if(animctrl_isStopped(aCtrl))
|
||||
sp2C = BS_1_IDLE;
|
||||
|
||||
if(!func_8028B2E8())
|
||||
if(!player_isStable())
|
||||
sp2C = BS_2F_FALL;
|
||||
|
||||
if(player_inWater())
|
||||
sp2C = BS_4C_LANDING_IN_WATER;
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
sp2C = func_8029C780();
|
||||
sp2C = bs_getTypeOfJump();
|
||||
|
||||
bs_setState(sp2C);
|
||||
}
|
||||
|
|
|
@ -121,7 +121,7 @@ void bscroc_idle_update(void){
|
|||
if(func_8028B094())
|
||||
next_state = BS_61_CROC_FALL;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
if(func_8029B300() > 0)
|
||||
|
@ -235,7 +235,7 @@ void bscroc_jump_update(void){
|
|||
break;
|
||||
case 2:
|
||||
func_80299628(0);
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029AE48();
|
||||
baanim_setEndAndDuration(1.0f, 1.0f);
|
||||
D_8037D3EC = 3;
|
||||
|
@ -250,7 +250,7 @@ void bscroc_jump_update(void){
|
|||
break;
|
||||
}//L802AC66C
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if(func_8029B300() > 0)
|
||||
sp2C = BS_CROC_WALK;
|
||||
|
||||
|
@ -300,7 +300,7 @@ void bscroc_fall_update(void){
|
|||
}
|
||||
break;
|
||||
case 1:
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029AE48();
|
||||
baphysics_set_target_horizontal_velocity(0.0f);
|
||||
baanim_setEndAndDuration(1.0f, 1.0f);
|
||||
|
@ -310,7 +310,7 @@ void bscroc_fall_update(void){
|
|||
break;
|
||||
}//L802AC850
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if(func_8029B300() > 0 || (D_8037D3EC == 2 && animctrl_isStopped(aCtrl))){
|
||||
if(miscflag_isTrue(0x19)){
|
||||
next_state = badrone_transform();
|
||||
|
@ -376,7 +376,7 @@ static void __bscroc_recoil_update(void){
|
|||
case 1:
|
||||
break;
|
||||
}
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
next_state = BS_5E_CROC_IDLE;
|
||||
|
||||
bs_setState(next_state);
|
||||
|
@ -458,7 +458,7 @@ void bscroc_die_update(void){
|
|||
func_80299628(0);
|
||||
switch(D_8037D3EC){
|
||||
case 0:
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
baanim_setEnd(0.7453f);
|
||||
FUNC_8030E624(SFX_1F_HITTING_AN_ENEMY_3, 0.8f, 18000);
|
||||
FUNC_8030E624(SFX_39_BANJO_AYE_2, 1.8f, 18000);
|
||||
|
@ -467,7 +467,7 @@ void bscroc_die_update(void){
|
|||
}
|
||||
break;
|
||||
case 1:
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
baanim_setEnd(1.0f);
|
||||
FUNC_8030E624(SFX_1F_HITTING_AN_ENEMY_3, 0.8f, 18000);
|
||||
FUNC_8030E624(SFX_39_BANJO_AYE_2, 1.8f, 18000);
|
||||
|
@ -505,7 +505,7 @@ int bscroc_hitboxActive(void){
|
|||
static void func_802ACF58(void){
|
||||
f32 sp2C;
|
||||
f32 sp20[3];
|
||||
sp2C = func_8028B2E8() ? 500.0f : 400.0f;
|
||||
sp2C = player_isStable() ? 500.0f : 400.0f;
|
||||
func_802589E4(sp20, yaw_get(), sp2C);
|
||||
sp20[1] = 200.0f;
|
||||
baphysics_set_velocity(sp20);
|
||||
|
@ -549,7 +549,7 @@ void bscroc_bite_update(void){
|
|||
next_state = BS_CROC_WALK;
|
||||
}
|
||||
|
||||
if(func_8028B2E8() && button_pressed(BUTTON_A))
|
||||
if(player_isStable() && button_pressed(BUTTON_A))
|
||||
next_state = BS_CROC_JUMP;
|
||||
|
||||
bs_setState(next_state);
|
||||
|
|
|
@ -183,7 +183,7 @@ enum bs_e func_802ADCD4(enum bs_e arg0){
|
|||
arg0 = BS_CLAW;
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
arg0 = func_8029C780();
|
||||
arg0 = bs_getTypeOfJump();
|
||||
|
||||
}else{
|
||||
if(should_wonderwing())
|
||||
|
|
|
@ -10,7 +10,7 @@ s32 D_8037D414;
|
|||
|
||||
/* .code */
|
||||
int _bsdie_802ADE00(void){
|
||||
return func_8028B2E8();
|
||||
return player_isStable();
|
||||
}
|
||||
|
||||
void _bsdie_802ADE20(void){
|
||||
|
|
|
@ -40,7 +40,7 @@ void func_802AEC08(void){
|
|||
|
||||
void func_802AEC28(void){
|
||||
baphysics_reset_horizontal_velocity();
|
||||
if(func_8028B2E8() || player_inWater())
|
||||
if(player_isStable() || player_inWater())
|
||||
__bsDroneGoTo_set_substate(2);
|
||||
}
|
||||
|
||||
|
@ -91,7 +91,7 @@ void func_802AEDC8(void){
|
|||
void bsDroneGoTo_init(void){
|
||||
bsdronetogo_substate = 0;
|
||||
func_8031F9F4(1);
|
||||
if( !func_8028B2E8() && func_8029BDE8()){
|
||||
if( !player_isStable() && func_8029BDE8()){
|
||||
__bsDroneGoTo_set_substate(1);
|
||||
}else{
|
||||
__bsDroneGoTo_set_substate(2);
|
||||
|
|
|
@ -30,7 +30,7 @@ void bsDroneLook_init(void) {
|
|||
eye_rotation[1] += 180.0f;
|
||||
eye_rotation[2] = 0.0f;
|
||||
ncFirstPersonCamera_setZoomedOutRotation(eye_rotation);
|
||||
miscflag_set(0x17);
|
||||
miscflag_set(MISC_FLAG_17_FPV);
|
||||
}
|
||||
|
||||
void bsDroneLook_update(void) {
|
||||
|
@ -42,7 +42,7 @@ void bsDroneLook_update(void) {
|
|||
|
||||
next_state = 0;
|
||||
dt = time_getDelta();
|
||||
if (ncFirstPersonCamera_getState() == 2) {
|
||||
if (ncFirstPersonCamera_getState() == FIRSTPERSON_STATE_2_IDLE) {
|
||||
//camera is in "idle" state
|
||||
ncFirstPersonCamera_getZoomedInRotation(eye_rotation);
|
||||
eye_rotation[0] -= func_8029B2DC() * 90.0f * dt;
|
||||
|
@ -59,7 +59,7 @@ void bsDroneLook_update(void) {
|
|||
}
|
||||
// 1st person cancelled via entering water
|
||||
if (player_inWater()) {
|
||||
if (player_getTransformation() == TRANSFORM_1_BANJO && func_8028EE84() == BSWATERGROUP_0_NONE) {
|
||||
if (player_getTransformation() == TRANSFORM_1_BANJO && player_getWaterState() == BSWATERGROUP_0_NONE) {
|
||||
exit_first_person += TRUE;
|
||||
}
|
||||
} else if (func_8028B254(25) == 0) {
|
||||
|
@ -79,5 +79,5 @@ void bsDroneLook_end(void) {
|
|||
func_80299D2C(SFX_12E_CAMERA_ZOOM_MEDIUM, 1.2f, 12000);
|
||||
}
|
||||
ncDynamicCamera_exitFirstPerson();
|
||||
miscflag_clear(0x17);
|
||||
miscflag_clear(MISC_FLAG_17_FPV);
|
||||
}
|
||||
|
|
|
@ -134,7 +134,7 @@ void bsjump_update(void){
|
|||
break;
|
||||
}//L802B1548
|
||||
|
||||
if(func_8028B424())
|
||||
if(player_isFallTumbling())
|
||||
sp34 = BS_3D_FALL_TUMBLING;
|
||||
|
||||
if(button_released(BUTTON_A))
|
||||
|
@ -149,7 +149,7 @@ void bsjump_update(void){
|
|||
if(should_beak_bust())
|
||||
sp34 = BS_F_BBUSTER;
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029C5E8();
|
||||
sp34 = BS_20_LANDING;
|
||||
}
|
||||
|
@ -214,7 +214,7 @@ void bsjump_fall_update(void){
|
|||
break;
|
||||
}//L802B1824
|
||||
if(miscflag_isFalse(0xf)){
|
||||
if(func_8028B424())
|
||||
if(player_isFallTumbling())
|
||||
sp2C = BS_3D_FALL_TUMBLING;
|
||||
|
||||
if(should_feathery_flap() && miscflag_isFalse(MISC_FLAG_5_HAS_PECKED))
|
||||
|
@ -237,7 +237,7 @@ void bsjump_fall_update(void){
|
|||
|
||||
}//L802B18E8
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029C5E8();
|
||||
sp2C = BS_20_LANDING;
|
||||
}
|
||||
|
@ -311,7 +311,7 @@ void func_802B1A54(void) {
|
|||
case 2:
|
||||
break;
|
||||
}
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
func_8029C5E8();
|
||||
next_state = BS_20_LANDING;
|
||||
}
|
||||
|
@ -371,7 +371,7 @@ void func_802B1CF8(void) {
|
|||
case 1:
|
||||
break;
|
||||
}
|
||||
if (func_8028B2E8() != 0) {
|
||||
if (player_isStable() != 0) {
|
||||
next_state = 1;
|
||||
}
|
||||
bs_setState(next_state);
|
||||
|
@ -424,7 +424,7 @@ void bsjump_tumble_update(void){
|
|||
if(player_inWater())
|
||||
sp1C = BS_4C_LANDING_IN_WATER;
|
||||
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
sp1C = BS_SPLAT;
|
||||
|
||||
bs_setState(sp1C);
|
||||
|
|
|
@ -50,10 +50,10 @@ void bsow_update(void) {
|
|||
if (baanim_isAt(0.3f) != 0) {
|
||||
func_80292EA4();
|
||||
}
|
||||
if (func_8028B424() != 0) {
|
||||
if (player_isFallTumbling() != 0) {
|
||||
sp1C = BS_3D_FALL_TUMBLING;
|
||||
}
|
||||
if (func_8028B2E8() != 0) {
|
||||
if (player_isStable() != 0) {
|
||||
sp1C = BS_2_WALK_SLOW;
|
||||
}
|
||||
if ((player_inWater() != 0) && (baphysics_get_vertical_velocity() <= 0.0f)) {
|
||||
|
|
|
@ -92,7 +92,7 @@ void bspumpkin_idle_update(void) {
|
|||
if (func_8028B094()) {
|
||||
next_state = BS_4B_PUMPKIN_FALL;
|
||||
}
|
||||
if (func_80294F78()) {
|
||||
if (should_look_first_person_camera()) {
|
||||
next_state = badrone_look();
|
||||
}
|
||||
if (func_8029B300() > 0) {
|
||||
|
@ -208,7 +208,7 @@ void bspumpkin_jump_update(void) {
|
|||
}
|
||||
break;
|
||||
case 2:
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
func_8029AE48();
|
||||
animctrl_setSubRange(anim_ctrl, 0.0f, 1.0f);
|
||||
animctrl_setDuration(anim_ctrl, 1.2f);
|
||||
|
@ -224,7 +224,7 @@ void bspumpkin_jump_update(void) {
|
|||
}
|
||||
break;
|
||||
}
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
if (func_8029B300() > 0) {
|
||||
next_state = BS_49_PUMPKIN_WALK;
|
||||
}
|
||||
|
@ -277,7 +277,7 @@ void bspumpkin_fall_update(void) {
|
|||
}
|
||||
break;
|
||||
case 1:
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
func_8029AE48();
|
||||
baphysics_set_target_horizontal_velocity(0.0f);
|
||||
animctrl_setSubRange(anim_ctrl, 0.0f, 1.0f);
|
||||
|
@ -289,7 +289,7 @@ void bspumpkin_fall_update(void) {
|
|||
case 2:
|
||||
break;
|
||||
}
|
||||
if (func_8028B2E8() && ((func_8029B300() > 0) || (D_8037D4E0 == 2 && animctrl_isStopped(anim_ctrl)))) {
|
||||
if (player_isStable() && ((func_8029B300() > 0) || (D_8037D4E0 == 2 && animctrl_isStopped(anim_ctrl)))) {
|
||||
if (miscflag_isTrue(0x19)) {
|
||||
next_state = badrone_transform();
|
||||
} else {
|
||||
|
@ -475,7 +475,7 @@ void bspumpkin_die_update(void){
|
|||
break;
|
||||
|
||||
case 1://L802B32AC
|
||||
if(func_8028B2E8()) {
|
||||
if(player_isStable()) {
|
||||
func_8029AE48();
|
||||
FUNC_8030E624(SFX_1F_HITTING_AN_ENEMY_3, 0.8f, 18000);
|
||||
FUNC_8030E624(SFX_39_BANJO_AYE_2, 1.8f, 18000);
|
||||
|
@ -502,7 +502,7 @@ void bspumpkin_die_update(void){
|
|||
|
||||
case 4://L802B3384
|
||||
D_8037D4F4 = ml_max_f(0.0f, D_8037D4F4 - 10.0f);
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
func_8029AE48();
|
||||
FUNC_8030E624(SFX_1F_HITTING_AN_ENEMY_3, 0.8f, 18000);
|
||||
FUNC_8030E624(SFX_39_BANJO_AYE_2, 1.8f, 18000);
|
||||
|
|
|
@ -118,10 +118,10 @@ void func_802B3954(void) {
|
|||
baMarker_collisionOn();
|
||||
}
|
||||
func_802B37DC();
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
next_state = BS_20_LANDING;
|
||||
}
|
||||
if (func_8028B424() && D_8037D500 == 0) {
|
||||
if (player_isFallTumbling() && D_8037D500 == 0) {
|
||||
next_state = BS_3D_FALL_TUMBLING;
|
||||
}
|
||||
if (animctrl_isStopped(anim_ctrl) && func_8028B094() && (D_8037D500 == 0)) {
|
||||
|
|
|
@ -111,7 +111,7 @@ void bsslide_update(void){
|
|||
sp3C = BS_4C_LANDING_IN_WATER;
|
||||
|
||||
if(D_8037D528 == 0.0f && button_pressed(BUTTON_A))
|
||||
sp3C = func_8029C780();
|
||||
sp3C = bs_getTypeOfJump();
|
||||
|
||||
bs_setState(sp3C);
|
||||
}
|
||||
|
|
|
@ -76,7 +76,7 @@ void bssplat_update(void){
|
|||
break;
|
||||
}//L802B4808
|
||||
|
||||
if(func_8028B2E8() == 0 && player_inWater())
|
||||
if(player_isStable() == 0 && player_inWater())
|
||||
sp1C = BS_2D_SWIM_IDLE;
|
||||
|
||||
bs_setState(sp1C);
|
||||
|
|
|
@ -71,9 +71,9 @@ s32 func_802B488C(s32 arg0){
|
|||
retVal = BS_CLAW;
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
retVal = func_8029C780();
|
||||
retVal = bs_getTypeOfJump();
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
retVal = badrone_look();
|
||||
|
||||
if(player_isSliding())
|
||||
|
|
|
@ -152,10 +152,10 @@ void func_802B5950(void) {
|
|||
|
||||
next_state = 0;
|
||||
anim_ctrl = baanim_getAnimCtrlPtr();
|
||||
if ((func_8023DB4C(7) == 0) && ((f64) randf() < 0.5)) {
|
||||
if ((globalTimer_getTimeMasked(7) == 0) && ((f64) randf() < 0.5)) {
|
||||
func_8029C304(1);
|
||||
}
|
||||
if ((func_8023DB4C(7) == 0) && ((f64) randf() < 0.5)) {
|
||||
if ((globalTimer_getTimeMasked(7) == 0) && ((f64) randf() < 0.5)) {
|
||||
func_802B5480();
|
||||
}
|
||||
if (animctrl_isAt(anim_ctrl, 0.01f) != 0) {
|
||||
|
@ -170,7 +170,7 @@ void func_802B5950(void) {
|
|||
if (!player_inWater()) {
|
||||
next_state = BS_1_IDLE;
|
||||
}
|
||||
if (func_80294F78()) {
|
||||
if (should_look_first_person_camera()) {
|
||||
next_state = badrone_look();
|
||||
}
|
||||
if (should_dive()) {
|
||||
|
|
|
@ -60,7 +60,7 @@ void bsturn_update(void){
|
|||
sp2C = BS_CLAW;
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
sp2C = func_8029C780();
|
||||
sp2C = bs_getTypeOfJump();
|
||||
|
||||
bs_setState(sp2C);
|
||||
}
|
||||
|
|
|
@ -66,9 +66,9 @@ void bstwirl_update(void){
|
|||
}//L802B6C4C
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
sp1C = func_8029C780();
|
||||
sp1C = bs_getTypeOfJump();
|
||||
|
||||
if(0.6 < animctrl_getAnimTimer(aCtrl) && !func_8028B2E8())
|
||||
if(0.6 < animctrl_getAnimTimer(aCtrl) && !player_isStable())
|
||||
sp1C = BS_2F_FALL;
|
||||
|
||||
if(player_inWater())
|
||||
|
|
|
@ -162,7 +162,7 @@ void bswalk_creep_update(void){
|
|||
if(func_8028B128())
|
||||
next_state = BS_WALK_MUD;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
if(func_8028B094())
|
||||
|
@ -174,7 +174,7 @@ void bswalk_creep_update(void){
|
|||
next_state = func_802B6F20(next_state);
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
next_state = func_8029C780();
|
||||
next_state = bs_getTypeOfJump();
|
||||
|
||||
if(player_isSliding())
|
||||
next_state = BS_SLIDE;
|
||||
|
@ -235,7 +235,7 @@ void bswalk_slow_upate(void){
|
|||
if(func_8028B128())
|
||||
next_state = BS_WALK_MUD;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
if(func_8028B094())
|
||||
|
@ -247,7 +247,7 @@ void bswalk_slow_upate(void){
|
|||
next_state = func_802B6F20(next_state);
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
next_state = func_8029C780();
|
||||
next_state = bs_getTypeOfJump();
|
||||
|
||||
if(player_isSliding())
|
||||
next_state = BS_SLIDE;
|
||||
|
@ -311,7 +311,7 @@ void bswalk_update(void){
|
|||
next_state = BS_SKID;
|
||||
}
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
if(func_8028B094())
|
||||
|
@ -323,7 +323,7 @@ void bswalk_update(void){
|
|||
next_state = func_802B6F20(next_state);
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
next_state = func_8029C780();
|
||||
next_state = bs_getTypeOfJump();
|
||||
|
||||
if(player_isSliding())
|
||||
next_state = BS_SLIDE;
|
||||
|
@ -386,7 +386,7 @@ void bswalk_fast_update(void){
|
|||
if(baphysics_is_slower_than(18.0f))
|
||||
next_state = BS_1_IDLE;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
break;
|
||||
|
@ -395,7 +395,7 @@ void bswalk_fast_update(void){
|
|||
if(baphysics_is_slower_than(bsWalkSlowWalkWalkVelocityThreshold))
|
||||
next_state = BS_2_WALK_SLOW;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
break;
|
||||
|
@ -403,7 +403,7 @@ void bswalk_fast_update(void){
|
|||
if(baphysics_is_slower_than(bsWalkWalkFastWalkVelocityThreshold) && func_802B6EF4())
|
||||
next_state = BS_WALK;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
break;
|
||||
}//L802B7AA4
|
||||
|
@ -423,7 +423,7 @@ void bswalk_fast_update(void){
|
|||
next_state = func_802B6F20(next_state);
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
next_state = func_8029C780();
|
||||
next_state = bs_getTypeOfJump();
|
||||
|
||||
if(player_isSliding())
|
||||
next_state = BS_SLIDE;
|
||||
|
@ -460,7 +460,7 @@ void bswalk_mud_update(void){
|
|||
if(!func_8029B300())
|
||||
next_state = BS_1_IDLE;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
if(func_8028B094())
|
||||
|
@ -472,7 +472,7 @@ void bswalk_mud_update(void){
|
|||
next_state = func_802B6F20(next_state);
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
next_state = func_8029C780();
|
||||
next_state = bs_getTypeOfJump();
|
||||
|
||||
if(player_isSliding())
|
||||
next_state = BS_SLIDE;
|
||||
|
|
|
@ -162,7 +162,7 @@ void bswalrus_idle_update(void){
|
|||
if(func_8028B094())
|
||||
next_state = BS_6A_WALRUS_FALL;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
if(func_8029B300() > 0)
|
||||
|
@ -270,7 +270,7 @@ void bswalrus_jump_update(void){
|
|||
break;
|
||||
case 2://L802B87B4
|
||||
func_80299628(0);
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029AE48();
|
||||
animctrl_setSubRange(aCtrl, 0.0f, 1.0f);
|
||||
animctrl_setDuration(aCtrl, 1.0f);
|
||||
|
@ -287,7 +287,7 @@ void bswalrus_jump_update(void){
|
|||
break;
|
||||
}//L802B8838
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if(func_8029B300() > 0)
|
||||
next_state = BS_WALRUS_WALK;
|
||||
|
||||
|
@ -335,7 +335,7 @@ void bswalrus_fall_update(void){
|
|||
}
|
||||
break;
|
||||
case 1://L802B89E0
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029AE48();
|
||||
baphysics_set_target_horizontal_velocity(0.0f);
|
||||
animctrl_setSubRange(aCtrl, 0.0f, 1.0f);
|
||||
|
@ -348,7 +348,7 @@ void bswalrus_fall_update(void){
|
|||
break;
|
||||
}//L802B8A38
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if( func_8029B300() > 0
|
||||
|| (D_8037D5C8 == 2 && animctrl_isStopped(aCtrl))
|
||||
){
|
||||
|
@ -399,7 +399,7 @@ static void __bswalrus_recoil_update(void){
|
|||
if(baanim_isAt(0.5f))
|
||||
func_80292EA4();
|
||||
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
next_state = BS_67_WALRUS_IDLE;
|
||||
|
||||
bs_setState(next_state);
|
||||
|
@ -483,7 +483,7 @@ void bswalrus_die_update(void){
|
|||
func_80299628(0);
|
||||
switch(D_8037D5C8){
|
||||
case 0://L802B8F54
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
baanim_setEnd(1.0f);
|
||||
FUNC_8030E624(SFX_1F_HITTING_AN_ENEMY_3, 0.8f, 18000);
|
||||
FUNC_8030E624(SFX_39_BANJO_AYE_2, 1.8f, 18000);
|
||||
|
@ -568,7 +568,7 @@ void bswalrus_sled_update(void){
|
|||
f32 sp20[3];
|
||||
|
||||
if(50.0f < baphysics_get_horizontal_velocity()){
|
||||
if(func_8023DB4C(1)){
|
||||
if(globalTimer_getTimeMasked(1)){
|
||||
baModel_80292554(&sp20);
|
||||
}else{
|
||||
baModel_80292578(&sp20);
|
||||
|
@ -578,7 +578,7 @@ void bswalrus_sled_update(void){
|
|||
|
||||
func_80299628(0);
|
||||
func_802B7F28();
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
next_state = badrone_look();
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
|
@ -648,7 +648,7 @@ void bswalrus_sled_jump_update(void){
|
|||
break;
|
||||
}//L802B9530
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if(button_pressed(BUTTON_A))
|
||||
next_state = BS_7E_WALRUS_SLED;
|
||||
|
||||
|
@ -693,7 +693,7 @@ void func_802B963C(void){
|
|||
}
|
||||
break;
|
||||
case 1://L802B96C0
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
func_8029AE48();
|
||||
baphysics_set_target_horizontal_velocity(0.0f);
|
||||
D_8037D5C8 = 2;
|
||||
|
@ -703,7 +703,7 @@ void func_802B963C(void){
|
|||
break;
|
||||
}//L802B96F0
|
||||
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
if( func_8029B300() > 0
|
||||
|| (D_8037D5C8 == 2 && animctrl_isStopped(aCtrl))
|
||||
){
|
||||
|
|
|
@ -58,15 +58,15 @@ void func_802B9B14(void){
|
|||
|
||||
switch(D_8037D5D0){
|
||||
case 0: // L802B9B48
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
func_802B9980(1);
|
||||
break;
|
||||
case 1: // L802B9B68
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
func_802B9980(2);
|
||||
break;
|
||||
case 2: // L802B9B88
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
func_802B9980(3);
|
||||
break;
|
||||
case 3: // L802B9BA8
|
||||
|
|
|
@ -27,7 +27,7 @@ void chBadShad_update(Actor *this){
|
|||
this->initialized = 1;
|
||||
this->marker->collidable = 0;
|
||||
}
|
||||
if(!this->despawn_flag && this->unk1C_x < (f32)(func_8023DB5C() - 1) ){
|
||||
if(!this->despawn_flag && this->unk1C_x < (f32)(globalTimer_getTime() - 1) ){
|
||||
//unlink
|
||||
if(this->unk104){
|
||||
marker_getActor(this->unk104)->unk104 = 0;
|
||||
|
@ -116,7 +116,7 @@ void func_802D71A0(s32 this, s32 arg1){
|
|||
if(sp3C){
|
||||
marker_getActor(marker)->unk104 = sp3C->marker;
|
||||
sp3C->unk104 = marker;
|
||||
sp3C->unk1C[0] = func_8023DB5C();
|
||||
sp3C->unk1C[0] = globalTimer_getTime();
|
||||
sp3C->unk1C[1] = sp40;
|
||||
sp3C->unk28 = sp28;
|
||||
}
|
||||
|
@ -145,7 +145,7 @@ void func_802D729C(Actor *actor, f32 arg1){
|
|||
if(sp1C->despawn_flag == TRUE)
|
||||
return;
|
||||
|
||||
if(!((func_8023DB5C() ^ actor->marker->actrArrayIdx) & 0x7)){
|
||||
if(!((globalTimer_getTime() ^ actor->marker->actrArrayIdx) & 0x7)){
|
||||
sp1C->unk28 = func_802D7038(actor);
|
||||
sp1C->position_x = D_8037DE10[0];
|
||||
sp1C->position_y = D_8037DE10[1] + 6.0f;
|
||||
|
@ -158,6 +158,6 @@ void func_802D729C(Actor *actor, f32 arg1){
|
|||
sp1C->position_x = actor->position_x;
|
||||
sp1C->position_z = actor->position_z;
|
||||
}
|
||||
sp1C->unk1C[0] = func_8023DB5C();
|
||||
sp1C->unk1C[0] = globalTimer_getTime();
|
||||
sp1C->unk1C[1] = arg1;
|
||||
}
|
||||
|
|
|
@ -74,7 +74,7 @@ void func_802C5FF8(Actor *this){
|
|||
if( !this->unk138_28
|
||||
&& actor_animationIsAt(this, 0.4f)
|
||||
&& randf() < 0.14
|
||||
&& func_8028EE84() != BSWATERGROUP_2_UNDERWATER
|
||||
&& player_getWaterState() != BSWATERGROUP_2_UNDERWATER
|
||||
){
|
||||
func_8030E878(SFX_2B_BULL_MOO_1, randf2(0.9f, 1.1f), 32000, this->position, 0.0f, 2000.0f);
|
||||
}
|
||||
|
@ -136,7 +136,7 @@ void func_802C6240(Actor *this){
|
|||
|| actor_animationIsAt(this, 0.4f)
|
||||
|| actor_animationIsAt(this, 0.536f)
|
||||
){
|
||||
if(func_8028EE84() != BSWATERGROUP_2_UNDERWATER){
|
||||
if(player_getWaterState() != BSWATERGROUP_2_UNDERWATER){
|
||||
func_8030E878(SFX_C8_CRUNCH,randf2(0.93f, 1.07f),10000, this->position, 0.0f, 1800.0f);
|
||||
}
|
||||
}
|
||||
|
@ -161,13 +161,13 @@ void func_802C6240(Actor *this){
|
|||
if(!func_80329030(this, 0) && func_80329480(this)){
|
||||
func_80328CEC(this, (s32)this->yaw, 90, 150);
|
||||
}//L802C64EC
|
||||
if(!(func_8023DB5C() & 0xf))
|
||||
if(!(globalTimer_getTime() & 0xf))
|
||||
func_80328CEC(this, (s32)this->yaw_ideal, 10, 20);
|
||||
|
||||
if(!(func_8023DB5C() & 0x7))
|
||||
if(!(globalTimer_getTime() & 0x7))
|
||||
subaddie_maybe_set_state_position_direction(this, 1, 0.16f, 1, 0.02f);
|
||||
|
||||
if( !(func_8023DB5C() & 0xf)
|
||||
if( !(globalTimer_getTime() & 0xf)
|
||||
&& func_80329078(this, (s32)this->yaw_ideal, 150)
|
||||
&& subaddie_maybe_set_state(this, 3, 0.13f)
|
||||
){
|
||||
|
@ -191,7 +191,7 @@ void func_802C6240(Actor *this){
|
|||
subaddie_set_state(this, 2);
|
||||
func_802C5E80(this);
|
||||
}
|
||||
if(!(func_8023DB5C() & 0xf) && subaddie_maybe_set_state(this, 2, 0.08f))
|
||||
if(!(globalTimer_getTime() & 0xf) && subaddie_maybe_set_state(this, 2, 0.08f))
|
||||
func_802C5E80(this);
|
||||
func_802C5EB8(this);
|
||||
break;
|
||||
|
@ -203,7 +203,7 @@ void func_802C6240(Actor *this){
|
|||
subaddie_set_state(this, 8);
|
||||
}
|
||||
func_802C5F44(this);
|
||||
if(actor_animationIsAt(this, 0.35f) && func_8028EE84() != BSWATERGROUP_2_UNDERWATER){
|
||||
if(actor_animationIsAt(this, 0.35f) && player_getWaterState() != BSWATERGROUP_2_UNDERWATER){
|
||||
func_8030E58C(SFX_3C_BULL_GROWN, randf()/10.0f + 1.0);
|
||||
this->unk10_12--;
|
||||
}
|
||||
|
@ -356,7 +356,7 @@ Actor *func_802C6E84(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
|
|||
}
|
||||
break;
|
||||
case 4://L802C6F50
|
||||
if((func_8023DB5C() & 1) == 1){
|
||||
if((globalTimer_getTime() & 1) == 1){
|
||||
if(func_80259808(actor->yaw)){
|
||||
func_802C6E3C(0xb, sp34);
|
||||
func_802C6E3C(0xa, sp34);
|
||||
|
@ -369,7 +369,7 @@ Actor *func_802C6E84(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
|
|||
break;
|
||||
case 1://L802C6FB4
|
||||
if(actor_animationIsAt(actor, 0.85f)
|
||||
&& (func_8023DB5C()& 0xe) == 8
|
||||
&& (globalTimer_getTime()& 0xe) == 8
|
||||
&& randf() < 0.6
|
||||
){
|
||||
func_8034A174(func_80329934(),5, sp40);
|
||||
|
|
|
@ -232,7 +232,7 @@ void chCrab_update(Actor *this) {
|
|||
static s32 D_803670B0 = 0;
|
||||
static s32 D_803670B4 = 0;
|
||||
|
||||
sp34 = func_8023DB5C();
|
||||
sp34 = globalTimer_getTime();
|
||||
sp30 = time_getDelta();
|
||||
is_mutant_snippet = this->modelCacheIndex == ACTOR_F5_MUTIE_SNIPPET;
|
||||
if (!this->unk16C_4) {
|
||||
|
@ -343,7 +343,7 @@ void chCrab_update(Actor *this) {
|
|||
break;
|
||||
|
||||
case 4: //L802CC024
|
||||
if ((func_8023DB5C() & 0xF) == 9) {
|
||||
if ((globalTimer_getTime() & 0xF) == 9) {
|
||||
this->yaw_ideal = (f32) func_80329784(this);
|
||||
}
|
||||
func_80328FB0(this, 7.0f);
|
||||
|
|
|
@ -76,10 +76,10 @@ void chfirefx_update(Actor *this){
|
|||
}//L80359934
|
||||
if(subaddie_playerIsWithinSphere(this, 2000)){
|
||||
if( func_8024DB50(this->position, 50.0f) && this->unk38_31 ){
|
||||
if(!(func_8023DB5C() & 3) && randf() < 0.1){
|
||||
if(!(globalTimer_getTime() & 3) && randf() < 0.1){
|
||||
__chfirefx_spawnSmoke(this->position, this->scale);
|
||||
} //L803599AC
|
||||
if(!(func_8023DB5C() & 3) && randf() < 0.3){
|
||||
if(!(globalTimer_getTime() & 3) && randf() < 0.3){
|
||||
__chfirefx_spawnSpark(this->position, this->scale);
|
||||
}
|
||||
}//L803599F4
|
||||
|
|
|
@ -341,10 +341,10 @@ void func_802C4C14(Actor *this){
|
|||
switch(sp84){
|
||||
case 0://L802C4D8C
|
||||
if(actor_animationIsAt(this, 0.1f))
|
||||
func_8030E510(SFX_5D_BANJO_RAAOWW, 8000);
|
||||
sfxsource_play(SFX_5D_BANJO_RAAOWW, 8000);
|
||||
|
||||
if(actor_animationIsAt(this, 0.7f))
|
||||
func_8030E510(SFX_5E_BANJO_PHEWWW, 8000);
|
||||
sfxsource_play(SFX_5E_BANJO_PHEWWW, 8000);
|
||||
break;
|
||||
case 1://L802C4DD0
|
||||
if(randf() < 0.1){
|
||||
|
@ -364,7 +364,7 @@ void func_802C4C14(Actor *this){
|
|||
switch(this->state){
|
||||
case 1://L802C4F10
|
||||
if(sp84 == 1){
|
||||
func_8030E510(SFX_136_GAMEBOY_STARTUP, 15000);
|
||||
sfxsource_play(SFX_136_GAMEBOY_STARTUP, 15000);
|
||||
timedFunc_set_3(0.25f, (GenFunction_3)comusic_8025AB44, COMUSIC_73_GAMEBOY, -1, 2000);
|
||||
func_8025A58C(0, 2000);
|
||||
}
|
||||
|
@ -441,20 +441,20 @@ void func_802C4C14(Actor *this){
|
|||
if(randf() < 0.1){
|
||||
switch(sp84){
|
||||
case 0://L802C52B8
|
||||
func_8030E510(SFX_31_BANJO_OHHWAAOOO, 28000);
|
||||
sfxsource_play(SFX_31_BANJO_OHHWAAOOO, 28000);
|
||||
func_8030E540(SFX_135_CARTOONY_SPRING);
|
||||
timedFunc_set_2(0.4f, (GenFunction_2)func_8030E510, SFX_13A_GLASS_BREAKING_7, 0x7fff);
|
||||
timedFunc_set_2(0.9f, (GenFunction_2)func_8030E510, SFX_150_PORCELAIN_CRASH, 0x7fff);
|
||||
timedFunc_set_2(1.0f, (GenFunction_2)func_8030E510, SFX_151_CAT_MEOW, 0x7fff);
|
||||
timedFunc_set_2(0.4f, (GenFunction_2)sfxsource_play, SFX_13A_GLASS_BREAKING_7, 0x7fff);
|
||||
timedFunc_set_2(0.9f, (GenFunction_2)sfxsource_play, SFX_150_PORCELAIN_CRASH, 0x7fff);
|
||||
timedFunc_set_2(1.0f, (GenFunction_2)sfxsource_play, SFX_151_CAT_MEOW, 0x7fff);
|
||||
break;
|
||||
case 1://L802C5320
|
||||
timedFunc_set_2(0.4f, (GenFunction_2)func_8030E510, SFX_31_BANJO_OHHWAAOOO, 28000);
|
||||
timedFunc_set_2(0.2f, (GenFunction_2)func_8030E510, SFX_E_SHOCKSPRING_BOING, 28000);
|
||||
timedFunc_set_2(0.4f, (GenFunction_2)sfxsource_play, SFX_31_BANJO_OHHWAAOOO, 28000);
|
||||
timedFunc_set_2(0.2f, (GenFunction_2)sfxsource_play, SFX_E_SHOCKSPRING_BOING, 28000);
|
||||
func_8030E540(SFX_2D_KABOING);
|
||||
break;
|
||||
case 2://L802C5364
|
||||
timedFunc_set_2(0.15f, (GenFunction_2)func_8030E510, SFX_32_BANJO_EGHEE, 28000);
|
||||
func_8030E510(SFX_3F6_UNKNOWN, 28000);
|
||||
timedFunc_set_2(0.15f, (GenFunction_2)sfxsource_play, SFX_32_BANJO_EGHEE, 28000);
|
||||
sfxsource_play(SFX_3F6_UNKNOWN, 28000);
|
||||
func_8030E540(SFX_8F_SNOWBALL_FLYING);
|
||||
break;
|
||||
}//L802C5394
|
||||
|
@ -466,7 +466,7 @@ void func_802C4C14(Actor *this){
|
|||
subaddie_set_state(this, 3);
|
||||
}
|
||||
}else{//L802C53D0
|
||||
func_8030E510(SFX_4F_BANJO_WAHOO, 28000);
|
||||
sfxsource_play(SFX_4F_BANJO_WAHOO, 28000);
|
||||
subaddie_set_state(this, 3);
|
||||
}//L802C53E8
|
||||
if(sp84 == 0)
|
||||
|
|
|
@ -200,7 +200,7 @@ void func_8035B8A8(Actor *this){
|
|||
|
||||
void func_8035B900(Actor *this){
|
||||
ActorLocal_Core2_D4050 *local = (ActorLocal_Core2_D4050 *)&this->local;
|
||||
s32 sp30 = func_8023DB5C();
|
||||
s32 sp30 = globalTimer_getTime();
|
||||
f32 sp2C = time_getDelta();
|
||||
if(!this->unk16C_4){
|
||||
this->unk16C_4 = TRUE;
|
||||
|
@ -346,7 +346,7 @@ void func_8035BD48(Actor *this){
|
|||
func_80343DEC(this);
|
||||
}
|
||||
|
||||
if((func_8023DB5C() &0x3F) == 7 && randf() < 0.7){
|
||||
if((globalTimer_getTime() &0x3F) == 7 && randf() < 0.7){
|
||||
func_8030E878(0x3f4, randf2(1.0f, 1.2f), 32000, this->position, this->scale*400.0f, this->scale*1800.0f);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -83,7 +83,7 @@ int func_80359F40(Actor *this, f32 arg1[3]){
|
|||
f32 sp20;
|
||||
|
||||
sp24 = func_80257204(this->position[0], this->position[2], arg1[0], arg1[2]);
|
||||
if((func_8023DB5C() & 0xF) == 4){
|
||||
if((globalTimer_getTime() & 0xF) == 4){
|
||||
this->velocity[2] = (f32)randi2(-45, 45);
|
||||
}
|
||||
sp20 = this->yaw;
|
||||
|
@ -177,7 +177,7 @@ void func_8035A694(Actor *this){
|
|||
|
||||
sp3C = this->yaw;
|
||||
sp38 = this->unk28*1.5 + 1.0;
|
||||
tmp_v0 = func_8023DB5C();
|
||||
tmp_v0 = globalTimer_getTime();
|
||||
this->yaw += sp38;
|
||||
if(360.0f < this->yaw)
|
||||
this->yaw -= 360.0f;
|
||||
|
|
|
@ -113,7 +113,7 @@ void chSnowball_update(Actor *this) {
|
|||
this->initialized = TRUE;
|
||||
player_getPosition(sp7C);
|
||||
sp7C[1] += 1.0f;
|
||||
phi_a1 = (func_8023DB5C() & 1) ? 0x15 : 0x2B;
|
||||
phi_a1 = (globalTimer_getTime() & 1) ? 0x15 : 0x2B;
|
||||
for(i = 0; i < 3; i++){
|
||||
sp58[i] = sp7C[i] + (sp7C[i] - this->unk1C[i]) * phi_a1;
|
||||
}
|
||||
|
|
|
@ -98,7 +98,7 @@ void __chSnowman_spawnHat(ActorMarker *marker){
|
|||
|
||||
other->velocity[0] = 34.0f;
|
||||
|
||||
sp28 = (func_8023DB5C() & 1)? 0x3C : 0x78;
|
||||
sp28 = (globalTimer_getTime() & 1)? 0x3C : 0x78;
|
||||
ml_vec3f_yaw_rotate_copy(other->velocity, other->velocity, other->yaw - sp28);
|
||||
other->velocity[1] = 30.0f;
|
||||
}
|
||||
|
@ -260,7 +260,7 @@ void chSnowman_update(Actor *this){
|
|||
|| fileProgressFlag_get(0x13)
|
||||
){//L802E2318
|
||||
if(0.0 < local->unk4){
|
||||
if( (func_8023DB5C() & 1)
|
||||
if( (globalTimer_getTime() & 1)
|
||||
|| func_8028ECAC() == BSGROUP_A_FLYING
|
||||
){//L802E236C
|
||||
local->unk4 -= dt;
|
||||
|
@ -269,7 +269,7 @@ void chSnowman_update(Actor *this){
|
|||
else{//L802E2380
|
||||
if( __chSnowman_isPlayerInAttackRange(this, 500, 2750)
|
||||
&& __chSnowman_isYawNearYawTarget(this, 3)
|
||||
&& func_8028EE84() != BSWATERGROUP_2_UNDERWATER
|
||||
&& player_getWaterState() != BSWATERGROUP_2_UNDERWATER
|
||||
&& !__chSnowman_CCW_playerInProtectedZone()
|
||||
){
|
||||
subaddie_set_state_with_direction(this, CHSNOWMAN_STATE_2_ATTACK, 0.01f, 1);
|
||||
|
@ -285,7 +285,7 @@ void chSnowman_update(Actor *this){
|
|||
else if(
|
||||
0.98 < animctrl_getAnimTimer(this->animctrl)
|
||||
|| !__chSnowman_isPlayerInAttackRange(this, 500, 2750)
|
||||
|| func_8028EE84() == BSWATERGROUP_2_UNDERWATER
|
||||
|| player_getWaterState() == BSWATERGROUP_2_UNDERWATER
|
||||
|| __chSnowman_CCW_playerInProtectedZone()
|
||||
){
|
||||
__chSnowman_enterIdle(this);
|
||||
|
|
|
@ -150,7 +150,7 @@ void chTermite_update(Actor *this) {
|
|||
static s32 D_80372F48 = 0;
|
||||
static s32 D_80372F4C = 0;
|
||||
|
||||
sp34 = func_8023DB5C();
|
||||
sp34 = globalTimer_getTime();
|
||||
if (!this->unk16C_4) {
|
||||
marker_setCollisionScripts(this->marker, NULL, __chTermite_ow, __chTermite_die);
|
||||
this->unk124_0 = this->unk138_31 = FALSE;
|
||||
|
|
|
@ -120,7 +120,7 @@ void func_80299EC0(f32 arg0[3]) {
|
|||
|
||||
if (D_8037C6F0.unk0 == 1) {
|
||||
sp78 = 50;
|
||||
} else if (func_8028EE84() == BSWATERGROUP_0_NONE) {
|
||||
} else if (player_getWaterState() == BSWATERGROUP_0_NONE) {
|
||||
sp78 = 200;
|
||||
} else {
|
||||
sp78 = 250;
|
||||
|
|
|
@ -455,7 +455,7 @@ enum bs_14420_e func_8029BAF0(void){
|
|||
return BS14420_D_WONDERWING;
|
||||
}
|
||||
if (player_inWater()) {
|
||||
switch(func_8028EE84()){
|
||||
switch(player_getWaterState()){
|
||||
case BSWATERGROUP_2_UNDERWATER:
|
||||
return BS14420_5_UNDERWATER;
|
||||
case BSWATERGROUP_1_SURFACE:
|
||||
|
@ -721,9 +721,9 @@ void func_8029C674(void) {
|
|||
f32 sp1C[3];
|
||||
|
||||
D_8037D1E8 = FALSE;
|
||||
if (func_80298850() == 4) {
|
||||
if (func_80298850() == BSGROUP_4_LOOK) {
|
||||
D_8037D1E8 = TRUE;
|
||||
miscflag_set(0x17);
|
||||
miscflag_set(MISC_FLAG_17_FPV);
|
||||
ncDynamicCamera_enterFirstPerson();
|
||||
func_8028E9C4(5, sp1C);
|
||||
ncFirstPersonCamera_setZoomedOutPosition(sp1C);
|
||||
|
@ -748,12 +748,12 @@ void func_8029C6D0(void) {
|
|||
|
||||
void func_8029C748(void) {
|
||||
if (D_8037D1E8) {
|
||||
miscflag_clear(0x17);
|
||||
miscflag_clear(MISC_FLAG_17_FPV);
|
||||
ncDynamicCamera_exitFirstPerson();
|
||||
}
|
||||
}
|
||||
|
||||
enum bs_e func_8029C780(void){
|
||||
enum bs_e bs_getTypeOfJump(void){
|
||||
if(button_held(BUTTON_Z) && can_flap_flip())
|
||||
return BS_12_BFLIP;
|
||||
|
||||
|
@ -831,7 +831,7 @@ s32 func_8029C9C0(s32 arg0){
|
|||
return arg0;
|
||||
|
||||
if(button_pressed(BUTTON_A))
|
||||
arg0 = func_8029C780();
|
||||
arg0 = bs_getTypeOfJump();
|
||||
|
||||
if(button_pressed(BUTTON_B) && can_claw())
|
||||
arg0 = BS_CLAW;
|
||||
|
@ -839,7 +839,7 @@ s32 func_8029C9C0(s32 arg0){
|
|||
if(button_held(BUTTON_Z) && should_beak_barge())
|
||||
arg0 = BS_BBARGE;
|
||||
|
||||
if(func_80294F78())
|
||||
if(should_look_first_person_camera())
|
||||
arg0 = badrone_look();
|
||||
|
||||
if(player_isSliding())
|
||||
|
|
|
@ -186,7 +186,7 @@ bool func_8029D66C(void){
|
|||
case MAP_6E_GL_GV_LOBBY:
|
||||
case MAP_72_GL_BGS_LOBBY:
|
||||
case MAP_8E_GL_FURNACE_FUN://L8029D6FC
|
||||
return func_80294610(0xE000) && func_8028B2E8();
|
||||
return func_80294610(0xE000) && player_isStable();
|
||||
|
||||
case MAP_31_RBB_RUSTY_BUCKET_BAY:
|
||||
player_getPosition(sp2C);
|
||||
|
@ -228,7 +228,7 @@ bool func_8029D7B4(void){
|
|||
&& func_8028ECAC() != BSGROUP_9_LONG_LEG
|
||||
&& miscflag_isFalse(MISC_FLAG_E_TOUCHING_WADING_BOOTS)
|
||||
&& sp1C != BS_25_LONGLEG_ENTER
|
||||
&& func_8028EE84() != BSWATERGROUP_2_UNDERWATER
|
||||
&& player_getWaterState() != BSWATERGROUP_2_UNDERWATER
|
||||
&& func_8028EC04() < 1U
|
||||
&& func_80297C6C() != 3
|
||||
&& bs_getState() != BS_3D_FALL_TUMBLING
|
||||
|
@ -254,7 +254,7 @@ void func_8029D968(void){
|
|||
}
|
||||
temp_v0 = func_8029463C();
|
||||
if(temp_v0 != NULL){
|
||||
sp18 = (temp_v0->flags & 0x4000) && func_8028B2E8();
|
||||
sp18 = (temp_v0->flags & 0x4000) && player_isStable();
|
||||
}
|
||||
if (sp1C || sp18) {
|
||||
rumbleManager_80250D94(1.0f, 0.5f, 0.4f);
|
||||
|
|
|
@ -107,15 +107,15 @@ s32 can_wonderwing(void){
|
|||
return ability_hasLearned(ABILITY_12_WONDERWING);
|
||||
}
|
||||
|
||||
int func_8028ACD8(void){
|
||||
int can_view_first_person(void){
|
||||
if( map_get() == MAP_27_FP_FREEZEEZY_PEAK && mapSpecificFlags_get(0xd)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(ncFirstPersonCamera_getState() == 3)
|
||||
if(ncFirstPersonCamera_getState() == FIRSTPERSON_STATE_3_EXIT)
|
||||
return 0;
|
||||
|
||||
if(!func_8028B2E8() && !player_inWater())
|
||||
if(!player_isStable() && !player_inWater())
|
||||
return 0;
|
||||
return 1;
|
||||
}
|
||||
|
@ -205,10 +205,10 @@ int player_shouldSlideTrot(void){
|
|||
}
|
||||
|
||||
bool func_8028B254(s32 arg0) {
|
||||
return (func_8028B2E8() || (baphysics_get_vertical_velocity() < 0.0f && (player_getYPosition() - func_80294438()) < (f32) arg0));
|
||||
return (player_isStable() || (baphysics_get_vertical_velocity() < 0.0f && (player_getYPosition() - func_80294438()) < (f32) arg0));
|
||||
}
|
||||
|
||||
int func_8028B2E8(void){
|
||||
int player_isStable(void){
|
||||
return D_8037BF60 && baphysics_get_vertical_velocity() < 0.0f;
|
||||
}
|
||||
|
||||
|
@ -232,10 +232,10 @@ bool func_8028B3B4(void) {
|
|||
return FALSE;
|
||||
}
|
||||
|
||||
bool func_8028B424(void){
|
||||
bool player_isFallTumbling(void){
|
||||
s32 sp1C;
|
||||
|
||||
if (func_8028B2E8()) {
|
||||
if (player_isStable()) {
|
||||
return FALSE;
|
||||
}
|
||||
if (!bafalldamage_get_damage(&sp1C)) {
|
||||
|
@ -280,7 +280,7 @@ void func_8028B534(void){
|
|||
D_8037BF62 = 1;
|
||||
}
|
||||
else{
|
||||
if(func_8028B2E8() || sp1C == BSGROUP_A_FLYING || sp1C == BSGROUP_5_CLIMB){
|
||||
if(player_isStable() || sp1C == BSGROUP_A_FLYING || sp1C == BSGROUP_5_CLIMB){
|
||||
D_8037BF62 = 0;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -30,7 +30,7 @@ Actor *func_802CA7BC(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
|
|||
f32 sp40;
|
||||
f32 sp34[3];
|
||||
|
||||
sp60 = (func_8028EE84() == BSWATERGROUP_2_UNDERWATER) ? 8.0f : 4.0f;
|
||||
sp60 = (player_getWaterState() == BSWATERGROUP_2_UNDERWATER) ? 8.0f : 4.0f;
|
||||
this = marker_getActor(marker);
|
||||
if( !func_8028F070()
|
||||
|| !func_8028F150()
|
||||
|
|
|
@ -446,7 +446,7 @@ void func_802CCC5C(Actor *this) {
|
|||
&& !func_8028F25C()
|
||||
&& (sp58 > 800.0f)
|
||||
&& (this->marker->unk14_21)
|
||||
&& (func_8028EE84() != BSWATERGROUP_2_UNDERWATER)
|
||||
&& (player_getWaterState() != BSWATERGROUP_2_UNDERWATER)
|
||||
&& func_802CC57C(this, sp8C)
|
||||
) {
|
||||
sp8C[0] = 0.0f;
|
||||
|
@ -463,7 +463,7 @@ void func_802CCC5C(Actor *this) {
|
|||
spBC = 1;
|
||||
}
|
||||
if (this->state == 3) {
|
||||
if (func_8028F25C() || (func_8028EE84() == BSWATERGROUP_2_UNDERWATER)) {
|
||||
if (func_8028F25C() || (player_getWaterState() == BSWATERGROUP_2_UNDERWATER)) {
|
||||
func_802CC640(this, 4);
|
||||
} else {
|
||||
if (local->unk3A == 0) {
|
||||
|
|
|
@ -247,7 +247,7 @@ void chBeeSwarm_802CF434(Actor *this) {
|
|||
void chBeeSwarm_802CF518(Actor *this) {
|
||||
if( func_803292E0(this)
|
||||
&& func_80329530(this, 900)
|
||||
&& func_8028EE84() == BSWATERGROUP_0_NONE
|
||||
&& player_getWaterState() == BSWATERGROUP_0_NONE
|
||||
&& player_getTransformation() != TRANSFORM_6_BEE
|
||||
) {
|
||||
subaddie_set_state(this, 3);
|
||||
|
@ -258,7 +258,7 @@ void chBeeSwarm_802CF57C(Actor *this) {
|
|||
ActorLocal_core2_47BD0 *local;
|
||||
|
||||
local = (ActorLocal_core2_47BD0 *) &this->local;
|
||||
if (!func_803292E0(this) || !func_80329530(this, 900) || func_8028EE84() != BSWATERGROUP_0_NONE) {
|
||||
if (!func_803292E0(this) || !func_80329530(this, 900) || player_getWaterState() != BSWATERGROUP_0_NONE) {
|
||||
subaddie_set_state(this, 5);
|
||||
func_802CEF54(this, local->unkC, 100.0f);
|
||||
}
|
||||
|
|
|
@ -171,7 +171,7 @@ void func_802D31AC(ActorMarker *arg0, ActorMarker * arg1) {
|
|||
|
||||
case MARKER_109_BREAKABLE_BRICK_WALL:
|
||||
func_8030E6D4(SFX_114_BRICKWALL_BREAKING);
|
||||
func_8030E510(SFX_11_WOOD_BREAKING_1, 28000);
|
||||
sfxsource_play(SFX_11_WOOD_BREAKING_1, 28000);
|
||||
subaddie_set_state_looped(sp2C, 9);
|
||||
fileProgressFlag_set((sp2C->unkF4_8 == 1) ? FILEPROG_C8_LAIR_BRICKWALL_TO_WADINGBOOTS_BROKEN : FILEPROG_C9_LAIR_BRICKWALL_TO_SHOCKJUMP_PAD_BROKEN, TRUE);
|
||||
break;
|
||||
|
@ -329,7 +329,7 @@ void func_802D31AC(ActorMarker *arg0, ActorMarker * arg1) {
|
|||
case 0x164:
|
||||
case 0x165:
|
||||
if (sp2C->unk1C[1] == sp2C->position[1]) {
|
||||
func_8030E510(SFX_9B_BOULDER_BREAKING_1, 25000);
|
||||
sfxsource_play(SFX_9B_BOULDER_BREAKING_1, 25000);
|
||||
sp2C->unk1C[0] = 1.0f;
|
||||
}
|
||||
break;
|
||||
|
@ -539,7 +539,7 @@ void func_802D4388(Actor *this){
|
|||
Actor *func_802D4588(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx) {
|
||||
s32 phi_a1;
|
||||
|
||||
phi_a1 = (marker_getActor(marker)->unk38_0) ? ((func_8023DB5C() & 4) != 0) ? 1 : 2 : 2;
|
||||
phi_a1 = (marker_getActor(marker)->unk38_0) ? ((globalTimer_getTime() & 4) != 0) ? 1 : 2 : 2;
|
||||
func_8033A45C(1, phi_a1);
|
||||
return actor_draw(marker, gfx, mtx, vtx);
|
||||
}
|
||||
|
|
|
@ -131,14 +131,14 @@ bool func_802DAFBC(Actor *this) {
|
|||
if (temp_v0 & 4) {
|
||||
func_8032C9E0(sp38);
|
||||
sp34 = func_80257248(sp38, this->position);
|
||||
if (((func_8023DB5C() - local->unk38) == 0x1E) && ((sp34 - this->yaw_ideal < 15.0f) && (sp34 - this->yaw_ideal > -15.0f))) {
|
||||
if (((globalTimer_getTime() - local->unk38) == 0x1E) && ((sp34 - this->yaw_ideal < 15.0f) && (sp34 - this->yaw_ideal > -15.0f))) {
|
||||
func_802DAF2C(this->position, this->yaw, this->unk28);
|
||||
} else {
|
||||
func_80328CEC(this, (s32) sp34, 0, 0xF);
|
||||
}
|
||||
this->unk38_31 = 0x1E;
|
||||
this->unk38_0 = TRUE;
|
||||
local->unk38 = func_8023DB5C();
|
||||
local->unk38 = globalTimer_getTime();
|
||||
} else if (temp_v0 & 8) {
|
||||
func_802DAE10(this);
|
||||
this->unk38_31 = 0x5A;
|
||||
|
@ -284,13 +284,13 @@ void func_802DB5A0(Actor *this) {
|
|||
func_80328FB0(this, 2.0f);
|
||||
func_802DB3B0(this);
|
||||
if (this->unk38_31 == 0) {
|
||||
if (!(func_8023DB5C() & 0xF)) {
|
||||
if (!(globalTimer_getTime() & 0xF)) {
|
||||
func_80328CEC(this, this->yaw_ideal, 0xA, 0x14);
|
||||
}
|
||||
if (!(func_8023DB5C() & 7)) {
|
||||
if (!(globalTimer_getTime() & 7)) {
|
||||
subaddie_maybe_set_state(this, 1, 0.02f);
|
||||
}
|
||||
if( !(func_8023DB5C() & 0xF)
|
||||
if( !(globalTimer_getTime() & 0xF)
|
||||
&& func_80329078(this, (s32) this->yaw_ideal, 0x96)
|
||||
) {
|
||||
if (subaddie_maybe_set_state(this, 3, 0.13f) != 0) {
|
||||
|
@ -316,7 +316,7 @@ void func_802DB5A0(Actor *this) {
|
|||
case 3://L802DB930
|
||||
func_80328FB0(this, 3.0f);
|
||||
func_802DB3B0(this);
|
||||
if (!(func_8023DB5C() & 0xF) && (subaddie_maybe_set_state(this, 2, 0.08f))) {
|
||||
if (!(globalTimer_getTime() & 0xF) && (subaddie_maybe_set_state(this, 2, 0.08f))) {
|
||||
func_802DAE10(this);
|
||||
}
|
||||
func_802DB220(this);
|
||||
|
@ -351,7 +351,7 @@ void func_802DB5A0(Actor *this) {
|
|||
|
||||
case 7://L802DBB4C
|
||||
if (this->unk38_31 == 0) {
|
||||
if ((func_8023DB5C() & 0xF) == 9) {
|
||||
if ((globalTimer_getTime() & 0xF) == 9) {
|
||||
this->yaw_ideal = (f32) func_80329784(this);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -59,7 +59,7 @@ void func_802DC208(Actor *this) {
|
|||
}
|
||||
if( func_8024DB50(this->position, 50.0f)
|
||||
&& func_802DC188()
|
||||
&& !(func_8023DB5C() & 0x1F)
|
||||
&& !(globalTimer_getTime() & 0x1F)
|
||||
&& randf() < 0.1
|
||||
){
|
||||
switch((s32)this->yaw){
|
||||
|
|
|
@ -29,7 +29,7 @@ void func_8028DB04(void){
|
|||
D_8037BFA0 = 2;
|
||||
}
|
||||
|
||||
enum hitbox_e func_8028DB14(ActorMarker *arg0){
|
||||
enum hitbox_e hitbox_getHitboxForActor(ActorMarker *arg0){
|
||||
s32 retVal;
|
||||
if(D_8037BFA0)
|
||||
return HITBOX_3_BEAK_BOMB;
|
||||
|
@ -77,10 +77,10 @@ enum hitbox_e func_8028DB14(ActorMarker *arg0){
|
|||
break;
|
||||
case BS_5_JUMP://8028DCD8
|
||||
case BS_3D_FALL_TUMBLING:
|
||||
if(baphysics_get_vertical_velocity() < 0.0f && !func_8028B2E8())
|
||||
if(baphysics_get_vertical_velocity() < 0.0f && !player_isStable())
|
||||
return HITBOX_A_FAST_FALLING;
|
||||
case BS_2F_FALL://8028DD10
|
||||
if(baphysics_get_vertical_velocity() < -1400.0f && !func_8028B2E8())
|
||||
if(baphysics_get_vertical_velocity() < -1400.0f && !player_isStable())
|
||||
return HITBOX_A_FAST_FALLING;
|
||||
default://8028DD4C
|
||||
return HITBOX_0_NONE;
|
||||
|
|
|
@ -254,7 +254,7 @@ void func_8028E71C(void) {
|
|||
|
||||
|
||||
enum hitbox_e player_getActiveHitbox(ActorMarker *marker){
|
||||
return func_8028DB14(marker);
|
||||
return hitbox_getHitboxForActor(marker);
|
||||
}
|
||||
|
||||
AnimCtrl *player_getAnimCtrlPtr(void){
|
||||
|
@ -444,8 +444,8 @@ enum bsgroup_e func_8028ECAC(void) {
|
|||
if (miscflag_isTrue(MISC_FLAG_1B_TRANSFORMING)) {
|
||||
return BSGROUP_D_TRANSFORMING;
|
||||
}
|
||||
if (miscflag_isTrue(0x17)) {
|
||||
return 4;
|
||||
if (miscflag_isTrue(MISC_FLAG_17_FPV)) {
|
||||
return BSGROUP_4_LOOK;
|
||||
}
|
||||
if (bsbfly_inSet(state_id)) {
|
||||
return BSGROUP_A_FLYING;
|
||||
|
@ -508,7 +508,7 @@ enum bsgroup_e func_8028ECAC(void) {
|
|||
}
|
||||
|
||||
|
||||
enum bswatergroup_e func_8028EE84(void) {
|
||||
enum bswatergroup_e player_getWaterState(void) {
|
||||
enum bswatergroup_e state_id;
|
||||
|
||||
state_id = bs_getState();
|
||||
|
@ -609,7 +609,7 @@ bool func_8028F150(void){
|
|||
}
|
||||
|
||||
bool func_8028F170(void){
|
||||
return miscflag_isTrue(0x17);
|
||||
return miscflag_isTrue(MISC_FLAG_17_FPV);
|
||||
}
|
||||
|
||||
int ability_isUnlocked(enum ability_e uid){
|
||||
|
@ -629,7 +629,7 @@ bool func_8028F1E0(void){
|
|||
}
|
||||
|
||||
bool func_8028F20C(void){
|
||||
return func_8028B2E8();
|
||||
return player_isStable();
|
||||
}
|
||||
|
||||
bool func_8028F22C(void){
|
||||
|
|
|
@ -124,7 +124,7 @@ void func_802F919C(void) {
|
|||
return;
|
||||
}
|
||||
temp_f20 = time_getDelta();
|
||||
sp60 = (func_8023DB5C() & 1) * 2;
|
||||
sp60 = (globalTimer_getTime() & 1) * 2;
|
||||
player_getPosition(D_80381040);
|
||||
|
||||
D_80369280->unkC[0] = D_80381040[0] - D_80369280->unk0[0];
|
||||
|
|
|
@ -144,7 +144,7 @@ void itemPrint_update(void) {
|
|||
} else {
|
||||
itemPrintValues[i] += (sign * _73640_MIN(time_getDelta() * _73640_MAX(diff, 8.0f), 1.0));
|
||||
}
|
||||
if ((D_80381168[i] != 0) && ((func_8023DB5C() & 7) == 0)) {
|
||||
if ((D_80381168[i] != 0) && ((globalTimer_getTime() & 7) == 0)) {
|
||||
func_8025A6EC(D_80381168[i], 32000);
|
||||
}
|
||||
if (D_80381378[i] != 0) {
|
||||
|
|
|
@ -2287,7 +2287,7 @@ void func_803086B4(void) {
|
|||
cube = D_80381FA0.cube_list;
|
||||
}
|
||||
};
|
||||
if (func_8023DB5C() & 1) {
|
||||
if (globalTimer_getTime() & 1) {
|
||||
if (D_8036ABA0 != NULL) {
|
||||
D_8036ABA0 = (s16*) defrag(D_8036ABA0);
|
||||
}
|
||||
|
|
|
@ -64,7 +64,7 @@ BKModelBin *func_8030A428(s32 arg0){
|
|||
if(D_80382390[arg0].unk0 == NULL){
|
||||
D_80382390[arg0].unk0 = assetcache_get(0x2d1 + arg0);
|
||||
}
|
||||
D_80382390[arg0].unk4 = func_8023DB5C();
|
||||
D_80382390[arg0].unk4 = globalTimer_getTime();
|
||||
return D_80382390[arg0].unk0;
|
||||
}
|
||||
|
||||
|
@ -78,7 +78,7 @@ BKSpriteDisplayData *func_8030A4D4(s32 arg0)
|
|||
if (((struct_7AF80_1 *)((s32)D_80382394 + arg0*sizeof(struct_7AF80_1)))->unk0 == 0){
|
||||
((struct_7AF80_1 *)((s32)D_80382394 + arg0*sizeof(struct_7AF80_1)))->unk0 = func_8033B6C4(arg0 + 0x572, &((struct_7AF80_1 *)((s32)D_80382394 + arg0*sizeof(struct_7AF80_1)))->unk4);
|
||||
}
|
||||
D_80382394[arg0].unk8 = func_8023DB5C();
|
||||
D_80382394[arg0].unk8 = globalTimer_getTime();
|
||||
return D_80382394[arg0].unk4;
|
||||
}
|
||||
|
||||
|
@ -154,7 +154,7 @@ void func_8030A850(s32 arg0) {
|
|||
struct_7AF80_0 *sp3C;
|
||||
struct_7AF80_1 *temp_a0_2;
|
||||
|
||||
temp_s3 = func_8023DB5C() - func_80255B08(arg0);
|
||||
temp_s3 = globalTimer_getTime() - func_80255B08(arg0);
|
||||
for(var_s0 = 0; (D_80382390 != NULL) && (var_s0 < ((arg0 == 1) ? 0x28 : 0x2A1)); var_s0++, D_8036B804 = (D_8036B804 >= 0x2A1)? 0: D_8036B804 + 1){
|
||||
sp3C = (struct_7AF80_0*)((u32)D_80382390 + sizeof(struct_7AF80_0)*D_8036B804);
|
||||
if ((sp3C->unk0 != 0) && ((sp3C->unk4 < temp_s3) || (arg0 == 3))){
|
||||
|
|
|
@ -28,7 +28,7 @@ typedef struct {
|
|||
f32 unk20;
|
||||
f32 unk24;
|
||||
s16 sfx_uid;
|
||||
s16 unk2A;//sample_rate
|
||||
s16 sample_rate;//sample_rate
|
||||
u8 unk2C;
|
||||
u8 pad2D[3];
|
||||
void (*unk30)(u8 indx);
|
||||
|
@ -41,7 +41,7 @@ typedef struct {
|
|||
u8 unk43_7:3;
|
||||
u8 unk43_4:3;
|
||||
u8 unk43_1:2;
|
||||
}struct45s;
|
||||
}SfxSource;
|
||||
|
||||
u8 func_8030D90C(void);
|
||||
void sfxsource_setSfxId(u8 indx, enum sfx_e uid);
|
||||
|
@ -56,7 +56,7 @@ void func_8030EDAC(f32, f32);
|
|||
|
||||
/* .bss */
|
||||
struct46s D_80382470[10];
|
||||
struct45s D_803824C0[35];
|
||||
SfxSource sfxsources[35];
|
||||
f32 D_80382E0C;
|
||||
f32 D_80382E10;
|
||||
|
||||
|
@ -68,46 +68,46 @@ void __sfx_getPlayerPositionIfPresent(f32 arg0[3]){
|
|||
ml_vec3f_clear(arg0);
|
||||
}
|
||||
|
||||
void func_8030C7D0(struct45s *arg0, s32 arg1){
|
||||
void func_8030C7D0(SfxSource *arg0, s32 arg1){
|
||||
arg0->unk43_7 = arg1;
|
||||
}
|
||||
|
||||
s32 func_8030C7E8(struct45s *arg0){
|
||||
s32 func_8030C7E8(SfxSource *arg0){
|
||||
return arg0->unk43_7;
|
||||
}
|
||||
|
||||
void func_8030C7F8(struct45s *arg0, s32 arg1){
|
||||
void func_8030C7F8(SfxSource *arg0, s32 arg1){
|
||||
arg0->unk43_4 = arg1;
|
||||
}
|
||||
|
||||
int func_8030C814(struct45s *arg0, s32 arg1){
|
||||
int func_8030C814(SfxSource *arg0, s32 arg1){
|
||||
return arg0->unk43_4 == arg1;
|
||||
}
|
||||
|
||||
void sfxsource_setFlag(struct45s *arg0, s32 arg1){
|
||||
void sfxsource_setFlag(SfxSource *arg0, s32 arg1){
|
||||
arg0->unk41 |= arg1;
|
||||
}
|
||||
|
||||
void sfxsource_clearFlag(struct45s *arg0, s32 arg1){
|
||||
void sfxsource_clearFlag(SfxSource *arg0, s32 arg1){
|
||||
arg0->unk41 &= ~arg1;
|
||||
}
|
||||
|
||||
s32 sfxsource_isFlagSet(struct45s *arg0, s32 arg1){
|
||||
s32 sfxsource_isFlagSet(SfxSource *arg0, s32 arg1){
|
||||
return arg0->unk41 & arg1;
|
||||
}
|
||||
|
||||
int sfxsource_isFlagCleared(struct45s *arg0, s32 arg1){
|
||||
int sfxsource_isFlagCleared(SfxSource *arg0, s32 arg1){
|
||||
return (arg0->unk41 & arg1) == 0;
|
||||
}
|
||||
|
||||
void sfxsource_initAll(void){
|
||||
int i;
|
||||
for(i = 0; i < 35; i++)
|
||||
D_803824C0[i].busy = FALSE;
|
||||
sfxsources[i].busy = FALSE;
|
||||
}
|
||||
|
||||
struct45s *sfxsource_at(u8 indx){
|
||||
return D_803824C0 + indx;
|
||||
SfxSource *sfxsource_at(u8 indx){
|
||||
return sfxsources + indx;
|
||||
}
|
||||
|
||||
struct46s *func_8030C8DC(s32 indx){
|
||||
|
@ -121,8 +121,8 @@ Struct81s *func_8030C8F4(s32 indx){
|
|||
u8 sfxsource_getNewIndex(void){
|
||||
int i;
|
||||
for(i = 1; i < 35; i++){
|
||||
if(!D_803824C0[i].busy){
|
||||
D_803824C0[i].busy = TRUE;
|
||||
if(!sfxsources[i].busy){
|
||||
sfxsources[i].busy = TRUE;
|
||||
return i;
|
||||
}
|
||||
}
|
||||
|
@ -154,15 +154,15 @@ s32 func_8030CA60(void){
|
|||
}
|
||||
|
||||
void sfxsource_free(u8 indx){
|
||||
struct45s *ptr = sfxsource_at(indx);
|
||||
SfxSource *ptr = sfxsource_at(indx);
|
||||
if(ptr->unk40){
|
||||
func_8030C9F4(ptr->unk40);
|
||||
ptr->unk40 = 0;
|
||||
}
|
||||
D_803824C0[indx].busy = FALSE;
|
||||
sfxsources[indx].busy = FALSE;
|
||||
}
|
||||
|
||||
void func_8030CBD0(struct45s *arg0){
|
||||
void func_8030CBD0(SfxSource *arg0){
|
||||
s32 sp24 = func_8030CA60();
|
||||
struct46s *temp_a1;
|
||||
if(sp24){
|
||||
|
@ -182,7 +182,7 @@ void func_8030CBD0(struct45s *arg0){
|
|||
}//L8030CC7C
|
||||
}
|
||||
|
||||
void func_8030CC90(struct45s *arg0){
|
||||
void func_8030CC90(SfxSource *arg0){
|
||||
if(func_8030C814(arg0, 1)){
|
||||
sfxsource_clearFlag(arg0, SFX_SRC_FLAG_5_UNKOWN);
|
||||
func_8030C7F8(arg0, 2);
|
||||
|
@ -192,7 +192,7 @@ void func_8030CC90(struct45s *arg0){
|
|||
}
|
||||
}
|
||||
|
||||
s32 func_8030CCF0(struct45s *arg0, s32 arg1){
|
||||
s32 func_8030CCF0(SfxSource *arg0, s32 arg1){
|
||||
f32 plyr_pos[3];
|
||||
f32 diff[3];
|
||||
f32 dist_sqr;
|
||||
|
@ -211,7 +211,7 @@ s32 func_8030CCF0(struct45s *arg0, s32 arg1){
|
|||
return retVal;
|
||||
}
|
||||
|
||||
s32 func_8030CDE4(struct45s *arg0){
|
||||
s32 func_8030CDE4(SfxSource *arg0){
|
||||
f32 sp44[3];
|
||||
f32 sp38[3];
|
||||
f32 sp2C[3];
|
||||
|
@ -264,14 +264,14 @@ void func_8030D004(s32 arg0, s32 arg1){
|
|||
}
|
||||
}
|
||||
|
||||
s32 func_8030D038(struct45s *arg0, s32 arg1){
|
||||
s32 func_8030D038(SfxSource *arg0, s32 arg1){
|
||||
if(sfxsource_isFlagSet(arg0,SFX_SRC_FLAG_6_UNKOWN)){
|
||||
if(sfxsource_isFlagSet(arg0, SFX_SRC_FLAG_7_UNKOWN)){
|
||||
if(player_is_present() && func_8028EE84() == BSWATERGROUP_2_UNDERWATER)
|
||||
if(player_is_present() && player_getWaterState() == BSWATERGROUP_2_UNDERWATER)
|
||||
arg1 *= arg0->unk3C;
|
||||
}
|
||||
else{//L8030D0B4
|
||||
if(player_is_present() && func_8028EE84() != BSWATERGROUP_2_UNDERWATER)
|
||||
if(player_is_present() && player_getWaterState() != BSWATERGROUP_2_UNDERWATER)
|
||||
arg1 *= arg0->unk38;
|
||||
}
|
||||
}
|
||||
|
@ -280,7 +280,7 @@ s32 func_8030D038(struct45s *arg0, s32 arg1){
|
|||
|
||||
s32 func_8030D10C(u8 indx){
|
||||
s32 sp24;
|
||||
struct45s * ptr;
|
||||
SfxSource * ptr;
|
||||
s32 tmp_v0;
|
||||
f32 tmp_f2;
|
||||
|
||||
|
@ -299,14 +299,14 @@ s32 func_8030D10C(u8 indx){
|
|||
|
||||
//L8030D228
|
||||
if(sfxsource_isFlagSet(ptr, SFX_SRC_FLAG_1_UNKOWN)){
|
||||
tmp_v0 = func_8030CCF0(ptr, ptr->unk2A);
|
||||
tmp_v0 = func_8030CCF0(ptr, ptr->sample_rate);
|
||||
if(tmp_v0 < 100)
|
||||
sp24 = 1;
|
||||
func_8030D004(ptr->unk40, func_8030D038(ptr, tmp_v0));
|
||||
func_8030CF9C(ptr->unk40, func_8030CDE4(ptr));
|
||||
}else{//L8030D288
|
||||
if(sfxsource_isFlagSet(ptr, SFX_SRC_FLAG_3_UNKOWN)){
|
||||
tmp_v0 = func_8030D038(ptr, ptr->unk2A);
|
||||
tmp_v0 = func_8030D038(ptr, ptr->sample_rate);
|
||||
if(tmp_v0 < 100)
|
||||
sp24 = 1;
|
||||
func_8030D004(ptr->unk40, tmp_v0);
|
||||
|
@ -326,7 +326,7 @@ void func_8030D310(u8 indx){
|
|||
f32 pad0;
|
||||
s32 sp30;
|
||||
f32 pad1;
|
||||
struct45s * ptr;
|
||||
SfxSource * ptr;
|
||||
f32 sp24;
|
||||
|
||||
ptr = sfxsource_at(indx);
|
||||
|
@ -396,7 +396,7 @@ void func_8030D310(u8 indx){
|
|||
}
|
||||
|
||||
bool func_8030D5CC(u8 indx){
|
||||
struct45s * sp1C = sfxsource_at(indx);
|
||||
SfxSource * sp1C = sfxsource_at(indx);
|
||||
if(!func_8030C814(sp1C, 3))
|
||||
return 0;
|
||||
|
||||
|
@ -411,7 +411,7 @@ bool func_8030D5CC(u8 indx){
|
|||
void func_8030D644(void){
|
||||
int i;
|
||||
for(i = 1; i < 35; i++){
|
||||
if(D_803824C0[i].busy){
|
||||
if(sfxsources[i].busy){
|
||||
func_8030D310(i);
|
||||
if(func_8030D5CC(i))
|
||||
sfxsource_free(i);
|
||||
|
@ -442,14 +442,14 @@ void func_8030D778(void){
|
|||
int i;
|
||||
int temp_s1;
|
||||
for(i = 1; i < 35; i++){
|
||||
if(D_803824C0[i].busy)
|
||||
if(sfxsources[i].busy)
|
||||
func_8030DA44(i);
|
||||
}
|
||||
do{
|
||||
temp_s1 = 0;
|
||||
func_8030D644();
|
||||
for(i = 1; i < 35; i++){
|
||||
if(D_803824C0[i].busy)
|
||||
if(sfxsources[i].busy)
|
||||
temp_s1++;
|
||||
}
|
||||
}while(temp_s1);
|
||||
|
@ -478,7 +478,7 @@ void func_8030D8DC(void){
|
|||
|
||||
u8 func_8030D90C(void){
|
||||
u8 s1 = sfxsource_getNewIndex();
|
||||
struct45s *s0;
|
||||
SfxSource *s0;
|
||||
|
||||
if(s1 == 0)
|
||||
return 0;
|
||||
|
@ -486,7 +486,7 @@ u8 func_8030D90C(void){
|
|||
s0 = sfxsource_at(s1);
|
||||
s0->unk30 = NULL;
|
||||
s0->sfx_uid = -1;
|
||||
s0->unk2A = 22000;
|
||||
s0->sample_rate = 22000;
|
||||
s0->unk2C = 0;
|
||||
s0->unk40 = 0;
|
||||
s0->unk43_1 = 0;
|
||||
|
@ -511,7 +511,7 @@ u8 func_8030D90C(void){
|
|||
}
|
||||
|
||||
void func_8030DA44(u8 indx){
|
||||
struct45s * sp1C = sfxsource_at(indx);
|
||||
SfxSource * sp1C = sfxsource_at(indx);
|
||||
func_8030E394(indx);
|
||||
func_8030C7F8(sp1C, 3);
|
||||
}
|
||||
|
@ -522,10 +522,10 @@ void sfxsource_setSfxId(u8 indx, enum sfx_e uid){
|
|||
}
|
||||
|
||||
void sfxsource_setSampleRate(u8 indx, s32 sample_rate){
|
||||
struct45s *temp_v0;
|
||||
SfxSource *temp_v0;
|
||||
if(indx){
|
||||
temp_v0 = sfxsource_at(indx);
|
||||
temp_v0->unk2A = sample_rate;
|
||||
temp_v0->sample_rate = sample_rate;
|
||||
sfxsource_setFlag(temp_v0, SFX_SRC_FLAG_3_UNKOWN);
|
||||
}
|
||||
}
|
||||
|
@ -550,7 +550,7 @@ void func_8030DB04(u8 indx, s32 arg1, f32 arg2[3], f32 min_dist, f32 max_dist){
|
|||
}
|
||||
|
||||
void func_8030DBB4(u8 indx, f32 arg1){
|
||||
struct45s *temp_v0;
|
||||
SfxSource *temp_v0;
|
||||
if(indx){
|
||||
temp_v0 = sfxsource_at(indx);
|
||||
temp_v0->unk34 = arg1;
|
||||
|
@ -581,7 +581,7 @@ void func_8030DBFC(u8 indx, f32 arg1, f32 arg2, f32 arg3){
|
|||
}
|
||||
|
||||
void func_8030DCCC(u8 indx, s32 arg1){
|
||||
struct45s *temp_v0;
|
||||
SfxSource *temp_v0;
|
||||
if(indx){
|
||||
temp_v0 = sfxsource_at(indx);
|
||||
temp_v0->unk2C = arg1;
|
||||
|
@ -590,7 +590,7 @@ void func_8030DCCC(u8 indx, s32 arg1){
|
|||
}
|
||||
|
||||
void func_8030DD14(u8 indx, int arg1){
|
||||
struct45s *temp_v0;
|
||||
SfxSource *temp_v0;
|
||||
if(indx){
|
||||
temp_v0 = sfxsource_at(indx);
|
||||
func_8030C7D0(temp_v0, arg1);
|
||||
|
@ -598,7 +598,7 @@ void func_8030DD14(u8 indx, int arg1){
|
|||
}
|
||||
|
||||
void func_8030DD54(u8 indx, void (*arg1)(u8)){
|
||||
struct45s *temp_v0;
|
||||
SfxSource *temp_v0;
|
||||
if(indx){
|
||||
temp_v0 = sfxsource_at(indx);
|
||||
temp_v0->unk30 = arg1;
|
||||
|
@ -606,7 +606,7 @@ void func_8030DD54(u8 indx, void (*arg1)(u8)){
|
|||
}
|
||||
|
||||
void func_8030DD90(u8 indx, s32 arg1){
|
||||
struct45s *temp_v0;
|
||||
SfxSource *temp_v0;
|
||||
if(indx){
|
||||
temp_v0 = sfxsource_at(indx);
|
||||
switch(arg1){
|
||||
|
@ -627,7 +627,7 @@ void func_8030DD90(u8 indx, s32 arg1){
|
|||
}
|
||||
|
||||
void func_8030DE44(u8 indx, s32 arg1, f32 arg2){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
switch(arg1){
|
||||
|
@ -644,7 +644,7 @@ void func_8030DE44(u8 indx, s32 arg1, f32 arg2){
|
|||
}
|
||||
|
||||
void sfxsource_set_fade_distances(u8 indx, f32 min, f32 max){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
ptr->fade_inner_radius_sqr = min*min;
|
||||
|
@ -654,7 +654,7 @@ void sfxsource_set_fade_distances(u8 indx, f32 min, f32 max){
|
|||
}
|
||||
|
||||
void func_8030DF18(u8 indx, f32 arg1){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
ptr->unk14 = (s16)arg1;
|
||||
|
@ -663,7 +663,7 @@ void func_8030DF18(u8 indx, f32 arg1){
|
|||
}
|
||||
|
||||
void sfxsource_set_position(u8 indx, f32 position[3]){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
ml_vec3f_copy(ptr->position, position);
|
||||
|
@ -672,7 +672,7 @@ void sfxsource_set_position(u8 indx, f32 position[3]){
|
|||
}
|
||||
|
||||
void func_8030DFB4(u8 indx, s32 arg1){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
ptr->unk16 = arg1;
|
||||
|
@ -680,7 +680,7 @@ void func_8030DFB4(u8 indx, s32 arg1){
|
|||
}
|
||||
|
||||
void func_8030DFF0(u8 indx, s32 arg1){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
if(arg1){
|
||||
|
@ -693,7 +693,7 @@ void func_8030DFF0(u8 indx, s32 arg1){
|
|||
}
|
||||
|
||||
void func_8030E04C(u8 indx, f32 arg1, f32 arg2, f32 arg3){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
ptr->unk43_1 = 1;
|
||||
|
@ -704,7 +704,7 @@ void func_8030E04C(u8 indx, f32 arg1, f32 arg2, f32 arg3){
|
|||
}
|
||||
|
||||
void func_8030E0B4(u8 indx, f32 arg1, f32 arg2){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
ptr->unk38 = arg1;
|
||||
|
@ -713,7 +713,7 @@ void func_8030E0B4(u8 indx, f32 arg1, f32 arg2){
|
|||
}
|
||||
|
||||
void func_8030E0FC(u8 indx, f32 arg1, f32 arg2, f32 arg3){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
|
@ -726,7 +726,7 @@ void func_8030E0FC(u8 indx, f32 arg1, f32 arg2, f32 arg3){
|
|||
}
|
||||
|
||||
enum sfx_e sfxsource_getSfxId(u8 indx){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
|
||||
if(!indx)
|
||||
return 0;
|
||||
|
@ -737,18 +737,18 @@ enum sfx_e sfxsource_getSfxId(u8 indx){
|
|||
}
|
||||
|
||||
s32 func_8030E1C4(u8 indx){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
|
||||
if(indx == 0)
|
||||
return 0;
|
||||
else{
|
||||
ptr = sfxsource_at(indx);
|
||||
return ptr->unk2A;
|
||||
return ptr->sample_rate;
|
||||
}
|
||||
}
|
||||
|
||||
f32 func_8030E200(u8 indx){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
|
||||
if(!indx)
|
||||
return 1.0f;
|
||||
|
@ -759,7 +759,7 @@ f32 func_8030E200(u8 indx){
|
|||
}
|
||||
|
||||
s32 func_8030E244(u8 indx){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
|
||||
if(!indx)
|
||||
return 0;
|
||||
|
@ -769,19 +769,19 @@ s32 func_8030E244(u8 indx){
|
|||
}
|
||||
}
|
||||
|
||||
bool func_8030E280(struct45s *arg0){
|
||||
bool func_8030E280(SfxSource *arg0){
|
||||
int temp_v1;
|
||||
if(sfxsource_isFlagSet(arg0, SFX_SRC_FLAG_1_UNKOWN)){
|
||||
temp_v1 = func_8030CCF0(arg0, arg0->unk2A);
|
||||
temp_v1 = func_8030CCF0(arg0, arg0->sample_rate);
|
||||
}
|
||||
else{
|
||||
temp_v1 = arg0->unk2A;
|
||||
temp_v1 = arg0->sample_rate;
|
||||
}
|
||||
return (temp_v1 > 100);
|
||||
}
|
||||
|
||||
void func_8030E2C4(u8 indx){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
|
||||
if(!indx)
|
||||
return;
|
||||
|
@ -810,7 +810,7 @@ void func_8030E2C4(u8 indx){
|
|||
}
|
||||
|
||||
void func_8030E394(u8 indx){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
|
||||
if(indx){
|
||||
ptr = sfxsource_at(indx);
|
||||
|
@ -824,7 +824,7 @@ void func_8030E394(u8 indx){
|
|||
|
||||
|
||||
int func_8030E3FC(u8 indx){
|
||||
struct45s *ptr;
|
||||
SfxSource *ptr;
|
||||
|
||||
if(!indx)
|
||||
return 0;
|
||||
|
@ -849,12 +849,12 @@ void func_8030E4E4(enum sfx_e uid){
|
|||
func_8030D6C4(uid, 1.0f, 22000, 0, 0);
|
||||
}
|
||||
|
||||
void func_8030E510(enum sfx_e uid, s32 arg1){
|
||||
func_8030D6C4(uid, 1.0f, arg1, 0, 2);
|
||||
void sfxsource_play(enum sfx_e uid, s32 sample_rate){
|
||||
func_8030D6C4(uid, 1.0f, sample_rate, 0, 2);
|
||||
}
|
||||
|
||||
void func_8030E540(enum sfx_e uid){
|
||||
func_8030E510(uid, 0x7ff8);
|
||||
sfxsource_play(uid, 0x7ff8);
|
||||
}
|
||||
|
||||
void func_8030E560(enum sfx_e uid, s32 arg1){
|
||||
|
@ -898,55 +898,56 @@ void func_8030E760(enum sfx_e uid, f32 arg1, s32 arg2){
|
|||
func_8030D6C4(uid, arg1, arg2, 0, 0);
|
||||
}
|
||||
|
||||
void func_8030E78C(enum sfx_e uid, f32 arg1, u32 arg2, f32 position[3], f32 arg4, f32 arg5, s32 arg6){
|
||||
u8 s0;
|
||||
void sfx_play(enum sfx_e uid, f32 arg1, u32 sampleRate, f32 position[3], f32 minFadeDistance, f32 maxFadeDistance, s32 arg6){
|
||||
u8 sfxsource;
|
||||
f32 plyr_pos[3];
|
||||
|
||||
__sfx_getPlayerPositionIfPresent(plyr_pos);
|
||||
if( !(arg5 <= ml_distance_vec3f(plyr_pos, position))
|
||||
if( !(maxFadeDistance <= ml_distance_vec3f(plyr_pos, position))
|
||||
&& levelSpecificFlags_validateCRC2()
|
||||
&& func_80320240()
|
||||
){
|
||||
s0 = func_8030D90C();
|
||||
if(s0){
|
||||
func_8030DD90(s0, arg6);
|
||||
sfxsource_setSfxId(s0, uid);
|
||||
sfxsource_setSampleRate(s0, arg2);
|
||||
func_8030DBB4(s0, arg1);
|
||||
sfxsource_set_fade_distances(s0, arg4, arg5);
|
||||
sfxsource_set_position(s0, position);
|
||||
func_8030DD14(s0, 1);
|
||||
func_8030E2C4(s0);
|
||||
sfxsource = func_8030D90C();
|
||||
if(sfxsource){
|
||||
func_8030DD90(sfxsource, arg6); // priority ?
|
||||
sfxsource_setSfxId(sfxsource, uid);
|
||||
sfxsource_setSampleRate(sfxsource, sampleRate);
|
||||
func_8030DBB4(sfxsource, arg1); // volume ?
|
||||
sfxsource_set_fade_distances(sfxsource, minFadeDistance, maxFadeDistance);
|
||||
sfxsource_set_position(sfxsource, position);
|
||||
func_8030DD14(sfxsource, 1);
|
||||
func_8030E2C4(sfxsource);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void func_8030E878(enum sfx_e id, f32 arg1, u32 arg2, f32 arg3[3], f32 arg4, f32 arg5){
|
||||
func_8030E78C(id, arg1, arg2, arg3, arg4, arg5, 2);
|
||||
void func_8030E878(enum sfx_e id, f32 arg1, u32 sampleRate, f32 position[3], f32 minFadeDistance, f32 maxFadeDistance){
|
||||
sfx_play(id, arg1, sampleRate, position, minFadeDistance, maxFadeDistance, 2);
|
||||
}
|
||||
|
||||
void func_8030E8B4(u32 arg0, f32 arg1[3], u32 arg2){
|
||||
func_8030E78C(
|
||||
// fadeDistance is a 32-bit value where the lower 16 bits represent minFadeDistance and the upper 16 bits represent maxFadeDistance.
|
||||
void func_8030E8B4(u32 arg0, f32 position[3], u32 fadeDistance){
|
||||
sfx_play(
|
||||
(arg0 & 0x7ff), (f32)((arg0 >> 0x15) & 0x7ff)/1023.0, ((arg0 >> 0x6) & 0x7fe0),
|
||||
arg1, (f32)(arg2 & 0xffff), (f32)((arg2 >> 0x10) & 0xffff),
|
||||
position, (f32)(fadeDistance & 0xffff), (f32)((fadeDistance >> 0x10) & 0xffff),
|
||||
2
|
||||
);
|
||||
}
|
||||
|
||||
void func_8030E988(enum sfx_e uid, f32 arg1, u32 arg2, f32 arg3[3], f32 arg4, f32 arg5){
|
||||
func_8030E78C(uid, arg1, arg2, arg3, arg4, arg5, 1);
|
||||
void func_8030E988(enum sfx_e uid, f32 arg1, u32 sampleRate, f32 position[3], f32 minFadeDistance, f32 maxFadeDistance){
|
||||
sfx_play(uid, arg1, sampleRate, position, minFadeDistance, maxFadeDistance, 1);
|
||||
}
|
||||
|
||||
void func_8030E9C4(enum sfx_e uid, f32 arg1, u32 arg2, f32 arg3[3], f32 arg4, f32 arg5){
|
||||
func_8030E78C(uid, arg1, arg2, arg3, arg4, arg5, 0);
|
||||
void func_8030E9C4(enum sfx_e uid, f32 arg1, u32 sampleRate, f32 position[3], f32 minFadeDistance, f32 maxFadeDistance){
|
||||
sfx_play(uid, arg1, sampleRate, position, minFadeDistance, maxFadeDistance, 0);
|
||||
}
|
||||
|
||||
void func_8030E9FC(enum sfx_e uid, f32 arg1, f32 arg2, u32 arg3, f32 arg4[3], f32 arg5, f32 arg6){
|
||||
func_8030E78C(uid, sfx_randf2(arg1, arg2), arg3, arg4, arg5, arg6, 2);
|
||||
void func_8030E9FC(enum sfx_e uid, f32 arg1, f32 arg2, u32 sampleRate, f32 position[3], f32 minFadeDistance, f32 maxFadeDistance){
|
||||
sfx_play(uid, sfx_randf2(arg1, arg2), sampleRate, position, minFadeDistance, maxFadeDistance, 2);
|
||||
}
|
||||
|
||||
void func_8030EA54(enum sfx_e uid, f32 arg1, f32 arg2, u32 arg3, f32 arg4[3], f32 arg5, f32 arg6){
|
||||
func_8030E78C(uid, sfx_randf2(arg1, arg2), arg3, arg4, arg5, arg6, 1);
|
||||
void func_8030EA54(enum sfx_e uid, f32 arg1, f32 arg2, u32 sampleRate, f32 position[3], f32 minFadeDistance, f32 maxFadeDistance){
|
||||
sfx_play(uid, sfx_randf2(arg1, arg2), sampleRate, position, minFadeDistance, maxFadeDistance, 1);
|
||||
}
|
||||
|
||||
void func_8030EAAC(enum sfx_e uid, f32 arg1, s32 arg2, s32 arg3){
|
||||
|
|
|
@ -35,7 +35,7 @@ void func_80290298(void) {
|
|||
is_pumpkin = player_getTransformation() == TRANSFORM_3_PUMPKIN;
|
||||
sp30 = (func_8028B528() && !is_pumpkin) ? 6 : 1;
|
||||
sp24 = func_8028B528() && !is_pumpkin;
|
||||
if (D_8037C02C || func_8028B2E8() || sp24 || func_8028ECAC() == BSGROUP_5_CLIMB || bs_getState() == BS_B_UNKOWN) {
|
||||
if (D_8037C02C || player_isStable() || sp24 || func_8028ECAC() == BSGROUP_5_CLIMB || bs_getState() == BS_B_UNKOWN) {
|
||||
_player_getPosition(D_8037C020);
|
||||
}
|
||||
|
||||
|
|
|
@ -89,7 +89,7 @@ void func_802906D8(void){
|
|||
int underwater_or_walrus_in_water;
|
||||
|
||||
func_80290444();
|
||||
underwater_or_walrus_in_water = (func_8028EE84() == BSWATERGROUP_2_UNDERWATER);
|
||||
underwater_or_walrus_in_water = (player_getWaterState() == BSWATERGROUP_2_UNDERWATER);
|
||||
if(!underwater_or_walrus_in_water){
|
||||
underwater_or_walrus_in_water = (player_getTransformation() == TRANSFORM_4_WALRUS && player_inWater());
|
||||
}
|
||||
|
|
|
@ -254,7 +254,7 @@ void func_8031C29C(struct0 *arg0) {
|
|||
|
||||
ml_vec3f_copy(sp30, arg0->unk1C);
|
||||
sp48 = ((arg0->unk1C[1] - arg0->posX) > 120.0) ? 1 : 0;
|
||||
sp40 = func_8023DB4C(1);
|
||||
sp40 = globalTimer_getTimeMasked(1);
|
||||
if ((sp48 == 0) || (sp40 != 0)) {
|
||||
arg0->unk59 = arg0->unk5B;
|
||||
temp_v0 = func_8031BBA0(&sp30, 60.0f, -390.0f, arg0->unk54 | 0x1E0000, &sp4C);
|
||||
|
|
|
@ -103,7 +103,7 @@ int func_80290D48(void){
|
|||
}
|
||||
|
||||
int func_80290E8C(void){
|
||||
if(func_8028EE84() != BSWATERGROUP_2_UNDERWATER)
|
||||
if(player_getWaterState() != BSWATERGROUP_2_UNDERWATER)
|
||||
return FALSE;
|
||||
|
||||
ncDynamicCamera_setState(3);
|
||||
|
|
|
@ -186,7 +186,7 @@ void func_8032CD60(Prop *prop) {
|
|||
sp30 = (sp44 == 3) ? sp38 : (sp38 - sp34)*2;
|
||||
|
||||
sp2C = (s32)((((u32)(((u16*)prop)[5]) << 0x15) >> 0x1B) * sp30) / 32;
|
||||
var_v1 = (((func_8023DB5C(sp34, sp30, prop, sp40) % (sp30 * sp48)) / sp48) + sp2C) % sp30;
|
||||
var_v1 = (((globalTimer_getTime(sp34, sp30, prop, sp40) % (sp30 * sp48)) / sp48) + sp2C) % sp30;
|
||||
var_t5 = 0;
|
||||
switch (sp40) { /* irregular */
|
||||
default:
|
||||
|
@ -1398,7 +1398,7 @@ void func_803306C8(s32 arg0) {
|
|||
s32 var_s0_2;
|
||||
s32 var_s1;
|
||||
|
||||
temp_fp = func_8023DB5C() - func_80255B08(arg0);
|
||||
temp_fp = globalTimer_getTime() - func_80255B08(arg0);
|
||||
func_80254BD0(&sp54, 1);
|
||||
if(sp54 > 256000) return;
|
||||
|
||||
|
@ -1514,7 +1514,7 @@ BKModelBin *func_80330B1C(ActorMarker *this){
|
|||
if(!this->unk18 && this->propPtr->unk8_1 && modelInfo->modelPtr && func_8033A12C(modelInfo->modelPtr)){
|
||||
this->unk18 = func_80330B10();
|
||||
}
|
||||
modelInfo->unk10 = func_8023DB5C();
|
||||
modelInfo->unk10 = globalTimer_getTime();
|
||||
return modelInfo->modelPtr;
|
||||
}
|
||||
|
||||
|
@ -1577,7 +1577,7 @@ BKSpriteDisplayData *func_80330E54(ActorMarker *marker, BKSprite **sprite_ptr) {
|
|||
if (model_cache_ptr->unk4 == 0) {
|
||||
model_cache_ptr->unk4 = func_8033B6C4(marker->modelId, &model_cache_ptr->unk8);
|
||||
}
|
||||
model_cache_ptr->unk10 = func_8023DB5C();
|
||||
model_cache_ptr->unk10 = globalTimer_getTime();
|
||||
if (sprite_ptr != NULL) {
|
||||
*sprite_ptr = model_cache_ptr->unk4;
|
||||
}
|
||||
|
|
|
@ -554,7 +554,7 @@ void func_80334448(NodeProp *arg0, ActorMarker *arg1) {
|
|||
|
||||
switch(func_80330F7C(arg0)) {
|
||||
case 3: //L80334480
|
||||
sp24 = func_8023DB5C();
|
||||
sp24 = globalTimer_getTime();
|
||||
if ((func_80330FC4(arg0) + 1) != sp24) {
|
||||
D_8036F980[func_80330F8C(arg0)](arg0, arg1);
|
||||
}
|
||||
|
|
|
@ -312,7 +312,7 @@ s32 func_80334ECC(void) {
|
|||
func_80351C48();
|
||||
func_80330FF4();
|
||||
func_8028E71C();
|
||||
phi_v0 = func_8023DB5C();
|
||||
phi_v0 = globalTimer_getTime();
|
||||
if (D_80370250) {
|
||||
phi_v1 = 0xF;
|
||||
} else {
|
||||
|
|
|
@ -282,8 +282,8 @@ void func_803465E4(void){
|
|||
|
||||
if(!func_8028EC04() && func_8028F070()){
|
||||
if(level_get() != LEVEL_2_TREASURE_TROVE_COVE || !levelSpecificFlags_get(5)){
|
||||
is_underwater = (func_8028EE84() == BSWATERGROUP_2_UNDERWATER);
|
||||
is_on_water_surface = (func_8028EE84() == BSWATERGROUP_1_SURFACE);
|
||||
is_underwater = (player_getWaterState() == BSWATERGROUP_2_UNDERWATER);
|
||||
is_on_water_surface = (player_getWaterState() == BSWATERGROUP_1_SURFACE);
|
||||
is_in_polluted_or_winter_water = ((level_get() == LEVEL_9_RUSTY_BUCKET_BAY) || (map_get() == MAP_46_CCW_WINTER));
|
||||
if( is_in_polluted_or_winter_water && (is_underwater || is_on_water_surface)){ //L803467EC
|
||||
D_80385FEC = 2.0f;
|
||||
|
@ -326,7 +326,7 @@ void func_803465E4(void){
|
|||
}
|
||||
}//L80346B6C
|
||||
|
||||
if((func_8023DB5C() & 7) == 6){
|
||||
if((globalTimer_getTime() & 7) == 6){
|
||||
if(!func_80320708() || !func_80320248()){
|
||||
D_80385F30[randi2(0, 0x2C)] = 1;
|
||||
D_80385FF0[randi2(0, 0xE)] = 1;
|
||||
|
|
|
@ -80,7 +80,7 @@ void func_80349FB0(DemoInput *input_ptr, u32 size, int arg2){
|
|||
func_803204E4(0xc4, 1);
|
||||
func_8024F224();
|
||||
rand_reset();
|
||||
func_8023DB68();
|
||||
globalTimer_reset();
|
||||
}//*/
|
||||
|
||||
/* returns offset of current input */
|
||||
|
|
|
@ -329,7 +329,7 @@ void func_80355134(void) {
|
|||
sp3C = func_8033E864();
|
||||
sp38 = func_8033E888();
|
||||
sp34 = func_8033E8AC();
|
||||
if ((func_8023DB5C() & 1) == 0) {
|
||||
if ((globalTimer_getTime() & 1) == 0) {
|
||||
temp_s0->unk20--;
|
||||
}
|
||||
if (temp_s0->unk20 < 0) {
|
||||
|
@ -400,7 +400,7 @@ void func_803553E8(void) {
|
|||
sp3C = func_8033E864();
|
||||
sp38 = func_8033E888();
|
||||
sp34 = func_8033E8AC();
|
||||
if ((func_8023DB5C() & 1) == 0) {
|
||||
if ((globalTimer_getTime() & 1) == 0) {
|
||||
temp_s0->unk20--;
|
||||
}
|
||||
if (temp_s0->unk20 < 0) {
|
||||
|
|
|
@ -142,7 +142,7 @@ void func_8035DA1C(Actor *this) {
|
|||
if (randf() < 0.01) {
|
||||
LOCAL_D6600(this)->unk0 = 5;
|
||||
}
|
||||
if (LOCAL_D6600(this)->unk0 != 0 && !(func_8023DB5C() & 0xF)) {
|
||||
if (LOCAL_D6600(this)->unk0 != 0 && !(globalTimer_getTime() & 0xF)) {
|
||||
LOCAL_D6600(this)->unk0--;
|
||||
func_8035D95C(this->marker);
|
||||
}
|
||||
|
|
|
@ -435,7 +435,7 @@ void func_80360828(Actor *this){
|
|||
this->unk38_31 = 0x3C;
|
||||
}
|
||||
else{
|
||||
if(!(func_8023DB5C() & 0xf)){
|
||||
if(!(globalTimer_getTime() & 0xf)){
|
||||
if(randf() < 0.35){
|
||||
FUNC_8030E8B4(SFX_419_UNKNOWN, 1.0f, 28000, this->position, 1250, 2500);
|
||||
}
|
||||
|
|
|
@ -103,7 +103,7 @@ void func_80294B00(int arg0){
|
|||
void func_80294B0C(void){
|
||||
f32 sp1C = player_getYPosition();
|
||||
int sp18 = func_8028ECAC();
|
||||
if( func_8028B2E8()
|
||||
if( player_isStable()
|
||||
|| player_inWater()
|
||||
|| (sp18 == BSGROUP_A_FLYING && player_getActiveHitbox(0) != HITBOX_3_BEAK_BOMB)
|
||||
|| sp18 == BSGROUP_5_CLIMB
|
||||
|
@ -180,11 +180,11 @@ void func_80294E54(int arg0){
|
|||
}
|
||||
|
||||
void func_80294E60(void){
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
_player_getPosition(D_8037C2D8);
|
||||
}
|
||||
|
||||
if(func_8028B2E8() || bsclimb_inSet(bs_getState())){
|
||||
if(player_isStable() || bsclimb_inSet(bs_getState())){
|
||||
miscflag_clear(MISC_FLAG_5_HAS_PECKED);
|
||||
miscflag_clear(MISC_FLAG_12_HAS_FLAPPED);
|
||||
}
|
||||
|
|
|
@ -13,8 +13,8 @@ int should_beak_bust(void){
|
|||
return button_pressed(BUTTON_Z) && can_beak_bust();
|
||||
}
|
||||
|
||||
int func_80294F78(void){
|
||||
return button_pressed(BUTTON_C_UP) && func_8028ACD8();
|
||||
int should_look_first_person_camera(void){
|
||||
return button_pressed(BUTTON_C_UP) && can_view_first_person();
|
||||
}
|
||||
|
||||
int should_rotate_camera_left(void){
|
||||
|
|
|
@ -40,7 +40,7 @@ enum bs_e func_80295EE0(enum bs_e arg0){
|
|||
sp2C = 0;
|
||||
sp28 = 0;
|
||||
current_state = bs_getState();
|
||||
if(player_getTransformation() != TRANSFORM_1_BANJO || func_8028EE84() != BSWATERGROUP_0_NONE){
|
||||
if(player_getTransformation() != TRANSFORM_1_BANJO || player_getWaterState() != BSWATERGROUP_0_NONE){
|
||||
sp2C = 1;
|
||||
}
|
||||
if(bsjig_inJiggyJig(current_state)){
|
||||
|
@ -191,7 +191,7 @@ enum bs_e func_802962BC(u32 arg0){
|
|||
if(bsbtrot_inSet(bs_getState()))
|
||||
return BS_BTROT_OW;
|
||||
|
||||
if(func_8028EE84() == BSWATERGROUP_2_UNDERWATER)
|
||||
if(player_getWaterState() == BSWATERGROUP_2_UNDERWATER)
|
||||
return BS_7F_DIVE_OW;
|
||||
|
||||
if(func_8028ECAC() == BSGROUP_A_FLYING)
|
||||
|
@ -300,7 +300,7 @@ void func_80296608(void){
|
|||
break;
|
||||
case BS_INTR_A: //L8029666C
|
||||
sp2C = 2;
|
||||
if(func_8028B2E8()){
|
||||
if(player_isStable()){
|
||||
next_state = badrone_transform();
|
||||
}
|
||||
else{
|
||||
|
@ -443,7 +443,7 @@ void func_80296608(void){
|
|||
!func_80298850()
|
||||
&& !sp1C
|
||||
&& !miscflag_isTrue(0xf)
|
||||
&& !func_8028B2E8()
|
||||
&& !player_isStable()
|
||||
){
|
||||
next_state = BS_4F_CLIMB_IDLE;
|
||||
sp2C = 2;
|
||||
|
@ -474,7 +474,7 @@ void func_80296608(void){
|
|||
next_state = BS_24_FLY;
|
||||
}
|
||||
else{
|
||||
switch(func_8028EE84()){
|
||||
switch(player_getWaterState()){
|
||||
case BSWATERGROUP_1_SURFACE:
|
||||
next_state = BS_2D_SWIM_IDLE;
|
||||
break;
|
||||
|
@ -482,7 +482,7 @@ void func_80296608(void){
|
|||
next_state = BS_2B_DIVE_IDLE;
|
||||
break;
|
||||
case BSWATERGROUP_0_NONE://L80296B0C
|
||||
if(func_8028B2E8())
|
||||
if(player_isStable())
|
||||
next_state = bs_getIdleState();
|
||||
else
|
||||
next_state = func_8029BA80();
|
||||
|
|
|
@ -224,7 +224,7 @@ void fxhoneycarrierscore_update(s32 arg0, struct8s *arg1){
|
|||
if(D_8036A014 == NULL){
|
||||
D_8036A014 = assetcache_get(0x7DD);
|
||||
}
|
||||
D_803815C4 = func_8023DB5C();
|
||||
D_803815C4 = globalTimer_getTime();
|
||||
D_803815E4 = 0;
|
||||
D_803815E0 = 0.9999f;
|
||||
item_adjustByDiffWithHud(ITEM_13_EMPTY_HONEYCOMB, -6);
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue