Renaming Actor.unk28
This commit is contained in:
parent
8af5e336a2
commit
17f1f826b5
|
@ -25,7 +25,7 @@
|
|||
extern f32 fabsf(f32);
|
||||
#pragma intrinsic (fabsf)
|
||||
|
||||
|
||||
#define AS_BOOL(expr) ((expr) ? TRUE : FALSE)
|
||||
|
||||
#define TUPLE_ASSIGN(out, a, b, c) {\
|
||||
out[0] = a;\
|
||||
|
|
|
@ -166,7 +166,7 @@ typedef struct actor_s{
|
|||
AnimCtrl *animctrl;
|
||||
ActorAnimationInfo *unk18;
|
||||
TUPLE(f32, unk1C);
|
||||
f32 unk28; //used in cheggs
|
||||
f32 actor_specific_1_f; //used in cheggs
|
||||
TUPLE(f32, velocity);
|
||||
u32 unk38_31:10;
|
||||
u32 unk38_21:9;
|
||||
|
|
|
@ -138,7 +138,7 @@ bool func_8038F5D4(Actor *this, f32 arg1[3], f32 arg2, f32 arg3, s32 arg4){
|
|||
if(actor_animationIsAt(this, 0.9f)){
|
||||
FUNC_8030E8B4(SFX_3F2_UNKNOWN, 0.8f, 24000, this->position, 500, 2000);
|
||||
}
|
||||
this->unk28 = (1.0f- sp24)*arg2;
|
||||
this->actor_specific_1_f = (1.0f- sp24)*arg2;
|
||||
func_80329054(this, 2);
|
||||
if(ml_distance_vec3f(this->position, arg1) <= arg4)
|
||||
return TRUE;
|
||||
|
|
|
@ -106,12 +106,12 @@ void func_8038AF10(Actor *this){
|
|||
animctrl_setSmoothTransition(this->animctrl, TRUE);
|
||||
subaddie_set_state_with_direction(this, 3, 0.00001f, 1);
|
||||
actor_loopAnimation(this);
|
||||
this->unk28 = 16.0f;
|
||||
this->actor_specific_1_f = 16.0f;
|
||||
this->unk1C[0] = 1.0f;
|
||||
}
|
||||
|
||||
int func_8038AF78(Actor *this, f32 arg1, f32 arg2){
|
||||
this->unk28 = arg2;
|
||||
this->actor_specific_1_f = arg2;
|
||||
this->yaw_ideal = (f32)func_80329784(this);
|
||||
func_80328FB0(this, arg1);
|
||||
if(!func_80329030(this, 0) && func_80329480(this))
|
||||
|
@ -192,7 +192,7 @@ void func_8038B124(Actor *this){
|
|||
subaddie_set_state_with_direction(this, 2, 0.00001f, 1);
|
||||
actor_playAnimationOnce(this);
|
||||
this->yaw = (f32)func_80329784(this);
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
this->unk1C[0] = 1.0f;
|
||||
func_802BB3DC(0, 14.0f, 0.92f);
|
||||
func_8038ABD8(this->position, 8);
|
||||
|
@ -200,7 +200,7 @@ void func_8038B124(Actor *this){
|
|||
else{//L8038B3E0
|
||||
this->yaw_ideal = func_80257204(this->position_x, this->position_z, this->velocity_x, this->velocity_z);
|
||||
func_80328FB0(this, 18.0f);
|
||||
this->unk28 = 18.0f;
|
||||
this->actor_specific_1_f = 18.0f;
|
||||
func_80329030(this, 0);
|
||||
animctrl_setAnimTimer(this->animctrl, 0.0f);
|
||||
|
||||
|
@ -233,7 +233,7 @@ void func_8038B124(Actor *this){
|
|||
func_8038ABD8(this->position, 8);
|
||||
}
|
||||
else{
|
||||
GV_D_80391A70[0] = 2*this->unk28;
|
||||
GV_D_80391A70[0] = 2 * this->actor_specific_1_f;
|
||||
GV_D_80391A70[1] = 0.0f;
|
||||
GV_D_80391A70[2] = 0.0f;
|
||||
ml_vec3f_yaw_rotate_copy(GV_D_80391A70, GV_D_80391A70, this->yaw - 90.0);
|
||||
|
|
|
@ -46,7 +46,7 @@ void chchimpystump_update(Actor *this) {
|
|||
if (!this->initialized) {
|
||||
actor_collisionOff(this);
|
||||
this->initialized = TRUE;
|
||||
this->unk28 = this->position_y;
|
||||
this->actor_specific_1_f = this->position_y;
|
||||
this->position_y -= 134.0f;
|
||||
this->marker->propPtr->unk8_3 = 1;
|
||||
}
|
||||
|
@ -64,8 +64,8 @@ void chchimpystump_update(Actor *this) {
|
|||
__chchimpystump_updateShaking(this);
|
||||
this->position_y += 2.5;
|
||||
|
||||
if (this->unk28 <= this->position_y) {
|
||||
this->position_y = this->unk28;
|
||||
if (this->actor_specific_1_f <= this->position_y) {
|
||||
this->position_y = this->actor_specific_1_f;
|
||||
subaddie_set_state(this, CHIMPY_STUMP_STATE_3_RAISED);
|
||||
func_802BB41C(1);
|
||||
func_80244C78(0);
|
||||
|
|
|
@ -72,7 +72,7 @@ bool __chConga_isPlayerNearCongaTree(Actor * this){
|
|||
|
||||
unused_tmpz = plyr_pos[2] - 5029.0f;
|
||||
|
||||
if (52900.0f < (plyr_pos[0] - - 5011.0f)*(plyr_pos[0] - - 5011.0f) + (plyr_pos[2]- 5029.0f)*(plyr_pos[2] - 5029.0f)) {
|
||||
if (52900.0f < (plyr_pos[0] - -5011.0f) * (plyr_pos[0] - -5011.0f) + (plyr_pos[2] - 5029.0f) * (plyr_pos[2] - 5029.0f)) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
|
@ -181,7 +181,7 @@ void __chConga_sendOrangeProjectile(ActorMarker *congaMarker){
|
|||
|
||||
congaPtr->unk10_12 -= (congaPtr->unk10_12 && ( conga_state == 7));
|
||||
MM_func_80387F44();
|
||||
congaPtr->unk28 = 2.0f;
|
||||
congaPtr->actor_specific_1_f = 2.0f;
|
||||
orangePtr = func_8032811C(ACTOR_14_ORANGE_PROJECTILE, conga_localPtr->orangeSpawnPosition, congaPtr->yaw);
|
||||
|
||||
if(orangePtr != NULL){
|
||||
|
@ -220,13 +220,13 @@ void func_803876D0(Actor *this){
|
|||
this->unk16C_0 = 1;
|
||||
this->initialized = TRUE;
|
||||
this->velocity_x = 0.0f;
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
node_prop = func_80304C38(0x150, this);
|
||||
((ActorLocal_Conga *)&this->local)->unk1C = nodeprop_getRadius(node_prop);
|
||||
nodeprop_getPosition_s32(node_prop, &((ActorLocal_Conga *)&this->local)->unk10);
|
||||
}
|
||||
if(0.0f == this->unk28){
|
||||
this->unk28 = (actorArray_findActorFromMarkerId(MARKER_36_ORANGE_COLLECTIBLE) != NULL)? 2.0f: 1.0f;
|
||||
if(0.0f == this->actor_specific_1_f){
|
||||
this->actor_specific_1_f = (actorArray_findActorFromMarkerId(MARKER_36_ORANGE_COLLECTIBLE) != NULL)? 2.0f: 1.0f;
|
||||
}
|
||||
if(0.0f != this->velocity_x){
|
||||
this->velocity_x -= 1.0f;
|
||||
|
|
|
@ -66,7 +66,7 @@ void MM_func_80387FF4(Actor * this){
|
|||
this->unk1C_y = ground_position_y;
|
||||
func_8030E6D4(SFX_2F_ORANGE_SPLAT);
|
||||
|
||||
this->unk28 = 1.0f;
|
||||
this->actor_specific_1_f = 1.0f;
|
||||
this->lifetime_value = 340.0f;
|
||||
this->state = 2;
|
||||
}
|
||||
|
@ -95,10 +95,10 @@ Actor *func_80388188(ActorMarker *this, Gfx **dl, Mtx **mptr, Vtx **vtx){
|
|||
position[2] = actorPtr->position_z;
|
||||
modelRender_setAlpha( (s32) MIN(255.0f, actorPtr->lifetime_value) );
|
||||
modelRender_setDepthMode(MODEL_RENDER_DEPTH_FULL);
|
||||
modelRender_draw(dl, mptr, position, rotation, actorPtr->unk28, sp60, func_8030A428(0x18));
|
||||
modelRender_draw(dl, mptr, position, rotation, actorPtr->actor_specific_1_f, sp60, func_8030A428(0x18));
|
||||
actorPtr->position_y -= 1.9;
|
||||
if(actorPtr->unk28 < 2.428){
|
||||
actorPtr->unk28 += 0.1;
|
||||
if(actorPtr->actor_specific_1_f < 2.428){
|
||||
actorPtr->actor_specific_1_f += 0.1;
|
||||
}
|
||||
}
|
||||
return actorPtr;
|
||||
|
|
|
@ -371,7 +371,7 @@ void func_80388080(Actor *this){
|
|||
}
|
||||
}else{//L80388520
|
||||
if(local->unkC == 1){
|
||||
this->unk28 = 3.0f;
|
||||
this->actor_specific_1_f = 3.0f;
|
||||
if(mapSpecificFlags_get(0xC) || volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE)){//L80388554
|
||||
if(!func_80329030(this, 0) && func_80329480(this)){
|
||||
func_80328CEC(this, (s32)this->yaw, 0x78, 0xb4);
|
||||
|
@ -391,7 +391,7 @@ void func_80388080(Actor *this){
|
|||
}
|
||||
}
|
||||
else if(local->unkC == 2){//L80388634
|
||||
this->unk28 = 4.0f;
|
||||
this->actor_specific_1_f = 4.0f;
|
||||
if(!func_80329030(this, 0) && func_80329480(this)){
|
||||
func_80328CEC(this, (s32)this->yaw, 0x78, 0xB4);
|
||||
this->unk38_0 = 1;
|
||||
|
@ -426,9 +426,9 @@ void func_80388080(Actor *this){
|
|||
if(ml_distance_vec3f(this->position, this->unk1C) < 20.0f){
|
||||
func_80387E64(this);
|
||||
}
|
||||
this->unk28 = 5.0f;
|
||||
this->actor_specific_1_f = 5.0f;
|
||||
if(mapSpecificFlags_get(0xC) || (volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE))){ //L8038892C
|
||||
if(!func_80387FA8(this, local, (s32)this->yaw, (s32)this->unk28)){
|
||||
if(!func_80387FA8(this, local, (s32)this->yaw, (s32)this->actor_specific_1_f)){
|
||||
if(func_80329480(this)){
|
||||
func_80328CEC(this, (s32)this->yaw, 0x78, 0xb4);
|
||||
this->unk38_0 = 1;
|
||||
|
@ -441,7 +441,7 @@ void func_80388080(Actor *this){
|
|||
this->unk1C_x -= local->unk0_x;
|
||||
this->unk1C_y -= local->unk0_y;
|
||||
this->unk1C_z -= local->unk0_z;
|
||||
TUPLE_ASSIGN(sp60, this->unk28, 0.0f, 0.0f);
|
||||
TUPLE_ASSIGN(sp60, this->actor_specific_1_f, 0.0f, 0.0f);
|
||||
ml_vec3f_yaw_rotate_copy(sp60, sp60, this->yaw - 90.0);
|
||||
local->unk0_x = sp60[0] + local->unk0_x;
|
||||
local->unk0_y = sp60[1] + local->unk0_y;
|
||||
|
|
|
@ -414,10 +414,10 @@ void chsmmole_Update(Actor * this){
|
|||
this->unk1C_x = this->position_x;
|
||||
this->unk1C_y = this->position_y;
|
||||
this->unk1C_z = this->position_z;
|
||||
this->unk28 = 300.0f;
|
||||
this->actor_specific_1_f = 300.0f;
|
||||
} else{ //L80389A68
|
||||
nodeprop_getPosition(sp40, this->unk1C);
|
||||
this->unk28 = nodeprop_getRadius(sp40);
|
||||
this->actor_specific_1_f = nodeprop_getRadius(sp40);
|
||||
}//L80389A8C
|
||||
if(this->unkF4_8 == 1){
|
||||
if(volatileFlag_get(VOLATILE_FLAG_1) || volatileFlag_get(VOLATILE_FLAG_1F_IN_CHARACTER_PARADE)){
|
||||
|
@ -458,7 +458,7 @@ void chsmmole_Update(Actor * this){
|
|||
|| (this->unkF4_8 == 8 && mapSpecificFlags_get(3) && !mapSpecificFlags_get(0xF))
|
||||
){//L80389C50
|
||||
|
||||
if( ((ml_distance_vec3f(sp44, this->unk1C) < this->unk28) && func_8028F20C())
|
||||
if( ((ml_distance_vec3f(sp44, this->unk1C) < this->actor_specific_1_f) && func_8028F20C())
|
||||
|| mapSpecificFlags_get(0x10)
|
||||
){//L80389C8C
|
||||
if(func_80329530(this, 0x96))
|
||||
|
|
|
@ -79,7 +79,7 @@ void func_803875D4(ActorMarker *marker){
|
|||
|
||||
subaddie_set_state(this, 4);
|
||||
actor_loopAnimation(this);
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
|
||||
if(!mapSpecificFlags_get(2)) {
|
||||
text_id = jiggyscore_isCollected(JIGGY_14_TTC_BLUBBER) ? 0xa2a : 0xa0d;
|
||||
|
@ -187,7 +187,7 @@ void func_803878CC(Actor * this){
|
|||
if( actor_animationIsAt(this, 0.99f)
|
||||
&& subaddie_maybe_set_state_position_direction(this, 1, 0.0f, 1, 0.78f)
|
||||
){
|
||||
this->unk28 = 4.0f;
|
||||
this->actor_specific_1_f = 4.0f;
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -215,7 +215,7 @@ void func_803878CC(Actor * this){
|
|||
local = (ActorLocal_Blubber*)&this->local;
|
||||
if(actor_animationIsAt(this, 0.99f) && !local->unk24){
|
||||
subaddie_set_state(this, 5);
|
||||
this->unk28 = 8.0f;
|
||||
this->actor_specific_1_f = 8.0f;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -83,10 +83,10 @@ bool __chClam_updateTarget(Actor *this, f32 arg1) {
|
|||
return FALSE;
|
||||
}
|
||||
|
||||
this->unk28 = phi_f2 / arg1;
|
||||
this->actor_specific_1_f = phi_f2 / arg1;
|
||||
this->yaw_ideal = func_80257204(this->position[0], this->position[2], target_position[0], target_position[2]);
|
||||
if ((volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0 : 0x11) < this->unk28) {
|
||||
this->unk28 = (volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) != 0) ? 0.0f : 17.0f;
|
||||
if ((volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0 : 0x11) < this->actor_specific_1_f) {
|
||||
this->actor_specific_1_f = (volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) != 0) ? 0.0f : 17.0f;
|
||||
} else if (sp38 == 0) {
|
||||
__chClam_func_803863F0(SFX_AE_YUMYUM_TALKING, randf2(0.9f, 1.0f), 22000, this->position, 500.0f, 2000.0f);
|
||||
}
|
||||
|
@ -108,13 +108,13 @@ bool __chClam_rotateTowardTarget(Actor *this, s32 arg1) {
|
|||
if (((f64) animctrl_getAnimTimer(this->animctrl) < 0.1) && ((f64) randf() < 0.5)) {
|
||||
if (this->unk1C[0] != 0.0f) {
|
||||
arg1 *= 2;
|
||||
this->unk28 = (f32) randi2(0, 0.5*(volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0 : 0x11));
|
||||
this->actor_specific_1_f = (f32) randi2(0, 0.5*(volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0 : 0x11));
|
||||
this->yaw_ideal += (f32) randi2(-arg1, arg1);
|
||||
} else if ((f64) randf() < 0.4) {
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
this->yaw_ideal += (f32) randi2(-arg1, arg1);
|
||||
} else {
|
||||
this->unk28 = (f32) randi2(0.33 * (volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0 : 0x11), volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0 : 0x11);
|
||||
this->actor_specific_1_f = (f32) randi2(0.33 * (volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0 : 0x11), volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0 : 0x11);
|
||||
this->yaw_ideal = this->yaw;
|
||||
}
|
||||
this->unk1C[0] = 0.0f;
|
||||
|
@ -124,13 +124,13 @@ bool __chClam_rotateTowardTarget(Actor *this, s32 arg1) {
|
|||
return FALSE;
|
||||
}
|
||||
}
|
||||
temp_f0_2 = this->unk28 * sp2C;
|
||||
temp_f0_2 = this->actor_specific_1_f * sp2C;
|
||||
this->velocity[1] = ((f32)(0.3*temp_f0_2) / sp2C) - (f32) ((s32) (sp2C * -5) / 2);
|
||||
if (func_80329078(this, this->yaw_ideal, temp_f0_2)) {
|
||||
return TRUE;
|
||||
}
|
||||
this->unk1C[0] = 1.0f;
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
this->yaw_ideal = this->yaw;
|
||||
return FALSE;
|
||||
}
|
||||
|
|
|
@ -52,7 +52,7 @@ Actor *chBadShad_draw(ActorMarker *marker, Gfx **gfx, Mtx **mtx, Vtx **vtx){
|
|||
|
||||
if(other)
|
||||
modelRender_setAlpha(other->alpha_124_19);
|
||||
sp40 = ml_map_f(this->unk28, 0.0f , 800.0f, 0.53f, 0.18f)*this->unk1C[1];
|
||||
sp40 = ml_map_f(this->actor_specific_1_f, 0.0f , 800.0f, 0.53f, 0.18f)*this->unk1C[1];
|
||||
modelRender_setDepthMode(MODEL_RENDER_DEPTH_COMPARE);
|
||||
modelRender_draw(gfx, mtx, this->position, sp44, sp40, NULL, marker_loadModelBin(marker));
|
||||
return this;
|
||||
|
@ -120,7 +120,7 @@ void func_802D71A0(s32 this, s32 arg1){
|
|||
sp3C->unk104 = marker;
|
||||
sp3C->unk1C[0] = globalTimer_getTime();
|
||||
sp3C->unk1C[1] = sp40;
|
||||
sp3C->unk28 = sp28;
|
||||
sp3C->actor_specific_1_f = sp28;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -148,7 +148,7 @@ void func_802D729C(Actor *actor, f32 arg1){
|
|||
return;
|
||||
|
||||
if(!((globalTimer_getTime() ^ actor->marker->actrArrayIdx) & 0x7)){
|
||||
sp1C->unk28 = func_802D7038(actor);
|
||||
sp1C->actor_specific_1_f = func_802D7038(actor);
|
||||
sp1C->position_x = D_8037DE10[0];
|
||||
sp1C->position_y = D_8037DE10[1] + 6.0f;
|
||||
sp1C->position_z = D_8037DE10[2];
|
||||
|
|
|
@ -40,7 +40,7 @@ ActorInfo D_803660B4 = {0x9, ACTOR_E_BULL_INTRO, ASSET_354_MODEL_BULL_INTRO,
|
|||
|
||||
/* .code */
|
||||
void func_802C5E80(Actor *this){
|
||||
this->unk28 = randf2(3.5f, 4.9f);
|
||||
this->actor_specific_1_f = randf2(3.5f, 4.9f);
|
||||
}
|
||||
|
||||
void func_802C5EB8(Actor *this){
|
||||
|
@ -83,7 +83,7 @@ void func_802C5FF8(Actor *this){
|
|||
void func_802C60AC(ActorMarker *marker, ActorMarker *other_marker){
|
||||
Actor *actor = marker_getActor(marker);
|
||||
if( actor->state == 4
|
||||
&& 5.0 <= actor->unk28
|
||||
&& 5.0 <= actor->actor_specific_1_f
|
||||
&& func_803294F0(actor, 80, func_80329784(actor))
|
||||
){
|
||||
animctrl_setPlaybackType(actor->animctrl, ANIMCTRL_ONCE);
|
||||
|
@ -171,7 +171,7 @@ void func_802C6240(Actor *this){
|
|||
&& func_80329078(this, (s32)this->yaw_ideal, 150)
|
||||
&& subaddie_maybe_set_state(this, 3, 0.13f)
|
||||
){
|
||||
this->unk28 = randf2(7.1f, 8.4f);
|
||||
this->actor_specific_1_f = randf2(7.1f, 8.4f);
|
||||
}
|
||||
func_802C5EB8(this);
|
||||
break;
|
||||
|
@ -212,7 +212,7 @@ void func_802C6240(Actor *this){
|
|||
|
||||
if(this->unk10_12 == 0 || (this->unk10_12 < 3 && func_80329530(this, 300))){
|
||||
subaddie_set_state(this, 9);
|
||||
this->unk28 = 13.0f;
|
||||
this->actor_specific_1_f = 13.0f;
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -220,9 +220,10 @@ void func_802C6240(Actor *this){
|
|||
if(actor_animationIsAt(this, 0.35f))
|
||||
func_8030E58C(SFX_2E_BIGBUTT_RUNNING, 1.0f);
|
||||
|
||||
this->unk28 += 0.15;
|
||||
if(30.0f < this->unk28)
|
||||
this->unk28 = 30.0f;
|
||||
this->actor_specific_1_f += 0.15;
|
||||
if (30.0f < this->actor_specific_1_f) {
|
||||
this->actor_specific_1_f = 30.0f;
|
||||
}
|
||||
|
||||
this->yaw_ideal = (f32)func_80329784(this);
|
||||
func_80328FB0(this, 9.0f);
|
||||
|
@ -233,7 +234,7 @@ void func_802C6240(Actor *this){
|
|||
if(func_80329078(this, (s32)this->yaw_ideal,200)){
|
||||
animctrl_setPlaybackType(this->animctrl, ANIMCTRL_ONCE);
|
||||
subaddie_set_state(this, 4);
|
||||
this->unk28 += 5.7;
|
||||
this->actor_specific_1_f += 5.7;
|
||||
tmp_a0 = this->unk44_31;
|
||||
if(this->unk44_31 == 0){
|
||||
this->unk44_31 = func_8030D90C();
|
||||
|
@ -259,7 +260,7 @@ void func_802C6240(Actor *this){
|
|||
func_8030E2C4(this->unk44_31);
|
||||
if(0.99 <= animctrl_getAnimTimer(this->animctrl)){
|
||||
func_80329878(this, func_80329530(this, 250)? 0.8: 1.2);
|
||||
if(0.0f == this->unk28){
|
||||
if (0.0f == this->actor_specific_1_f) {
|
||||
animctrl_setPlaybackType(this->animctrl, ANIMCTRL_LOOP);
|
||||
subaddie_set_state_with_direction(this, 1, 0.65f, 1);
|
||||
func_8030DA44(this->unk44_31);
|
||||
|
|
|
@ -38,7 +38,7 @@ void chCollectible_setState(Actor *arg0, s32 next_state){
|
|||
default:
|
||||
break;
|
||||
case 1:
|
||||
arg0->unk28 = 0.0f;
|
||||
arg0->actor_specific_1_f = 0.0f;
|
||||
//fall-through
|
||||
case 3:
|
||||
actor_collisionOff(arg0);
|
||||
|
@ -122,13 +122,13 @@ void chCollectible_collectGoldFeather(ActorProp *arg0){
|
|||
Actor *chCollectible_draw(ActorMarker *this, Gfx **gdl, Mtx **mptr, Vtx **arg3){
|
||||
Actor *thisActor = marker_getActor(this);
|
||||
|
||||
if(thisActor->unk28 != 0.0f){
|
||||
if (thisActor->actor_specific_1_f != 0.0f) {
|
||||
if(thisActor->unk38_0){
|
||||
func_80344C2C(1);
|
||||
if(thisActor->unk28 == 255.0f){
|
||||
if (thisActor->actor_specific_1_f == 255.0f) {
|
||||
func_803262B8(thisActor);
|
||||
} else{
|
||||
actor_setOpacity(thisActor, thisActor->unk28);
|
||||
actor_setOpacity(thisActor, thisActor->actor_specific_1_f);
|
||||
}
|
||||
}
|
||||
return func_80325934(this, gdl, mptr, arg3);
|
||||
|
@ -148,7 +148,7 @@ void chCollectible_update(Actor *this) {
|
|||
}
|
||||
this->unk10_12 = -1;
|
||||
this->unk38_0 = (map_get() == MAP_90_GL_BATTLEMENTS);
|
||||
this->unk28 = this->unk38_0 ? 0.0f: 255.0f;
|
||||
this->actor_specific_1_f = this->unk38_0 ? 0.0f : 255.0f;
|
||||
this->initialized = TRUE;
|
||||
}
|
||||
if(!this->unk38_0)
|
||||
|
@ -167,13 +167,13 @@ void chCollectible_update(Actor *this) {
|
|||
}
|
||||
/* fallthrough */
|
||||
case 3:
|
||||
if (this->unk28 > 0) {
|
||||
this->unk28 = MAX(this->unk28 - 8, 0);
|
||||
if (this->actor_specific_1_f > 0) {
|
||||
this->actor_specific_1_f = MAX(this->actor_specific_1_f - 8, 0);
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
if (this->unk28 < 255) {
|
||||
this->unk28 = MIN(this->unk28 + 8, 255);
|
||||
if (this->actor_specific_1_f < 255) {
|
||||
this->actor_specific_1_f = MIN(this->actor_specific_1_f + 8, 255);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@ ActorAnimationInfo chCrabMutantAnimations[] = {
|
|||
|
||||
/* .code */
|
||||
void __chCrab_802CB040(Actor *this) {
|
||||
this->unk28 = randf2(1.5f, 2.3f);
|
||||
this->actor_specific_1_f = randf2(1.5f, 2.3f);
|
||||
}
|
||||
|
||||
void __chCrab_802CB078(Actor *this) {
|
||||
|
@ -49,7 +49,7 @@ void __chCrab_802CB078(Actor *this) {
|
|||
if( func_80329530(this, 1500)
|
||||
&& ( (this->modelCacheIndex == ACTOR_F2_BLACK_SNIPPET) || func_803292E0(this))
|
||||
) {
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
subaddie_set_state(this, 3U);
|
||||
}
|
||||
}
|
||||
|
@ -327,7 +327,7 @@ void chCrab_update(Actor *this) {
|
|||
func_80328FB0(this, 4.0f);
|
||||
if (func_80329480(this)) {
|
||||
subaddie_set_state(this, 4);
|
||||
this->unk28 = 12.0f;
|
||||
this->actor_specific_1_f = 12.0f;
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -336,7 +336,7 @@ void chCrab_update(Actor *this) {
|
|||
func_80328FB0(this, 4.0f);
|
||||
if (func_80329480(this)) {
|
||||
subaddie_set_state(this, 9);
|
||||
this->unk28 = 12.0f;
|
||||
this->actor_specific_1_f = 12.0f;
|
||||
} else if (!levelSpecificFlags_get(0xE)) {
|
||||
subaddie_set_state_with_direction(this, 3, 0.0f, 1);
|
||||
}
|
||||
|
|
|
@ -169,14 +169,14 @@ void func_8035B674(Actor *this){
|
|||
void func_8035B6CC(Actor *this){
|
||||
subaddie_set_state_with_direction(this, 2, 0.01f, 1);
|
||||
actor_playAnimationOnce(this);
|
||||
this->unk28 = 1.0f;
|
||||
this->actor_specific_1_f = 1.0f;
|
||||
func_8030E878(0x3F4, randf2(1.0f, 1.2f), 32000, this->position, this->scale*400.0f, this->scale*1800.0f);
|
||||
}
|
||||
|
||||
void func_8035B75C(Actor *this){
|
||||
subaddie_set_state_with_direction(this, 3, 0.01f, 1);
|
||||
actor_loopAnimation(this);
|
||||
this->unk28 = volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0.0 : 12.0;
|
||||
this->actor_specific_1_f = volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE) ? 0.0 : 12.0;
|
||||
func_8030E878(0x3F4, randf2(1.0f, 1.2f), 32000, this->position, this->scale*400.0f, this->scale*1800.0f);
|
||||
}
|
||||
|
||||
|
@ -186,10 +186,8 @@ void func_8035B824(Actor *this){
|
|||
subaddie_set_state_with_direction(this, 4, 0.01f, 1);
|
||||
actor_loopAnimation(this);
|
||||
func_80328CEC(this, (s32)this->yaw_ideal, 0xA, 0x1E);
|
||||
this->unk28 = 4.0f;
|
||||
this->actor_specific_1_f = 4.0f;
|
||||
local->unk4 = randf2(2.0f, 4.5f);
|
||||
|
||||
|
||||
}
|
||||
|
||||
void func_8035B8A8(Actor *this){
|
||||
|
|
|
@ -99,14 +99,14 @@ void func_8035EE48(Actor *this){
|
|||
void func_8035EE80(Actor *this){
|
||||
subaddie_set_state(this, 3);
|
||||
actor_loopAnimation(this);
|
||||
this->unk28 = 10.5f;
|
||||
this->actor_specific_1_f = 10.5f;
|
||||
func_8035EE48(this);
|
||||
}
|
||||
|
||||
void func_8035EEC0(Actor *this){
|
||||
subaddie_set_state(this, 4);
|
||||
actor_loopAnimation(this);
|
||||
this->unk28 = 9.0f;
|
||||
this->actor_specific_1_f = 9.0f;
|
||||
func_8035EE48(this);
|
||||
}
|
||||
|
||||
|
@ -192,7 +192,7 @@ void func_8035F138(Actor *this) {
|
|||
marker_setCollisionScripts(this->marker, func_8035F0E8, func_8035F048, func_8035EF9C);
|
||||
local->unk0 = 1;
|
||||
this->unk1C[0] = this->position[0];
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
this->velocity[1] = 0.0f;
|
||||
this->unk1C[2] = this->position[2];
|
||||
this->velocity[0] = this->yaw;
|
||||
|
@ -237,8 +237,8 @@ void func_8035F138(Actor *this) {
|
|||
break;
|
||||
}
|
||||
|
||||
if (((this->unk28 + 0.28) <= 18.0) && ( 0.36 <= animctrl_getDuration(this->animctrl) - 0.0056000000000000008)) {
|
||||
this->unk28 += 0.28;
|
||||
if (((this->actor_specific_1_f + 0.28) <= 18.0) && ( 0.36 <= animctrl_getDuration(this->animctrl) - 0.0056000000000000008)) {
|
||||
this->actor_specific_1_f += 0.28;
|
||||
animctrl_setDuration(this->animctrl, animctrl_getDuration(this->animctrl) - 0.0056000000000000008);
|
||||
}
|
||||
break;
|
||||
|
@ -253,7 +253,7 @@ void func_8035F138(Actor *this) {
|
|||
if (func_8035ED60(this)) {
|
||||
subaddie_set_state_with_direction(this, 5, 0.99f, 0);
|
||||
actor_playAnimationOnce(this);
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
this->unk1C[1] = 1.9f;
|
||||
this->unk44_31 = func_8030ED2C(SFX_2C_PULLING_NOISE, 3);
|
||||
break;
|
||||
|
@ -277,7 +277,7 @@ void func_8035F138(Actor *this) {
|
|||
if (animctrl_getAnimTimer(this->animctrl) <= 0.02) {
|
||||
subaddie_set_state_with_direction(this, 1, 0.02f, 1);
|
||||
actor_playAnimationOnce(this);
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
func_8035EE48(this);
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -176,7 +176,7 @@ void func_8035A694(Actor *this){
|
|||
f32 sp28[3];
|
||||
|
||||
sp3C = this->yaw;
|
||||
sp38 = this->unk28*1.5 + 1.0;
|
||||
sp38 = this->actor_specific_1_f * 1.5 + 1.0;
|
||||
tmp_v0 = globalTimer_getTime();
|
||||
this->yaw += sp38;
|
||||
if(360.0f < this->yaw)
|
||||
|
@ -215,7 +215,7 @@ void __chicecube_ow(ActorMarker *marker, ActorMarker *other_marker){
|
|||
Actor *actor = marker_getActor(marker);
|
||||
FUNC_8030E8B4(SFX_1D_HITTING_AN_ENEMY_1, 0.9f, 22000, actor->position, 1500, 3000);
|
||||
actor->velocity[1] = 0.8f;
|
||||
actor->unk28 = 0.0f;
|
||||
actor->actor_specific_1_f = 0.0f;
|
||||
}
|
||||
|
||||
//__chicecube_die
|
||||
|
@ -241,7 +241,7 @@ void func_8035A9E0(Actor *this){
|
|||
subaddie_set_state_with_direction(this, 3, animctrl_getAnimTimer(this->animctrl), 1);
|
||||
actor_loopAnimation(this);
|
||||
this->unk38_31 = 1;
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
}
|
||||
|
||||
void func_8035AA40(Actor *this){
|
||||
|
@ -322,11 +322,11 @@ void chicecube_update(Actor *this){
|
|||
break;
|
||||
case 3: // L8035AD88
|
||||
animctrl_setAnimTimer(this->animctrl, 0.999f);
|
||||
if(this->unk28 + 0.28 < 18.0){
|
||||
this->unk28 = this->unk28 + 0.28;
|
||||
if (this->actor_specific_1_f + 0.28 < 18.0) {
|
||||
this->actor_specific_1_f = this->actor_specific_1_f + 0.28;
|
||||
}
|
||||
else{
|
||||
this->unk28 = 18.0f;
|
||||
else {
|
||||
this->actor_specific_1_f = 18.0f;
|
||||
}
|
||||
func_8035A694(this);
|
||||
if(!func_80359DF4(this, 1300)){
|
||||
|
@ -343,10 +343,14 @@ void chicecube_update(Actor *this){
|
|||
break;
|
||||
case 4: // L8035AE64
|
||||
animctrl_setAnimTimer(this->animctrl, 0.999f);
|
||||
if(this->unk28 - 0.28 > 8.0)
|
||||
this->unk28 = this->unk28 - 0.28;
|
||||
else
|
||||
this->unk28 = 8.0f;
|
||||
|
||||
if (this->actor_specific_1_f - 0.28 > 8.0) {
|
||||
this->actor_specific_1_f = this->actor_specific_1_f - 0.28;
|
||||
}
|
||||
else {
|
||||
this->actor_specific_1_f = 8.0f;
|
||||
}
|
||||
|
||||
func_8035A694(this);
|
||||
if(func_80359DF4(this, 900)){
|
||||
func_8035A9E0(this);
|
||||
|
|
|
@ -368,11 +368,11 @@ void chmole_update(Actor *this){
|
|||
this->velocity[0] = this->position[0];
|
||||
this->velocity[1] = this->position[1];
|
||||
this->velocity[2] = this->position[2];
|
||||
this->unk28 = 500.0f;
|
||||
this->actor_specific_1_f = 500.0f;
|
||||
}
|
||||
else{ //L802D9F08
|
||||
nodeprop_getPosition(node_prop, this->velocity);
|
||||
this->unk28 = 2*nodeprop_getRadius(node_prop);
|
||||
this->actor_specific_1_f = 2 * nodeprop_getRadius(node_prop);
|
||||
}
|
||||
}
|
||||
}//L802D9F34
|
||||
|
@ -387,7 +387,7 @@ void chmole_update(Actor *this){
|
|||
&& (func_8028ECAC() == 0 || func_8028ECAC() == BSGROUP_8_TROT)
|
||||
){
|
||||
player_getPosition(sp34);
|
||||
if(ml_distance_vec3f(sp34, this->velocity) < this->unk28){
|
||||
if (ml_distance_vec3f(sp34, this->velocity) < this->actor_specific_1_f) {
|
||||
chmole_startingDialog(this);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -26,7 +26,7 @@ ActorAnimationInfo chShrapnelAnimations[] = {
|
|||
|
||||
/* .code */
|
||||
void chShrapnel_func_802D0A00(Actor *this) {
|
||||
this->unk28 = randf2(1.5f, 2.3f);
|
||||
this->actor_specific_1_f = randf2(1.5f, 2.3f);
|
||||
}
|
||||
|
||||
void chShrapnel_func_802D0A38(Actor *this){
|
||||
|
@ -35,7 +35,7 @@ void chShrapnel_func_802D0A38(Actor *this){
|
|||
}
|
||||
else{
|
||||
if(func_80329530(this, 600) && func_803292E0(this)){
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
subaddie_set_state_with_direction(this, 2, 0.0f, 1);
|
||||
}
|
||||
}
|
||||
|
@ -123,7 +123,7 @@ void chShrapnel_explode(ActorMarker *marker, ActorMarker *other_marker) {
|
|||
|
||||
void chShrapnel_func_802D0FC8(Actor *this) {
|
||||
this->unk4C += time_getDelta();
|
||||
if (MAX(0.25, (12.0 - this->unk28) / 12.0) < this->unk4C) {
|
||||
if (MAX(0.25, (12.0 - this->actor_specific_1_f) / 12.0) < this->unk4C) {
|
||||
*(s32 *)(&this->local) = NOT(*(s32 *)(&this->local));
|
||||
this->unk4C = 0.0f;
|
||||
if (*(s32 *)(&this->local)) {
|
||||
|
@ -170,15 +170,15 @@ void chshrapnel_update(Actor *this) {
|
|||
subaddie_set_state(this, 3);
|
||||
actor_loopAnimation(this);
|
||||
FUNC_8030E8B4(SFX_C4_TWINKLY_MUNCHER_GRR, 0.6f, 32750, this->position, 1250, 2500);
|
||||
this->unk28 = 4.0f;
|
||||
this->actor_specific_1_f = 4.0f;
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case 3:
|
||||
this->yaw_ideal = (f32) func_80329784(this);
|
||||
func_80328FB0(this, this->unk28 / 2);
|
||||
this->unk28 = MIN( 50.0, (this->unk28 + tick));
|
||||
func_80328FB0(this, this->actor_specific_1_f / 2);
|
||||
this->actor_specific_1_f = MIN(50.0, (this->actor_specific_1_f + tick));
|
||||
if ((250.0 <= ABS(player_position[1] - this->unk1C[1])) || !func_80329054(this, 0)) {
|
||||
chShrapnel_func_802D0AB8(this);
|
||||
}
|
||||
|
|
|
@ -65,7 +65,7 @@ s32 D_8037E630;
|
|||
|
||||
/* .code */
|
||||
void func_802E0CD0(Actor *this){
|
||||
this->unk28 = 4.0f;
|
||||
this->actor_specific_1_f = 4.0f;
|
||||
}
|
||||
|
||||
static void __chsnacker_start_dialog(Actor *this) {
|
||||
|
@ -76,7 +76,7 @@ static void __chsnacker_start_dialog(Actor *this) {
|
|||
this->unk38_31--;
|
||||
}
|
||||
else{
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
if (level_get() == LEVEL_2_TREASURE_TROVE_COVE) {
|
||||
text_index = mapSpecificFlags_getN(8, 3);
|
||||
if( !this->is_first_encounter ) {
|
||||
|
@ -103,7 +103,7 @@ bool func_802E0DC0(f32 snacker_position[3]){
|
|||
}
|
||||
|
||||
void func_802E0E88(Actor *this){
|
||||
this->unk28 = 2.0f;
|
||||
this->actor_specific_1_f = 2.0f;
|
||||
subaddie_set_state_with_direction(this, 5, 0.0f, -1);
|
||||
actor_playAnimationOnce(this);
|
||||
}
|
||||
|
@ -235,7 +235,7 @@ void chsnacker_update(Actor *this) {
|
|||
func_80328FF0(this, 3.0f);
|
||||
if (func_80329480(this)) {
|
||||
subaddie_set_state_with_direction(this, 4, 0.0f, 1);
|
||||
this->unk28 = 9.0f;
|
||||
this->actor_specific_1_f = 9.0f;
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -243,9 +243,9 @@ void chsnacker_update(Actor *this) {
|
|||
func_803297FC(this, &sp44, &sp40);
|
||||
this->yaw_ideal = sp40;
|
||||
this->unk6C = func_802E10F0(sp44);
|
||||
func_80328FB0(this, this->unk28 / 2);
|
||||
func_80328FF0(this, this->unk28 / 2);
|
||||
this->unk28 = MIN(50.0, this->unk28 + dt);
|
||||
func_80328FB0(this, this->actor_specific_1_f / 2);
|
||||
func_80328FF0(this, this->actor_specific_1_f / 2);
|
||||
this->actor_specific_1_f = MIN(50.0, this->actor_specific_1_f + dt);
|
||||
func_8032CA80(this, (s_chSnacker_inRbb) ? 15 : 9);
|
||||
break;
|
||||
|
||||
|
|
|
@ -25,12 +25,14 @@ void __chTermite_updateRandomSpeed(Actor *this) {
|
|||
}
|
||||
|
||||
void __chTermite_updateAnimationSpeed(Actor *this) {
|
||||
if ((this->velocity[0] - 0.1 <= this->unk28) && (this->unk28 <= this->velocity[0] + 0.1)) {
|
||||
this->unk28 = this->velocity[0];
|
||||
} else {
|
||||
this->unk28 += (this->velocity[0] < this->unk28)? -0.2 : 0.2;
|
||||
if ((this->velocity[0] - 0.1 <= this->actor_specific_1_f) && (this->actor_specific_1_f <= this->velocity[0] + 0.1)) {
|
||||
this->actor_specific_1_f = this->velocity[0];
|
||||
}
|
||||
animctrl_setDuration(this->animctrl, ml_map_f(this->unk28, 5.0f, 12.0f, 0.54f, 0.36f));
|
||||
else {
|
||||
this->actor_specific_1_f += (this->velocity[0] < this->actor_specific_1_f) ? -0.2 : 0.2;
|
||||
}
|
||||
|
||||
animctrl_setDuration(this->animctrl, ml_map_f(this->actor_specific_1_f, 5.0f, 12.0f, 0.54f, 0.36f));
|
||||
}
|
||||
|
||||
void __chTermite_updateRandomRotationSpeed(Actor *this) {
|
||||
|
@ -193,7 +195,7 @@ void chTermite_update(Actor *this) {
|
|||
if (subaddie_maybe_set_state_position_direction(this, 2, 0.0f, 1, 0.06f)) {
|
||||
__chTermite_updateRandomRotationSpeed(this);
|
||||
__chTermite_updateRandomSpeed(this);
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
return;
|
||||
}
|
||||
return;
|
||||
|
@ -216,7 +218,7 @@ void chTermite_update(Actor *this) {
|
|||
if (func_8034A6FC(0.73f, 0.76f) && func_80329078(this, (s32) this->yaw, 750) ) {
|
||||
this->yaw_ideal = this->yaw;
|
||||
this->velocity[0] = 35.0f;
|
||||
this->unk28 = 19.4444447f;
|
||||
this->actor_specific_1_f = 19.4444447f;
|
||||
this->unk38_31 = 0x3A;
|
||||
}
|
||||
if ((sp34 & 0x1F) == 3 && 0.58 < (f64) randf()) {
|
||||
|
|
|
@ -153,7 +153,7 @@ void func_802CEF54(Actor *this, f32 arg1[3], f32 arg2){
|
|||
|
||||
phi_v1 = (this->state == 5) ? 200 : 50;
|
||||
phi_v0 = (this->state == 5) ? 200 : 100;
|
||||
func_802CEDE4(sp34, this->unk1C, arg2, &this->unk28, (f32) phi_v1, (f32) phi_v0);
|
||||
func_802CEDE4(sp34, this->unk1C, arg2, &this->actor_specific_1_f, (f32) phi_v1, (f32) phi_v0);
|
||||
this->unk1C[0] = this->unk1C[0] + arg1[0];
|
||||
this->unk1C[1] = this->unk1C[1] + arg1[1];
|
||||
this->unk1C[2] = this->unk1C[2] + arg1[2];
|
||||
|
@ -418,7 +418,7 @@ void chBeeSwarm_update(Actor *this) {
|
|||
subaddie_set_state(this, 6);
|
||||
}
|
||||
}
|
||||
chBeeSwarm_802CF1C8(this->unk1C, this->position, this->velocity, this->unk28, 100.0f, 0, &spA0);
|
||||
chBeeSwarm_802CF1C8(this->unk1C, this->position, this->velocity, this->actor_specific_1_f, 100.0f, 0, &spA0);
|
||||
}
|
||||
if (map_get() == MAP_78_GL_RBB_AND_MMM_PUZZLE) {
|
||||
if (this->unk38_31++ == 0x1E) {
|
||||
|
@ -470,7 +470,7 @@ void chBeeSwarm_update(Actor *this) {
|
|||
this->unk1C[1] = spB4[1];
|
||||
this->unk1C[2] = spB4[2];
|
||||
this->unk1C[1] += 50.0f;
|
||||
this->unk28 = 400.0f;
|
||||
this->actor_specific_1_f = 400.0f;
|
||||
if (ml_distance_vec3f(this->position, this->unk1C) < 100.0f) {
|
||||
func_802CEF54(this, spB4, 50.0f);
|
||||
subaddie_set_state(this, 4);
|
||||
|
@ -547,7 +547,7 @@ void chBeeSwarm_update(Actor *this) {
|
|||
sfxsource_set_fade_distances(this->unk44_31, 500.0f, 1500.0f);
|
||||
sfxsource_set_position(this->unk44_31, this->position);
|
||||
func_8030E2C4(this->unk44_31);
|
||||
sfxsource_setSampleRate(this->unk44_31, (s32)(((gu_sqrtf(this->velocity[0]*this->velocity[0] + this->velocity[1]*this->velocity[1] + this->velocity[2]*this->velocity[2])/ this->unk28) * 8000.0f) + 2000.0f));
|
||||
sfxsource_setSampleRate(this->unk44_31, (s32)(((gu_sqrtf(this->velocity[0] * this->velocity[0] + this->velocity[1] * this->velocity[1] + this->velocity[2] * this->velocity[2]) / this->actor_specific_1_f) * 8000.0f) + 2000.0f));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -83,7 +83,7 @@ void func_802D8B20(enum actor_e actor_id){
|
|||
temp_v0 = (randf() > 0.5) ? 0x1E : -0x1E;
|
||||
feather = spawn_actor_f32(actor_id, plyr_pos, (s32) (temp2 + temp_v0));
|
||||
func_8032AA58(feather, 0.45f);
|
||||
feather->unk28 = 22.0f;
|
||||
feather->actor_specific_1_f = 22.0f;
|
||||
feather->unk1C[1] = 48.0f;
|
||||
feather->lifetime_value = 1.2f;
|
||||
}
|
||||
|
|
|
@ -84,7 +84,7 @@ void func_802DAE10(Actor *this){
|
|||
ActorLocal_core2_53C10 *local;
|
||||
|
||||
local = (ActorLocal_core2_53C10 *)&this->local;
|
||||
this->unk28 = randf2(local->unk0, local->unk4);
|
||||
this->actor_specific_1_f = randf2(local->unk0, local->unk4);
|
||||
}
|
||||
|
||||
void func_802DAE40(Actor *this) {
|
||||
|
@ -132,7 +132,7 @@ bool func_802DAFBC(Actor *this) {
|
|||
func_8032C9E0(sp38);
|
||||
sp34 = func_80257248(sp38, this->position);
|
||||
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->actor_specific_1_f);
|
||||
} else {
|
||||
func_80328CEC(this, (s32) sp34, 0, 0xF);
|
||||
}
|
||||
|
@ -208,7 +208,7 @@ void func_802DB440(ActorMarker *marker, ActorMarker *other_marker) {
|
|||
|
||||
this = marker_getActor(marker);
|
||||
if( this->state == 7
|
||||
&& this->unk28 >= 3.0
|
||||
&& this->actor_specific_1_f >= 3.0
|
||||
&& func_803294F0(this, 0x50, func_80329784(this))
|
||||
) {
|
||||
FUNC_8030E8B4(SFX_1F_HITTING_AN_ENEMY_3, 1.0f, 20000, this->position, 1250, 2500);
|
||||
|
@ -294,7 +294,7 @@ void func_802DB5A0(Actor *this) {
|
|||
&& func_80329078(this, (s32) this->yaw_ideal, 0x96)
|
||||
) {
|
||||
if (subaddie_maybe_set_state(this, 3, 0.13f) != 0) {
|
||||
this->unk28 = randf2((f32)local->unk8, (f32)local->unk9);
|
||||
this->actor_specific_1_f = randf2((f32)local->unk8, (f32)local->unk9);
|
||||
}
|
||||
}
|
||||
func_802DB220(this);
|
||||
|
@ -341,7 +341,7 @@ void func_802DB5A0(Actor *this) {
|
|||
|| (this->unk10_12 < local->unkC_31 && func_80329530(this, 0xFA))
|
||||
) {
|
||||
subaddie_set_state(this, 7);
|
||||
this->unk28 = (f32)local->unkA;
|
||||
this->actor_specific_1_f = (f32) local->unkA;
|
||||
this->unk38_31 = 0;
|
||||
}
|
||||
if(!func_80329078(this, (s32) this->yaw, 0x14)) {
|
||||
|
|
|
@ -83,8 +83,6 @@ void mapSavestate_save(enum map_e map)
|
|||
D_8037E650[map] = actors_appendToSavestate(D_8037E650[map], ((u32 *) D_8037E650[map]) + (4 * ((iBit + 0x7F) >> 7)));
|
||||
}
|
||||
|
||||
#define AS_BOOL(expr) ((expr)? TRUE : FALSE)
|
||||
|
||||
void mapSavestate_apply(enum map_e map_id) {
|
||||
s32 iBit = 0;
|
||||
u32* flag_ptr;
|
||||
|
|
|
@ -790,7 +790,7 @@ Actor *actor_new(s32 position[3], s32 yaw, ActorInfo* actorInfo, u32 flags){
|
|||
suLastBaddie->pitch = 0.0f;
|
||||
suLastBaddie->roll = 0.0f;
|
||||
suLastBaddie->unk6C = 0.0f;
|
||||
suLastBaddie->unk28 = 0.0f;
|
||||
suLastBaddie->actor_specific_1_f = 0.0f;
|
||||
suLastBaddie->unk10_12 = 0;
|
||||
suLastBaddie->unk38_0 = 0;
|
||||
suLastBaddie->unk38_31 = 0;
|
||||
|
@ -1604,9 +1604,10 @@ void func_803297FC(Actor *arg0, f32 *o1, f32 *o2){
|
|||
}
|
||||
|
||||
void func_80329878(Actor *arg0, f32 arg1){
|
||||
arg0->unk28 -= arg1;
|
||||
if(arg0->unk28 < 0.0f){
|
||||
arg0->unk28 = 0.0f;
|
||||
arg0->actor_specific_1_f -= arg1;
|
||||
|
||||
if (arg0->actor_specific_1_f < 0.0f) {
|
||||
arg0->actor_specific_1_f = 0.0f;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -214,7 +214,7 @@ bool func_8032C2F0(Actor *arg0, f32 arg1[3], s32 arg2, s32 arg3) {
|
|||
f32 sp60[3];
|
||||
f32 sp20[4][4];
|
||||
|
||||
sp6C[0] = arg0->unk28;
|
||||
sp6C[0] = arg0->actor_specific_1_f;
|
||||
sp6C[1] = 0.0f;
|
||||
sp6C[2] = 0.0f;
|
||||
guRotateRPYF(sp20[0], arg0->roll, 90.0f - arg0->yaw, arg0->pitch);
|
||||
|
@ -230,7 +230,7 @@ bool func_8032C2F0(Actor *arg0, f32 arg1[3], s32 arg2, s32 arg3) {
|
|||
bool func_8032C404(Actor *arg0, f32 arg1[3], s32 arg2, s32 arg3) {
|
||||
f32 sp1C[3];
|
||||
|
||||
sp1C[0] = arg0->unk28;
|
||||
sp1C[0] = arg0->actor_specific_1_f;
|
||||
sp1C[1] = 0.0f;
|
||||
sp1C[2] = 0.0f;
|
||||
ml_vec3f_yaw_rotate_copy(sp1C, sp1C, arg0->yaw - 90.0);
|
||||
|
|
|
@ -63,14 +63,14 @@ void func_8035D65C(Actor *this) {
|
|||
return;
|
||||
}
|
||||
if (func_80329530(this, 500) && func_8028B470() && func_8035D608(this)) {
|
||||
this->unk28 = 2.0f;
|
||||
this->actor_specific_1_f = 2.0f;
|
||||
subaddie_set_state_with_direction(this, 4, 0.0f, -1);
|
||||
}
|
||||
}
|
||||
|
||||
void func_8035D6FC(Actor *this) {
|
||||
subaddie_set_state_with_direction(this, 3, 0.0f, -1);
|
||||
this->unk28 = 2.0f;
|
||||
this->actor_specific_1_f = 2.0f;
|
||||
subaddie_set_ideal_yaw(this, (s32) (randf2(-45.0f, 45.0f) + (this->yaw + 180.0f)));
|
||||
func_80328CA8(this, (s32) func_8035D590(randf2(-45.0f, 45.0f) + (360.0f - this->pitch)));
|
||||
this->unk38_31 = 0x78;
|
||||
|
@ -78,7 +78,7 @@ void func_8035D6FC(Actor *this) {
|
|||
|
||||
void func_8035D7CC(Actor *this) {
|
||||
subaddie_set_state_with_direction(this, 3, 0.0f, -1);
|
||||
this->unk28 = 2.0f;
|
||||
this->actor_specific_1_f = 2.0f;
|
||||
subaddie_set_ideal_yaw(this, (s32) (randf2(-45.0f, 45.0f) + (this->yaw + 180.0f)));
|
||||
func_80328CA8(this, (s32) func_8035D590(randf2(-45.0f, 45.0f) + (360.0f - this->pitch)));
|
||||
}
|
||||
|
@ -128,10 +128,10 @@ void func_8035DA1C(Actor *this) {
|
|||
if (!this->initialized) {
|
||||
this->initialized = TRUE;
|
||||
this->unk138_25 = TRUE;
|
||||
this->unk28 = 4.0f;
|
||||
this->actor_specific_1_f = 4.0f;
|
||||
LOCAL_D6600(this)->unk4 =(map_get() == MAP_71_GL_STATUE_ROOM) ? 8 : 0xf;
|
||||
if (volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE)) {
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
subaddie_set_state_with_direction(this, 1, 0.0f, 1);
|
||||
}
|
||||
func_8032CA80(this, LOCAL_D6600(this)->unk4);
|
||||
|
@ -152,7 +152,7 @@ void func_8035DA1C(Actor *this) {
|
|||
func_80328FF0(this, 0.5f);
|
||||
func_8032CA80(this, LOCAL_D6600(this)->unk4);
|
||||
if (subaddie_maybe_set_state(this, 2, 0.05f) && !volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE)) {
|
||||
this->unk28 = 4.0f;
|
||||
this->actor_specific_1_f = 4.0f;
|
||||
}
|
||||
func_8035D65C(this);
|
||||
break;
|
||||
|
@ -174,7 +174,7 @@ void func_8035DA1C(Actor *this) {
|
|||
func_80328CA8(this, 0);
|
||||
}
|
||||
if (subaddie_maybe_set_state_position_direction(this, 1, 0.0f, 1, 0.005f)) {
|
||||
this->unk28 = 2.0f;
|
||||
this->actor_specific_1_f = 2.0f;
|
||||
}
|
||||
func_8035D65C(this);
|
||||
break;
|
||||
|
@ -185,7 +185,7 @@ void func_8035DA1C(Actor *this) {
|
|||
func_8032CA80(this, LOCAL_D6600(this)->unk4);
|
||||
if (func_80329480(this) && func_8032944C(this)) {
|
||||
subaddie_set_state_with_direction(this, 2, 0.0f, -1);
|
||||
this->unk28 = 4.0f;
|
||||
this->actor_specific_1_f = 4.0f;
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -198,7 +198,7 @@ void func_8035DA1C(Actor *this) {
|
|||
func_8032CA80(this, LOCAL_D6600(this)->unk4);
|
||||
if (func_80329480(this) && func_8032944C(this)) {
|
||||
subaddie_set_state_with_direction(this, 5, 0.0f, -1);
|
||||
this->unk28 = 10.5f;
|
||||
this->actor_specific_1_f = 10.5f;
|
||||
}
|
||||
break;
|
||||
|
||||
|
|
|
@ -43,7 +43,7 @@ void func_8035F99C(Actor *this){
|
|||
if(!volatileFlag_get(VOLATILE_FLAG_C1_IN_FINAL_CHARACTER_PARADE)){
|
||||
subaddie_set_state_with_direction(this, 2, 0.01f, 1);
|
||||
actor_playAnimationOnce(this);
|
||||
this->unk28 = 5.0f;
|
||||
this->actor_specific_1_f = 5.0f;
|
||||
FUNC_8030E8B4(SFX_419_UNKNOWN, 1.0f, 28000, this->position, 0x4e2, 0x9c4);
|
||||
}
|
||||
}
|
||||
|
@ -51,7 +51,7 @@ void func_8035F99C(Actor *this){
|
|||
void func_8035FA0C(Actor *this){
|
||||
subaddie_set_state(this, 3);
|
||||
actor_loopAnimation(this);
|
||||
this->unk28 = 5.0f;
|
||||
this->actor_specific_1_f = 5.0f;
|
||||
}
|
||||
|
||||
void func_8035FA48(Actor *this){
|
||||
|
@ -75,7 +75,7 @@ void func_8035FAE0(Actor *this){
|
|||
subaddie_set_state_with_direction(this, 7, 0.01f, 1);
|
||||
actor_loopAnimation(this);
|
||||
this->yaw += 180.0f;
|
||||
this->unk28 = 20.0f;
|
||||
this->actor_specific_1_f = 20.0f;
|
||||
this->velocity_x = 300.0f;
|
||||
|
||||
}
|
||||
|
@ -181,7 +181,7 @@ bool func_8035FEDC(Actor *this){
|
|||
}
|
||||
|
||||
if(func_80329480(this)){
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
@ -190,7 +190,7 @@ bool func_8035FEDC(Actor *this){
|
|||
|
||||
bool func_8035FF5C(Actor *this){
|
||||
if(func_8032CA80(this, 5) && func_80329480(this)){
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
return FALSE;
|
||||
}
|
||||
return TRUE;
|
||||
|
@ -241,12 +241,12 @@ bool func_80360198(Actor *this) {
|
|||
|
||||
func_80328FB0(this, 5.0f);
|
||||
func_80360044(this);
|
||||
this->unk28 += (this->velocity[1] * 0.45) - (0.001 * this->unk28);
|
||||
if (this->unk28 > 13.0) {
|
||||
this->unk28 = 13.0f;
|
||||
this->actor_specific_1_f += (this->velocity[1] * 0.45) - (0.001 * this->actor_specific_1_f);
|
||||
if (this->actor_specific_1_f > 13.0) {
|
||||
this->actor_specific_1_f = 13.0f;
|
||||
}
|
||||
if (this->unk28 < -13.0) {
|
||||
this->unk28 = -13.0f;
|
||||
if (this->actor_specific_1_f < -13.0) {
|
||||
this->actor_specific_1_f = -13.0f;
|
||||
}
|
||||
|
||||
this->velocity[0] += ((this->velocity[1] * 0.9) - 0.6);
|
||||
|
@ -302,7 +302,7 @@ f32 func_803603AC(Actor *this, s32 arg1, u8 arg2){
|
|||
return 0.0f;
|
||||
|
||||
|
||||
phi_f2 = -(this->unk28*(dy))/(D1 + D2);
|
||||
phi_f2 = -(this->actor_specific_1_f*(dy))/(D1 + D2);
|
||||
if (phi_f2 >= 4.0f) {
|
||||
phi_f2 = 4.0f;
|
||||
} else if (phi_f2 <= -4.0f) {
|
||||
|
@ -395,7 +395,7 @@ void func_80360828(Actor *this){
|
|||
this->initialized = TRUE;
|
||||
marker_setCollisionScripts(this->marker, NULL, func_803607FC, func_80360790);
|
||||
this->unk38_0 = FALSE;
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
this->velocity_x = 0.0f;
|
||||
this->unk1C_x = this->position_x;
|
||||
this->unk1C_y = this->position_y;
|
||||
|
|
|
@ -756,9 +756,9 @@ void func_80387BFC(Actor *this, f32 arg1) {
|
|||
sp44[1] = 2.0 * local->unk20 * sp50;
|
||||
sp44[2] = this->velocity[2] * sp58;
|
||||
ml_vec3f_normalize(sp44);
|
||||
sp44[0] *= this->unk28;
|
||||
sp44[1] *= this->unk28;
|
||||
sp44[2] *= this->unk28;
|
||||
sp44[0] *= this->actor_specific_1_f;
|
||||
sp44[1] *= this->actor_specific_1_f;
|
||||
sp44[2] *= this->actor_specific_1_f;
|
||||
}
|
||||
|
||||
void fight_func_80387D4C(Actor *actor) {
|
||||
|
@ -776,9 +776,9 @@ void fight_func_80387D4C(Actor *actor) {
|
|||
sp20[2] = actor->velocity[2] * local->unk14;
|
||||
|
||||
ml_vec3f_normalize(sp20, actor);
|
||||
sp20[0] = sp20[0] * actor->unk28;
|
||||
sp20[1] = sp20[1] * actor->unk28;
|
||||
sp20[2] = sp20[2] * actor->unk28;
|
||||
sp20[0] = sp20[0] * actor->actor_specific_1_f;
|
||||
sp20[1] = sp20[1] * actor->actor_specific_1_f;
|
||||
sp20[2] = sp20[2] * actor->actor_specific_1_f;
|
||||
}
|
||||
|
||||
void func_80387E1C(Actor *this, f32 arg1[3]) {
|
||||
|
@ -875,14 +875,14 @@ void chfinalboss_phase1_setState(Actor *this, s32 next_state) {
|
|||
} else {
|
||||
func_8030E878(SFX_14B_GRUNTY_LAUGH_4, randf2(0.95f, 1.05f), 32000, this->position, 5000.0f, 12000.0f);
|
||||
}
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
this->lifetime_value = 0.0f;
|
||||
break;
|
||||
case 6:
|
||||
local = local;
|
||||
func_80386600(this->marker, 1);
|
||||
func_80324D54(0.4f, SFX_C1_BUZZBOMB_ATTACK, 0.85f, 32000, this->position, 5000.0f, 12000.0f);
|
||||
this->unk28 = 0.0f;
|
||||
this->actor_specific_1_f = 0.0f;
|
||||
func_80387B00(this);
|
||||
local->unkA = 0;
|
||||
break;
|
||||
|
@ -890,13 +890,13 @@ void chfinalboss_phase1_setState(Actor *this, s32 next_state) {
|
|||
local->unk14 = (local->unk14 > 2000.0f) ? local->unk14 : 2000.0f;
|
||||
local->unk14 = (local->unk14 < 2700.0f) ? local->unk14 : 2700.0f;
|
||||
local->unk18 = 400.0f;
|
||||
local->unk28 = (-this->unk28 * this->unk28) / (2.0 * local->unk14);
|
||||
local->unk28 = (-this->actor_specific_1_f * this->actor_specific_1_f) / (2.0 * local->unk14);
|
||||
func_80386600(this->marker, 1);
|
||||
animctrl_setAnimTimer(this->animctrl, sp3C);
|
||||
break;
|
||||
case 8:
|
||||
temp_f12 = 1150.0f;
|
||||
local->unk28 = (-this->unk28 * this->unk28) / (2.0 * temp_f12);
|
||||
local->unk28 = (-this->actor_specific_1_f * this->actor_specific_1_f) / (2.0 * temp_f12);
|
||||
local->unk2C = (100.0f - local->unk1C) / temp_f12;
|
||||
break;
|
||||
case 9:
|
||||
|
@ -1013,11 +1013,11 @@ void chfinalboss_phase1_update(ActorMarker *marker) {
|
|||
func_80387B00(this);
|
||||
this->lifetime_value += sp54;
|
||||
if (this->lifetime_value < 0.3333333333333333) {
|
||||
this->unk28 += 3300.0 * sp54;
|
||||
this->actor_specific_1_f += 3300.0 * sp54;
|
||||
} else if (0.7333333333333334 < this->lifetime_value) {
|
||||
this->unk28 -= 3300.0 * sp54;
|
||||
this->actor_specific_1_f -= 3300.0 * sp54;
|
||||
}
|
||||
local->unk20 += this->unk28 * sp54;
|
||||
local->unk20 += this->actor_specific_1_f * sp54;
|
||||
func_80387BFC(this, 45.0f * sp54);
|
||||
func_80328FB0(this, 30.0f * sp54);
|
||||
if (this->lifetime_value > 1.0) {
|
||||
|
@ -1027,11 +1027,11 @@ void chfinalboss_phase1_update(ActorMarker *marker) {
|
|||
case 6:
|
||||
func_803869BC(this);
|
||||
if (local->unk4 >= (local->hits + 1)) {
|
||||
this->unk28 += (D_80391738[local->hits] * sp54) * 0.66;
|
||||
this->actor_specific_1_f += (D_80391738[local->hits] * sp54) * 0.66;
|
||||
} else {
|
||||
this->unk28 += D_80391738[local->hits] * sp54;
|
||||
this->actor_specific_1_f += D_80391738[local->hits] * sp54;
|
||||
}
|
||||
local->unk20 -= this->unk28 * sp54;
|
||||
local->unk20 -= this->actor_specific_1_f * sp54;
|
||||
func_80387BFC(this, 180.0f * sp54);
|
||||
func_80328FB0(this, 30.0f * sp54);
|
||||
if ((local->unkA == 0) && (local->unk20 < (local->unk14 * 0.65))) {
|
||||
|
@ -1065,11 +1065,11 @@ void chfinalboss_phase1_update(ActorMarker *marker) {
|
|||
break;
|
||||
case 7:
|
||||
func_803869BC(this);
|
||||
this->unk28 = this->unk28 + local->unk28 * sp54;
|
||||
local->unk20 = local->unk20 - this->unk28 * sp54;
|
||||
this->actor_specific_1_f = this->actor_specific_1_f + local->unk28 * sp54;
|
||||
local->unk20 = local->unk20 - this->actor_specific_1_f * sp54;
|
||||
func_80387BFC(this, 180.0f * sp54);
|
||||
func_80328FB0(this, 30.0f * sp54);
|
||||
if (this->unk28 < 0) {
|
||||
if (this->actor_specific_1_f < 0) {
|
||||
chfinalboss_phase1_setState(this, 4);
|
||||
func_80386654(1.5f, fight_D_80391390, fight_D_80391380);
|
||||
}
|
||||
|
@ -1077,12 +1077,12 @@ void chfinalboss_phase1_update(ActorMarker *marker) {
|
|||
case 8:
|
||||
func_803885DC(this);
|
||||
func_803869BC(this);
|
||||
this->unk28 = this->unk28 + local->unk28 * sp54;
|
||||
local->unk20 = local->unk20 - this->unk28 * sp54;
|
||||
this->actor_specific_1_f = this->actor_specific_1_f + local->unk28 * sp54;
|
||||
local->unk20 = local->unk20 - this->actor_specific_1_f * sp54;
|
||||
func_80387ACC(this, 60.0f * sp54);
|
||||
fight_func_80387D4C(this);
|
||||
func_80328FB0(this, 30.0f * sp54);
|
||||
if (this->unk28 < 0) {
|
||||
if (this->actor_specific_1_f < 0) {
|
||||
chfinalboss_phase1_setState(this, 9);
|
||||
func_80386654(2.0f, fight_D_80391390, fight_D_80391380);
|
||||
this->lifetime_value = 4.0f;
|
||||
|
|
|
@ -164,8 +164,8 @@ void func_80391810(Actor *this, s32 next_state) {
|
|||
local = (ActorLocal_lair_AD70 *)&this->local;
|
||||
switch (next_state) {
|
||||
case 1:
|
||||
sp34 = (this->position[1] + this->unk28) - this->unk1C[1];
|
||||
this->velocity[1] = gu_sqrtf(this->unk28 * 2000.0);
|
||||
sp34 = (this->position[1] + this->actor_specific_1_f) - this->unk1C[1];
|
||||
this->velocity[1] = gu_sqrtf(this->actor_specific_1_f * 2000.0);
|
||||
local->unk0 = -this->velocity[1] / -1000.0f;
|
||||
local->unk0 += gu_sqrtf((sp34 * -2.0) / -1000.0);
|
||||
this->velocity[0] = this->unk1C[0] - this->position[0];
|
||||
|
@ -296,7 +296,7 @@ void func_80391EA8(ActorMarker *marker, ActorMarker *a1, f32 a2[3], f32 f1, f32
|
|||
actor->unk1C[1] = a2[1];
|
||||
actor->unk1C[2] = a2[2];
|
||||
|
||||
actor->unk28 = f1;
|
||||
actor->actor_specific_1_f = f1;
|
||||
|
||||
actor->yaw_ideal = randf2( 240, 480);
|
||||
actor->unk6C = randf2(-240, -480);
|
||||
|
|
Loading…
Reference in New Issue