document gGlobalTimer and related functions

This commit is contained in:
mariob92
2024-09-02 12:35:38 +02:00
parent 98e97f4e95
commit ec98c1620c
53 changed files with 102 additions and 102 deletions

View File

@@ -150,7 +150,7 @@ void func_80387CC0(void){
return; return;
viewport_get_rotation_vec3f(sp1C); viewport_get_rotation_vec3f(sp1C);
tmp_v0 = func_8023DB4C(0x7F); tmp_v0 = globalTimer_getTimeMasked(0x7F);
if(tmp_v0 >= 0x40){ if(tmp_v0 >= 0x40){
tmp_v0 = 0x7F - tmp_v0; tmp_v0 = 0x7F - tmp_v0;
} }

View File

@@ -70,7 +70,7 @@ Actor *func_80388740(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
|| this->state == 6 || this->state == 6
|| this->state == 8 || this->state == 8
){ ){
if(this->unk4C != 0.0f && (func_8023DB5C() & 1)){ if(this->unk4C != 0.0f && (globalTimer_getTime() & 1)){
if(-2.0 < this->roll){ if(-2.0 < this->roll){
func_8034A174(func_80329934(), 6, sp2C); func_8034A174(func_80329934(), 6, sp2C);
particleEmitter_setPosition(local->unk0, sp2C); particleEmitter_setPosition(local->unk0, sp2C);

View File

@@ -319,7 +319,7 @@ void func_8038D6C8(Actor *this){
if(!func_80329530(this, 800)) if(!func_80329530(this, 800))
break; break;
if(!(func_8023DB5C() & 1)) if(!(globalTimer_getTime() & 1))
subaddie_set_state_with_direction(this, 2, 0.001f, 1); subaddie_set_state_with_direction(this, 2, 0.001f, 1);
else else
subaddie_set_state_with_direction(this, 2, 0.999f, 0); subaddie_set_state_with_direction(this, 2, 0.999f, 0);

View File

@@ -74,11 +74,11 @@ void func_80390EB0(Actor *this){
if(func_8024DB50(this->position, 150.0f) || func_80329530(this, 1200)) 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); func_80390C70(this->position);
} }
if( !(func_8023DB5C() & 3) && randf() < 0.7){ if( !(globalTimer_getTime() & 3) && randf() < 0.7){
func_80390D58(this->position); func_80390D58(this->position);
} }
} }

View File

@@ -87,7 +87,7 @@ void func_80391040(Actor *this){
if( !this->marker->unk14_21 ) return; if( !this->marker->unk14_21 ) return;
if( !func_80390FC0() ) return; if( !func_80390FC0() ) return;
if( func_8023DB5C() & 7 ) return; if( globalTimer_getTime() & 7 ) return;
if(randf() < 0.5){ if(randf() < 0.5){
a1 = 8; a1 = 8;

View File

@@ -176,7 +176,7 @@ void chAncientOne_update(Actor *this){
} }
} }
else{//L80386C64 else{//L80386C64
sp38 = func_8023DB5C() & 0xF; sp38 = globalTimer_getTime() & 0xF;
sp34 = LOCAL_CH_ANCIENT_ONE(this)->unk1C + 40.0f; sp34 = LOCAL_CH_ANCIENT_ONE(this)->unk1C + 40.0f;
this->position_y += 18.0; this->position_y += 18.0;
this->position_x += (sp38 & 1) ? 0x17 : -0x17; this->position_x += (sp38 & 1) ? 0x17 : -0x17;

View File

@@ -293,7 +293,7 @@ void GV_func_8038BEA0(Actor *this){
else{ else{
func_8030E2C4(this->unk44_31); func_8030E2C4(this->unk44_31);
this->position_y -= 7.0; this->position_y -= 7.0;
if(func_8023DB5C() & 1){ if(globalTimer_getTime() & 1){
sp38[0] = this->position_x; sp38[0] = this->position_x;
sp38[1] = this->position_y; sp38[1] = this->position_y;
sp38[2] = this->position_z; sp38[2] = this->position_z;

View File

@@ -27,8 +27,8 @@ void _chchimpystump_80386CA0(Actor *this){
func_802BB3DC(1, 3.0f, 1.0f); func_802BB3DC(1, 3.0f, 1.0f);
func_80244BB0(0, 0x6A, 0x7FF8, 0.2f); func_80244BB0(0, 0x6A, 0x7FF8, 0.2f);
}//L80386D0C }//L80386D0C
this->position_x = ((func_8023DB5C() & 1) * 2) ^ (s32)this->position_x; this->position_x = ((globalTimer_getTime() & 1) * 2) ^ (s32)this->position_x;
this->position_z = ((func_8023DB5C() & 2) * 2) ^ (s32)this->position_z; this->position_z = ((globalTimer_getTime() & 2) * 2) ^ (s32)this->position_z;
} }
} }
@@ -57,7 +57,7 @@ void chchimpystump_update(Actor *this){
func_802BB41C(1); func_802BB41C(1);
func_80244C78(0); func_80244C78(0);
} }
if((func_8023DB5C() & 3) == 2) if((globalTimer_getTime() & 3) == 2)
func_80353064(this->position, 40.0f); func_80353064(this->position, 40.0f);
break; break;
case 3: case 3:

View File

@@ -83,7 +83,7 @@ void func_80386FB0(Actor *this){
} }
void func_80386FE8(void){ void func_80386FE8(void){
if( (func_8023DB5C() & 0xF) == 0xB if( (globalTimer_getTime() & 0xF) == 0xB
&& 0.85 < randf () && 0.85 < randf ()
&& !func_803114B0() && !func_803114B0()
){ ){

View File

@@ -34,8 +34,8 @@ void func_8038B900(Actor *this){
this->marker->propPtr->unk8_3 = 1; this->marker->propPtr->unk8_3 = 1;
if(this->marker->unk14_21){ if(this->marker->unk14_21){
sp54 = skeletalAnim_getProgress(this->unk148); sp54 = skeletalAnim_getProgress(this->unk148);
if( ( func_8023DB5C() & (1 << 4) ) if( ( globalTimer_getTime() & (1 << 4) )
&& ( func_8023DB5C() & (1 << 2) ) && ( globalTimer_getTime() & (1 << 2) )
&& ( randf() < 0.90 ) && ( randf() < 0.90 )
){ ){
if( ( this->state == 3 if( ( this->state == 3

View File

@@ -11,7 +11,7 @@ void func_8023DFF0(s32);
s32 D_80275610 = 0; s32 D_80275610 = 0;
s32 D_80275614 = 0; s32 D_80275614 = 0;
u32 D_80275618 = 0; u32 gGlobalTimer = 0;
u32 D_8027561C[] = { u32 D_8027561C[] = {
0x9, 0x4, 0xA, 0x3, 0xB, 0x2, 0xC, 0x5, 0x0, 0x9, 0x4, 0xA, 0x3, 0xB, 0x2, 0xC, 0x5, 0x0,
0x1, 0x6, 0xD, -1 0x1, 0x6, 0xD, -1
@@ -68,16 +68,16 @@ void func_8023DA9C(s32 arg0){
func_80255CD8(); func_80255CD8();
} }
u32 func_8023DB4C(u32 arg0){ u32 globalTimer_getTimeMasked(u32 mask){
return D_80275618 & arg0; return gGlobalTimer & mask;
} }
s32 func_8023DB5C(void){ s32 globalTimer_getTime(void){
return D_80275618; return gGlobalTimer;
} }
void func_8023DB68(void){ void globalTimer_reset(void){
D_80275618 = 0; gGlobalTimer = 0;
} }
s32 func_8023DB74(void){ s32 func_8023DB74(void){
@@ -117,16 +117,16 @@ void core1_init(void){
ml_init(); ml_init();
gctransition_reset(); gctransition_reset();
D_8027A130 = 0; D_8027A130 = 0;
D_80275618 = 0; gGlobalTimer = 0;
func_8023DA9C(3); func_8023DA9C(3);
} }
void func_8023DCDC(void){ void globalTimer_incTimer(void){
D_80275618++; gGlobalTimer++;
} }
void func_8023DCF4(void){ void globalTimer_decTimer(void){
D_80275618--; gGlobalTimer--;
} }
void mainLoop(void){ void mainLoop(void){
@@ -136,12 +136,12 @@ void mainLoop(void){
u16 rgba; u16 rgba;
s32 offset; s32 offset;
if((func_8023DB5C() & 0x7f) == 0x11) if((globalTimer_getTime() & 0x7f) == 0x11)
sns_write_payload_over_heap(); sns_write_payload_over_heap();
func_8023DA74(); func_8023DA74();
if(D_8027A130 != 3 || getGameMode() != GAME_MODE_4_PAUSED) if(D_8027A130 != 3 || getGameMode() != GAME_MODE_4_PAUSED)
func_8023DCDC(); globalTimer_incTimer();
if(!D_8027BEEC) if(!D_8027BEEC)
pfsManager_update(); pfsManager_update();
@@ -178,7 +178,7 @@ void mainLoop(void){
//render weird CRC failure image //render weird CRC failure image
for(y= 0x1e; y < framebuffer_height - 0x1e; y++){//L8023DEB4 for(y= 0x1e; y < framebuffer_height - 0x1e; y++){//L8023DEB4
for(x = 0x14; x < 0xeb; x++){ 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); r = _SHIFTL(x>>3, 11, 5);
g = _SHIFTL(y>>3, 6, 5); g = _SHIFTL(y>>3, 6, 5);

View File

@@ -126,7 +126,7 @@ s32 func_8024E67C(s32 controller_index){
} }
s32 func_8024E698(s32 controller_index){ s32 func_8024E698(s32 controller_index){
if(func_8023DB5C() < 2){ if(globalTimer_getTime() < 2){
return 0; return 0;
} }

View File

@@ -211,7 +211,7 @@ void sns_write_payload_over_heap(void)
s32 val2; s32 val2;
u32 i; u32 i;
if (func_8023DB5C() <= 0x3B || snsToRestoreItems) if (globalTimer_getTime() <= 0x3B || snsToRestoreItems)
return; return;
sns_generate_payload(snsBasePayloadPtr2); sns_generate_payload(snsBasePayloadPtr2);

View File

@@ -195,12 +195,12 @@ void func_80247C20(void) {
s32 i; s32 i;
if (D_80275BE4 == 0) { if (D_80275BE4 == 0) {
D_80275BE4 = func_8023DB5C(); D_80275BE4 = globalTimer_getTime();
return; return;
} }
if (func_8023DB5C() != D_80275BE4) { if (globalTimer_getTime() != D_80275BE4) {
D_80275BE0 = FALSE; D_80275BE0 = FALSE;
D_80275BE4 = func_8023DB5C(); D_80275BE4 = globalTimer_getTime();
} }
if (D_80275BE0) { if (D_80275BE0) {

View File

@@ -217,7 +217,7 @@ void bsbfly_update(void){
if(button_pressed(BUTTON_A)) if(button_pressed(BUTTON_A))
D_8037D347 = 1; D_8037D347 = 1;
if(D_8037D347 && func_8023DB5C()%3 == 0){ if(D_8037D347 && globalTimer_getTime()%3 == 0){
D_8037D347 = 0; D_8037D347 = 0;
func_80346C10(&sp2C, 0, BS_1_IDLE, ITEM_F_RED_FEATHER, 1); func_80346C10(&sp2C, 0, BS_1_IDLE, ITEM_F_RED_FEATHER, 1);
} }

View File

@@ -49,7 +49,7 @@ void bsbshock_charge_update(void){
f32 sp1C[3]; f32 sp1C[3];
if(func_8028B2E8()){ if(func_8028B2E8()){
if(func_8023DB5C() % 2) if(globalTimer_getTime() % 2)
func_8029C348(); func_8029C348();
} }
else else

View File

@@ -428,7 +428,7 @@ void func_802A8098(void) {
} }
switch (D_8037D396) { switch (D_8037D396) {
case 0: case 0:
if (func_8023DB4C(1) == 0) { if (globalTimer_getTimeMasked(1) == 0) {
_player_getPosition(plyr_pos); _player_getPosition(plyr_pos);
plyr_pos[1] += 60.0f; plyr_pos[1] += 60.0f;
p_ctrl = func_8029B950(plyr_pos, 25.0f); p_ctrl = func_8029B950(plyr_pos, 25.0f);

View File

@@ -152,10 +152,10 @@ void func_802B5950(void) {
next_state = 0; next_state = 0;
anim_ctrl = baanim_getAnimCtrlPtr(); 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); func_8029C304(1);
} }
if ((func_8023DB4C(7) == 0) && ((f64) randf() < 0.5)) { if ((globalTimer_getTimeMasked(7) == 0) && ((f64) randf() < 0.5)) {
func_802B5480(); func_802B5480();
} }
if (animctrl_isAt(anim_ctrl, 0.01f) != 0) { if (animctrl_isAt(anim_ctrl, 0.01f) != 0) {

View File

@@ -568,7 +568,7 @@ void bswalrus_sled_update(void){
f32 sp20[3]; f32 sp20[3];
if(50.0f < baphysics_get_horizontal_velocity()){ if(50.0f < baphysics_get_horizontal_velocity()){
if(func_8023DB4C(1)){ if(globalTimer_getTimeMasked(1)){
baModel_80292554(&sp20); baModel_80292554(&sp20);
}else{ }else{
baModel_80292578(&sp20); baModel_80292578(&sp20);

View File

@@ -27,7 +27,7 @@ void chBadShad_update(Actor *this){
this->initialized = 1; this->initialized = 1;
this->marker->collidable = 0; 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 //unlink
if(this->unk104){ if(this->unk104){
marker_getActor(this->unk104)->unk104 = 0; marker_getActor(this->unk104)->unk104 = 0;
@@ -116,7 +116,7 @@ void func_802D71A0(s32 this, s32 arg1){
if(sp3C){ if(sp3C){
marker_getActor(marker)->unk104 = sp3C->marker; marker_getActor(marker)->unk104 = sp3C->marker;
sp3C->unk104 = marker; sp3C->unk104 = marker;
sp3C->unk1C[0] = func_8023DB5C(); sp3C->unk1C[0] = globalTimer_getTime();
sp3C->unk1C[1] = sp40; sp3C->unk1C[1] = sp40;
sp3C->unk28 = sp28; sp3C->unk28 = sp28;
} }
@@ -145,7 +145,7 @@ void func_802D729C(Actor *actor, f32 arg1){
if(sp1C->despawn_flag == TRUE) if(sp1C->despawn_flag == TRUE)
return; return;
if(!((func_8023DB5C() ^ actor->marker->actrArrayIdx) & 0x7)){ if(!((globalTimer_getTime() ^ actor->marker->actrArrayIdx) & 0x7)){
sp1C->unk28 = func_802D7038(actor); sp1C->unk28 = func_802D7038(actor);
sp1C->position_x = D_8037DE10[0]; sp1C->position_x = D_8037DE10[0];
sp1C->position_y = D_8037DE10[1] + 6.0f; 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_x = actor->position_x;
sp1C->position_z = actor->position_z; sp1C->position_z = actor->position_z;
} }
sp1C->unk1C[0] = func_8023DB5C(); sp1C->unk1C[0] = globalTimer_getTime();
sp1C->unk1C[1] = arg1; sp1C->unk1C[1] = arg1;
} }

View File

@@ -161,13 +161,13 @@ void func_802C6240(Actor *this){
if(!func_80329030(this, 0) && func_80329480(this)){ if(!func_80329030(this, 0) && func_80329480(this)){
func_80328CEC(this, (s32)this->yaw, 90, 150); func_80328CEC(this, (s32)this->yaw, 90, 150);
}//L802C64EC }//L802C64EC
if(!(func_8023DB5C() & 0xf)) if(!(globalTimer_getTime() & 0xf))
func_80328CEC(this, (s32)this->yaw_ideal, 10, 20); 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); 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) && func_80329078(this, (s32)this->yaw_ideal, 150)
&& subaddie_maybe_set_state(this, 3, 0.13f) && subaddie_maybe_set_state(this, 3, 0.13f)
){ ){
@@ -191,7 +191,7 @@ void func_802C6240(Actor *this){
subaddie_set_state(this, 2); subaddie_set_state(this, 2);
func_802C5E80(this); 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_802C5E80(this);
func_802C5EB8(this); func_802C5EB8(this);
break; break;
@@ -356,7 +356,7 @@ Actor *func_802C6E84(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
} }
break; break;
case 4://L802C6F50 case 4://L802C6F50
if((func_8023DB5C() & 1) == 1){ if((globalTimer_getTime() & 1) == 1){
if(func_80259808(actor->yaw)){ if(func_80259808(actor->yaw)){
func_802C6E3C(0xb, sp34); func_802C6E3C(0xb, sp34);
func_802C6E3C(0xa, sp34); func_802C6E3C(0xa, sp34);
@@ -369,7 +369,7 @@ Actor *func_802C6E84(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
break; break;
case 1://L802C6FB4 case 1://L802C6FB4
if(actor_animationIsAt(actor, 0.85f) if(actor_animationIsAt(actor, 0.85f)
&& (func_8023DB5C()& 0xe) == 8 && (globalTimer_getTime()& 0xe) == 8
&& randf() < 0.6 && randf() < 0.6
){ ){
func_8034A174(func_80329934(),5, sp40); func_8034A174(func_80329934(),5, sp40);

View File

@@ -232,7 +232,7 @@ void chCrab_update(Actor *this) {
static s32 D_803670B0 = 0; static s32 D_803670B0 = 0;
static s32 D_803670B4 = 0; static s32 D_803670B4 = 0;
sp34 = func_8023DB5C(); sp34 = globalTimer_getTime();
sp30 = time_getDelta(); sp30 = time_getDelta();
is_mutant_snippet = this->modelCacheIndex == ACTOR_F5_MUTIE_SNIPPET; is_mutant_snippet = this->modelCacheIndex == ACTOR_F5_MUTIE_SNIPPET;
if (!this->unk16C_4) { if (!this->unk16C_4) {
@@ -343,7 +343,7 @@ void chCrab_update(Actor *this) {
break; break;
case 4: //L802CC024 case 4: //L802CC024
if ((func_8023DB5C() & 0xF) == 9) { if ((globalTimer_getTime() & 0xF) == 9) {
this->yaw_ideal = (f32) func_80329784(this); this->yaw_ideal = (f32) func_80329784(this);
} }
func_80328FB0(this, 7.0f); func_80328FB0(this, 7.0f);

View File

@@ -76,10 +76,10 @@ void chfirefx_update(Actor *this){
}//L80359934 }//L80359934
if(subaddie_playerIsWithinSphere(this, 2000)){ if(subaddie_playerIsWithinSphere(this, 2000)){
if( func_8024DB50(this->position, 50.0f) && this->unk38_31 ){ 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); __chfirefx_spawnSmoke(this->position, this->scale);
} //L803599AC } //L803599AC
if(!(func_8023DB5C() & 3) && randf() < 0.3){ if(!(globalTimer_getTime() & 3) && randf() < 0.3){
__chfirefx_spawnSpark(this->position, this->scale); __chfirefx_spawnSpark(this->position, this->scale);
} }
}//L803599F4 }//L803599F4

View File

@@ -200,7 +200,7 @@ void func_8035B8A8(Actor *this){
void func_8035B900(Actor *this){ void func_8035B900(Actor *this){
ActorLocal_Core2_D4050 *local = (ActorLocal_Core2_D4050 *)&this->local; ActorLocal_Core2_D4050 *local = (ActorLocal_Core2_D4050 *)&this->local;
s32 sp30 = func_8023DB5C(); s32 sp30 = globalTimer_getTime();
f32 sp2C = time_getDelta(); f32 sp2C = time_getDelta();
if(!this->unk16C_4){ if(!this->unk16C_4){
this->unk16C_4 = TRUE; this->unk16C_4 = TRUE;
@@ -346,7 +346,7 @@ void func_8035BD48(Actor *this){
func_80343DEC(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); func_8030E878(0x3f4, randf2(1.0f, 1.2f), 32000, this->position, this->scale*400.0f, this->scale*1800.0f);
} }
} }

View File

@@ -83,7 +83,7 @@ int func_80359F40(Actor *this, f32 arg1[3]){
f32 sp20; f32 sp20;
sp24 = func_80257204(this->position[0], this->position[2], arg1[0], arg1[2]); 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); this->velocity[2] = (f32)randi2(-45, 45);
} }
sp20 = this->yaw; sp20 = this->yaw;
@@ -177,7 +177,7 @@ void func_8035A694(Actor *this){
sp3C = this->yaw; sp3C = this->yaw;
sp38 = this->unk28*1.5 + 1.0; sp38 = this->unk28*1.5 + 1.0;
tmp_v0 = func_8023DB5C(); tmp_v0 = globalTimer_getTime();
this->yaw += sp38; this->yaw += sp38;
if(360.0f < this->yaw) if(360.0f < this->yaw)
this->yaw -= 360.0f; this->yaw -= 360.0f;

View File

@@ -113,7 +113,7 @@ void chSnowball_update(Actor *this) {
this->initialized = TRUE; this->initialized = TRUE;
player_getPosition(sp7C); player_getPosition(sp7C);
sp7C[1] += 1.0f; sp7C[1] += 1.0f;
phi_a1 = (func_8023DB5C() & 1) ? 0x15 : 0x2B; phi_a1 = (globalTimer_getTime() & 1) ? 0x15 : 0x2B;
for(i = 0; i < 3; i++){ for(i = 0; i < 3; i++){
sp58[i] = sp7C[i] + (sp7C[i] - this->unk1C[i]) * phi_a1; sp58[i] = sp7C[i] + (sp7C[i] - this->unk1C[i]) * phi_a1;
} }

View File

@@ -98,7 +98,7 @@ void __chSnowman_spawnHat(ActorMarker *marker){
other->velocity[0] = 34.0f; 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); ml_vec3f_yaw_rotate_copy(other->velocity, other->velocity, other->yaw - sp28);
other->velocity[1] = 30.0f; other->velocity[1] = 30.0f;
} }
@@ -260,7 +260,7 @@ void chSnowman_update(Actor *this){
|| fileProgressFlag_get(0x13) || fileProgressFlag_get(0x13)
){//L802E2318 ){//L802E2318
if(0.0 < local->unk4){ if(0.0 < local->unk4){
if( (func_8023DB5C() & 1) if( (globalTimer_getTime() & 1)
|| func_8028ECAC() == BSGROUP_A_FLYING || func_8028ECAC() == BSGROUP_A_FLYING
){//L802E236C ){//L802E236C
local->unk4 -= dt; local->unk4 -= dt;

View File

@@ -150,7 +150,7 @@ void chTermite_update(Actor *this) {
static s32 D_80372F48 = 0; static s32 D_80372F48 = 0;
static s32 D_80372F4C = 0; static s32 D_80372F4C = 0;
sp34 = func_8023DB5C(); sp34 = globalTimer_getTime();
if (!this->unk16C_4) { if (!this->unk16C_4) {
marker_setCollisionScripts(this->marker, NULL, __chTermite_ow, __chTermite_die); marker_setCollisionScripts(this->marker, NULL, __chTermite_ow, __chTermite_die);
this->unk124_0 = this->unk138_31 = FALSE; this->unk124_0 = this->unk138_31 = FALSE;

View File

@@ -539,7 +539,7 @@ void func_802D4388(Actor *this){
Actor *func_802D4588(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx) { Actor *func_802D4588(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx) {
s32 phi_a1; 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); func_8033A45C(1, phi_a1);
return actor_draw(marker, gfx, mtx, vtx); return actor_draw(marker, gfx, mtx, vtx);
} }

View File

@@ -131,14 +131,14 @@ bool func_802DAFBC(Actor *this) {
if (temp_v0 & 4) { if (temp_v0 & 4) {
func_8032C9E0(sp38); func_8032C9E0(sp38);
sp34 = func_80257248(sp38, this->position); 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); func_802DAF2C(this->position, this->yaw, this->unk28);
} else { } else {
func_80328CEC(this, (s32) sp34, 0, 0xF); func_80328CEC(this, (s32) sp34, 0, 0xF);
} }
this->unk38_31 = 0x1E; this->unk38_31 = 0x1E;
this->unk38_0 = TRUE; this->unk38_0 = TRUE;
local->unk38 = func_8023DB5C(); local->unk38 = globalTimer_getTime();
} else if (temp_v0 & 8) { } else if (temp_v0 & 8) {
func_802DAE10(this); func_802DAE10(this);
this->unk38_31 = 0x5A; this->unk38_31 = 0x5A;
@@ -284,13 +284,13 @@ void func_802DB5A0(Actor *this) {
func_80328FB0(this, 2.0f); func_80328FB0(this, 2.0f);
func_802DB3B0(this); func_802DB3B0(this);
if (this->unk38_31 == 0) { if (this->unk38_31 == 0) {
if (!(func_8023DB5C() & 0xF)) { if (!(globalTimer_getTime() & 0xF)) {
func_80328CEC(this, this->yaw_ideal, 0xA, 0x14); func_80328CEC(this, this->yaw_ideal, 0xA, 0x14);
} }
if (!(func_8023DB5C() & 7)) { if (!(globalTimer_getTime() & 7)) {
subaddie_maybe_set_state(this, 1, 0.02f); subaddie_maybe_set_state(this, 1, 0.02f);
} }
if( !(func_8023DB5C() & 0xF) if( !(globalTimer_getTime() & 0xF)
&& func_80329078(this, (s32) this->yaw_ideal, 0x96) && func_80329078(this, (s32) this->yaw_ideal, 0x96)
) { ) {
if (subaddie_maybe_set_state(this, 3, 0.13f) != 0) { if (subaddie_maybe_set_state(this, 3, 0.13f) != 0) {
@@ -316,7 +316,7 @@ void func_802DB5A0(Actor *this) {
case 3://L802DB930 case 3://L802DB930
func_80328FB0(this, 3.0f); func_80328FB0(this, 3.0f);
func_802DB3B0(this); 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_802DAE10(this);
} }
func_802DB220(this); func_802DB220(this);
@@ -351,7 +351,7 @@ void func_802DB5A0(Actor *this) {
case 7://L802DBB4C case 7://L802DBB4C
if (this->unk38_31 == 0) { if (this->unk38_31 == 0) {
if ((func_8023DB5C() & 0xF) == 9) { if ((globalTimer_getTime() & 0xF) == 9) {
this->yaw_ideal = (f32) func_80329784(this); this->yaw_ideal = (f32) func_80329784(this);
} }
} }

View File

@@ -59,7 +59,7 @@ void func_802DC208(Actor *this) {
} }
if( func_8024DB50(this->position, 50.0f) if( func_8024DB50(this->position, 50.0f)
&& func_802DC188() && func_802DC188()
&& !(func_8023DB5C() & 0x1F) && !(globalTimer_getTime() & 0x1F)
&& randf() < 0.1 && randf() < 0.1
){ ){
switch((s32)this->yaw){ switch((s32)this->yaw){

View File

@@ -124,7 +124,7 @@ void func_802F919C(void) {
return; return;
} }
temp_f20 = time_getDelta(); temp_f20 = time_getDelta();
sp60 = (func_8023DB5C() & 1) * 2; sp60 = (globalTimer_getTime() & 1) * 2;
player_getPosition(D_80381040); player_getPosition(D_80381040);
D_80369280->unkC[0] = D_80381040[0] - D_80369280->unk0[0]; D_80369280->unkC[0] = D_80381040[0] - D_80369280->unk0[0];

View File

@@ -144,7 +144,7 @@ void itemPrint_update(void) {
} else { } else {
itemPrintValues[i] += (sign * _73640_MIN(time_getDelta() * _73640_MAX(diff, 8.0f), 1.0)); 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); func_8025A6EC(D_80381168[i], 32000);
} }
if (D_80381378[i] != 0) { if (D_80381378[i] != 0) {

View File

@@ -2287,7 +2287,7 @@ void func_803086B4(void) {
cube = D_80381FA0.cube_list; cube = D_80381FA0.cube_list;
} }
}; };
if (func_8023DB5C() & 1) { if (globalTimer_getTime() & 1) {
if (D_8036ABA0 != NULL) { if (D_8036ABA0 != NULL) {
D_8036ABA0 = (s16*) defrag(D_8036ABA0); D_8036ABA0 = (s16*) defrag(D_8036ABA0);
} }

View File

@@ -64,7 +64,7 @@ BKModelBin *func_8030A428(s32 arg0){
if(D_80382390[arg0].unk0 == NULL){ if(D_80382390[arg0].unk0 == NULL){
D_80382390[arg0].unk0 = assetcache_get(0x2d1 + arg0); 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; 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){ 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); ((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; return D_80382394[arg0].unk4;
} }
@@ -154,7 +154,7 @@ void func_8030A850(s32 arg0) {
struct_7AF80_0 *sp3C; struct_7AF80_0 *sp3C;
struct_7AF80_1 *temp_a0_2; 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){ 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); sp3C = (struct_7AF80_0*)((u32)D_80382390 + sizeof(struct_7AF80_0)*D_8036B804);
if ((sp3C->unk0 != 0) && ((sp3C->unk4 < temp_s3) || (arg0 == 3))){ if ((sp3C->unk0 != 0) && ((sp3C->unk4 < temp_s3) || (arg0 == 3))){

View File

@@ -254,7 +254,7 @@ void func_8031C29C(struct0 *arg0) {
ml_vec3f_copy(sp30, arg0->unk1C); ml_vec3f_copy(sp30, arg0->unk1C);
sp48 = ((arg0->unk1C[1] - arg0->posX) > 120.0) ? 1 : 0; sp48 = ((arg0->unk1C[1] - arg0->posX) > 120.0) ? 1 : 0;
sp40 = func_8023DB4C(1); sp40 = globalTimer_getTimeMasked(1);
if ((sp48 == 0) || (sp40 != 0)) { if ((sp48 == 0) || (sp40 != 0)) {
arg0->unk59 = arg0->unk5B; arg0->unk59 = arg0->unk5B;
temp_v0 = func_8031BBA0(&sp30, 60.0f, -390.0f, arg0->unk54 | 0x1E0000, &sp4C); temp_v0 = func_8031BBA0(&sp30, 60.0f, -390.0f, arg0->unk54 | 0x1E0000, &sp4C);

View File

@@ -186,7 +186,7 @@ void func_8032CD60(Prop *prop) {
sp30 = (sp44 == 3) ? sp38 : (sp38 - sp34)*2; sp30 = (sp44 == 3) ? sp38 : (sp38 - sp34)*2;
sp2C = (s32)((((u32)(((u16*)prop)[5]) << 0x15) >> 0x1B) * sp30) / 32; 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; var_t5 = 0;
switch (sp40) { /* irregular */ switch (sp40) { /* irregular */
default: default:
@@ -1398,7 +1398,7 @@ void func_803306C8(s32 arg0) {
s32 var_s0_2; s32 var_s0_2;
s32 var_s1; s32 var_s1;
temp_fp = func_8023DB5C() - func_80255B08(arg0); temp_fp = globalTimer_getTime() - func_80255B08(arg0);
func_80254BD0(&sp54, 1); func_80254BD0(&sp54, 1);
if(sp54 > 256000) return; 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)){ if(!this->unk18 && this->propPtr->unk8_1 && modelInfo->modelPtr && func_8033A12C(modelInfo->modelPtr)){
this->unk18 = func_80330B10(); this->unk18 = func_80330B10();
} }
modelInfo->unk10 = func_8023DB5C(); modelInfo->unk10 = globalTimer_getTime();
return modelInfo->modelPtr; return modelInfo->modelPtr;
} }
@@ -1577,7 +1577,7 @@ BKSpriteDisplayData *func_80330E54(ActorMarker *marker, BKSprite **sprite_ptr) {
if (model_cache_ptr->unk4 == 0) { if (model_cache_ptr->unk4 == 0) {
model_cache_ptr->unk4 = func_8033B6C4(marker->modelId, &model_cache_ptr->unk8); 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) { if (sprite_ptr != NULL) {
*sprite_ptr = model_cache_ptr->unk4; *sprite_ptr = model_cache_ptr->unk4;
} }

View File

@@ -554,7 +554,7 @@ void func_80334448(NodeProp *arg0, ActorMarker *arg1) {
switch(func_80330F7C(arg0)) { switch(func_80330F7C(arg0)) {
case 3: //L80334480 case 3: //L80334480
sp24 = func_8023DB5C(); sp24 = globalTimer_getTime();
if ((func_80330FC4(arg0) + 1) != sp24) { if ((func_80330FC4(arg0) + 1) != sp24) {
D_8036F980[func_80330F8C(arg0)](arg0, arg1); D_8036F980[func_80330F8C(arg0)](arg0, arg1);
} }

View File

@@ -312,7 +312,7 @@ s32 func_80334ECC(void) {
func_80351C48(); func_80351C48();
func_80330FF4(); func_80330FF4();
func_8028E71C(); func_8028E71C();
phi_v0 = func_8023DB5C(); phi_v0 = globalTimer_getTime();
if (D_80370250) { if (D_80370250) {
phi_v1 = 0xF; phi_v1 = 0xF;
} else { } else {

View File

@@ -326,7 +326,7 @@ void func_803465E4(void){
} }
}//L80346B6C }//L80346B6C
if((func_8023DB5C() & 7) == 6){ if((globalTimer_getTime() & 7) == 6){
if(!func_80320708() || !func_80320248()){ if(!func_80320708() || !func_80320248()){
D_80385F30[randi2(0, 0x2C)] = 1; D_80385F30[randi2(0, 0x2C)] = 1;
D_80385FF0[randi2(0, 0xE)] = 1; D_80385FF0[randi2(0, 0xE)] = 1;

View File

@@ -80,7 +80,7 @@ void func_80349FB0(DemoInput *input_ptr, u32 size, int arg2){
func_803204E4(0xc4, 1); func_803204E4(0xc4, 1);
func_8024F224(); func_8024F224();
rand_reset(); rand_reset();
func_8023DB68(); globalTimer_reset();
}//*/ }//*/
/* returns offset of current input */ /* returns offset of current input */

View File

@@ -329,7 +329,7 @@ void func_80355134(void) {
sp3C = func_8033E864(); sp3C = func_8033E864();
sp38 = func_8033E888(); sp38 = func_8033E888();
sp34 = func_8033E8AC(); sp34 = func_8033E8AC();
if ((func_8023DB5C() & 1) == 0) { if ((globalTimer_getTime() & 1) == 0) {
temp_s0->unk20--; temp_s0->unk20--;
} }
if (temp_s0->unk20 < 0) { if (temp_s0->unk20 < 0) {
@@ -400,7 +400,7 @@ void func_803553E8(void) {
sp3C = func_8033E864(); sp3C = func_8033E864();
sp38 = func_8033E888(); sp38 = func_8033E888();
sp34 = func_8033E8AC(); sp34 = func_8033E8AC();
if ((func_8023DB5C() & 1) == 0) { if ((globalTimer_getTime() & 1) == 0) {
temp_s0->unk20--; temp_s0->unk20--;
} }
if (temp_s0->unk20 < 0) { if (temp_s0->unk20 < 0) {

View File

@@ -142,7 +142,7 @@ void func_8035DA1C(Actor *this) {
if (randf() < 0.01) { if (randf() < 0.01) {
LOCAL_D6600(this)->unk0 = 5; 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--; LOCAL_D6600(this)->unk0--;
func_8035D95C(this->marker); func_8035D95C(this->marker);
} }

View File

@@ -435,7 +435,7 @@ void func_80360828(Actor *this){
this->unk38_31 = 0x3C; this->unk38_31 = 0x3C;
} }
else{ else{
if(!(func_8023DB5C() & 0xf)){ if(!(globalTimer_getTime() & 0xf)){
if(randf() < 0.35){ if(randf() < 0.35){
FUNC_8030E8B4(SFX_419_UNKNOWN, 1.0f, 28000, this->position, 1250, 2500); FUNC_8030E8B4(SFX_419_UNKNOWN, 1.0f, 28000, this->position, 1250, 2500);
} }

View File

@@ -224,7 +224,7 @@ void fxhoneycarrierscore_update(s32 arg0, struct8s *arg1){
if(D_8036A014 == NULL){ if(D_8036A014 == NULL){
D_8036A014 = assetcache_get(0x7DD); D_8036A014 = assetcache_get(0x7DD);
} }
D_803815C4 = func_8023DB5C(); D_803815C4 = globalTimer_getTime();
D_803815E4 = 0; D_803815E4 = 0;
D_803815E0 = 0.9999f; D_803815E0 = 0.9999f;
item_adjustByDiffWithHud(ITEM_13_EMPTY_HONEYCOMB, -6); item_adjustByDiffWithHud(ITEM_13_EMPTY_HONEYCOMB, -6);

View File

@@ -929,7 +929,7 @@ void func_80316764(GcZoombox *this, s32 arg1) {
} }
} }
else if (arg1) { else if (arg1) {
if (!this->unk1A4_12 || (sp2C[0] == 0) || !(func_8023DB5C() & 1)){ if (!this->unk1A4_12 || (sp2C[0] == 0) || !(globalTimer_getTime() & 1)){
if (this->unk110[0] == -1.0f) { if (this->unk110[0] == -1.0f) {
func_80315C90(this, 1); func_80315C90(this, 1);
} }

View File

@@ -91,7 +91,7 @@ void func_8038D568(Actor *this){
ActorLocal_fight_6E90 *local = (ActorLocal_fight_6E90 *)&this->local; ActorLocal_fight_6E90 *local = (ActorLocal_fight_6E90 *)&this->local;
f32 sp48 = time_getDelta(); f32 sp48 = time_getDelta();
u32 sp44 = func_8023DB5C() & 0xF; u32 sp44 = globalTimer_getTime() & 0xF;
Actor *other; //sp40 Actor *other; //sp40
f32 sp3C; f32 sp3C;
f32 sp30[3]; f32 sp30[3];

View File

@@ -342,7 +342,7 @@ void func_803869BC(Actor *this) {
u32 temp_t3; u32 temp_t3;
if (this->marker->unk14_21) { if (this->marker->unk14_21) {
sp3C = func_8023DB5C(); sp3C = globalTimer_getTime();
temp_t3 = (u32) this->state; temp_t3 = (u32) this->state;
if ((temp_t3 == 6) || (temp_t3 == 7)) { if ((temp_t3 == 6) || (temp_t3 == 7)) {
sp30[0] = D_803916CC[0]; sp30[0] = D_803916CC[0];
@@ -852,7 +852,7 @@ void chfinalboss_phase1_setState(Actor *this, s32 next_state) {
f32 temp_f12; f32 temp_f12;
local = (ActorLocal_fight_180 *)&this->local; local = (ActorLocal_fight_180 *)&this->local;
sp40 = func_8023DB5C(); sp40 = globalTimer_getTime();
sp3C = animctrl_getAnimTimer(this->animctrl); sp3C = animctrl_getAnimTimer(this->animctrl);
local->phase = 1; local->phase = 1;
subaddie_set_state_with_direction(this, next_state, 0.0001f, 1); subaddie_set_state_with_direction(this, next_state, 0.0001f, 1);
@@ -936,7 +936,7 @@ void func_8038856C(Actor *actor, f32 *arg1) {
} }
void func_803885DC(Actor *this) { void func_803885DC(Actor *this) {
s32 sp24 = func_8023DB5C(); s32 sp24 = globalTimer_getTime();
if (func_8030E3FC(this->unk44_31) == 0) { if (func_8030E3FC(this->unk44_31) == 0) {
func_8030E2C4(this->unk44_31); func_8030E2C4(this->unk44_31);
@@ -1148,7 +1148,7 @@ void chfinalboss_phase2_setState(Actor *this, s32 arg1){
s32 sp28; s32 sp28;
local = (ActorLocal_fight_180 *)&this->local; local = (ActorLocal_fight_180 *)&this->local;
sp28 = func_8023DB5C(); sp28 = globalTimer_getTime();
local->phase = 2; local->phase = 2;
subaddie_set_state_with_direction(this, arg1, 0.0001f, 1); subaddie_set_state_with_direction(this, arg1, 0.0001f, 1);
actor_loopAnimation(this); actor_loopAnimation(this);

View File

@@ -108,7 +108,7 @@ void func_8038E2CC(ActorMarker *arg0) {
void chjinjonatorbase_update(Actor *this){ void chjinjonatorbase_update(Actor *this){
ActorLocal_fight_7BE0 *local = (ActorLocal_fight_7BE0 *)&this->local; ActorLocal_fight_7BE0 *local = (ActorLocal_fight_7BE0 *)&this->local;
f32 sp58 = time_getDelta(); f32 sp58 = time_getDelta();
s32 temp_s1 = func_8023DB5C() & 0xf; s32 temp_s1 = globalTimer_getTime() & 0xf;
s32 temp_s0; s32 temp_s0;
int i; int i;
Actor *other; Actor *other;

View File

@@ -323,7 +323,7 @@ void func_8038F620(Actor *this){
D_80391CEC, D_80391D34, D_80391CEC, D_80391D34,
D_80391CF4, D_80391D1C, D_80391D2C D_80391CF4, D_80391D1C, D_80391D2C
); );
func_8023DB5C(); globalTimer_getTime();
break; break;
}//L8038F918 }//L8038F918
D_803928F8[0] = this->position[0]; D_803928F8[0] = this->position[0];

View File

@@ -101,7 +101,7 @@ void func_8038FE94(Actor *this){
this->scale = (f64)this->scale + this->scale; this->scale = (f64)this->scale + this->scale;
}//L8038FF18 }//L8038FF18
this->roll += 20.0f; this->roll += 20.0f;
if(func_8023DB5C()%4 == 1){ if(globalTimer_getTime()%4 == 1){
if(randf() < 0.5){ if(randf() < 0.5){
func_8038EBE0(this->position, 4, ASSET_718_SPRITE_SPARKLE_WHITE_2, func_8038EBE0(this->position, 4, ASSET_718_SPRITE_SPARKLE_WHITE_2,
&D_80391F3C, &D_80391F54, &D_80391F6C, &D_80391F3C, &D_80391F54, &D_80391F6C,

View File

@@ -444,7 +444,7 @@ Actor *chWarpCauldron_draw(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx)
sp3C[0] = randi2(150, sp3C[1]); sp3C[0] = randi2(150, sp3C[1]);
sp3C[2] = 0; sp3C[2] = 0;
sp3C[3] = randi2(40, 80); sp3C[3] = randi2(40, 80);
if (func_8023DB5C() & 1) { if (globalTimer_getTime() & 1) {
func_802EE354(this, 0x3E9, 5, randi2(-10, 90), randf2(0.3f, 0.7f), 0.28f, 0.45f, sp3C, 5, 0); func_802EE354(this, 0x3E9, 5, randi2(-10, 90), randf2(0.3f, 0.7f), 0.28f, 0.45f, sp3C, 5, 0);
} }
} }

View File

@@ -405,7 +405,7 @@ void func_803867A8(Actor *this) {
this->position[0] = this->unk1C[0] + sp5C[0]; this->position[0] = this->unk1C[0] + sp5C[0];
this->position[2] = this->unk1C[2] + sp5C[2]; this->position[2] = this->unk1C[2] + sp5C[2];
if (this->marker->unk14_21) { if (this->marker->unk14_21) {
sp44 = this->unk158[func_8023DB5C() & 1]; sp44 = this->unk158[globalTimer_getTime() & 1];
if (sp44 != NULL) { if (sp44 != NULL) {
particleEmitter_setAlpha(sp44, this->alpha_124_19); particleEmitter_setAlpha(sp44, this->alpha_124_19);
phi_f0 = this->unk60 - 10.0f; phi_f0 = this->unk60 - 10.0f;