diff --git a/include/z64actor.h b/include/z64actor.h index ab58a16f86..38425b9ca2 100644 --- a/include/z64actor.h +++ b/include/z64actor.h @@ -916,7 +916,7 @@ void func_80034BA0(struct PlayState* play, SkelAnime* skelAnime, OverrideLimbDra PostLimbDraw postLimbDraw, Actor* actor, s16 alpha); void func_80034CC4(struct PlayState* play, SkelAnime* skelAnime, OverrideLimbDraw overrideLimbDraw, PostLimbDraw postLimbDraw, Actor* actor, s16 alpha); -s16 Actor_FadeInOut(Actor* actor, struct PlayState* play, s16 alpha, f32 radius); +s16 Actor_UpdateAlphaByDistance(Actor* actor, struct PlayState* play, s16 alpha, f32 radius); void func_80034F54(struct PlayState* play, s16* arg1, s16* arg2, s32 arg3); void Actor_Noop(Actor* actor, struct PlayState* play); diff --git a/src/code/z_actor.c b/src/code/z_actor.c index 0ac8b2ac2f..d8b03cb4c6 100644 --- a/src/code/z_actor.c +++ b/src/code/z_actor.c @@ -4396,7 +4396,7 @@ void func_80034CC4(PlayState* play, SkelAnime* skelAnime, OverrideLimbDraw overr CLOSE_DISPS(play->state.gfxCtx, "../z_actor.c", 8904); } -s16 Actor_FadeInOut(Actor* actor, PlayState* play, s16 alpha, f32 radius) { +s16 Actor_UpdateAlphaByDistance(Actor* actor, PlayState* play, s16 alpha, f32 radius) { Player* player = GET_PLAYER(play); f32 distance; diff --git a/src/overlays/actors/ovl_En_Md/z_en_md.c b/src/overlays/actors/ovl_En_Md/z_en_md.c index 0b2ad7285d..3bfc78a865 100644 --- a/src/overlays/actors/ovl_En_Md/z_en_md.c +++ b/src/overlays/actors/ovl_En_Md/z_en_md.c @@ -650,7 +650,7 @@ u8 EnMd_SetMovedPos(EnMd* this, PlayState* play) { return 1; } -void EnMd_FadeInOut(EnMd* this, PlayState* play) { +void EnMd_UpdateAlphaByDistance(EnMd* this, PlayState* play) { f32 radius; if (play->sceneId != SCENE_MIDOS_HOUSE) { @@ -658,7 +658,7 @@ void EnMd_FadeInOut(EnMd* this, PlayState* play) { (play->sceneId == SCENE_KOKIRI_FOREST)) ? 100.0f : 400.0f; - this->alpha = Actor_FadeInOut(&this->actor, play, this->alpha, radius); + this->alpha = Actor_UpdateAlphaByDistance(&this->actor, play, this->alpha, radius); this->actor.shape.shadowAlpha = this->alpha; } else { this->alpha = 255; @@ -844,7 +844,7 @@ void EnMd_Update(Actor* thisx, PlayState* play) { CollisionCheck_SetOC(play, &play->colChkCtx, &this->collider.base); SkelAnime_Update(&this->skelAnime); EnMd_UpdateEyes(this); - EnMd_FadeInOut(this, play); + EnMd_UpdateAlphaByDistance(this, play); Actor_MoveXZGravity(&this->actor); EnMd_UpdateTalking(this, play); Actor_UpdateBgCheckInfo(play, &this->actor, 0.0f, 0.0f, 0.0f, UPDBGCHECKINFO_FLAG_2); diff --git a/src/overlays/actors/ovl_En_Sa/z_en_sa.c b/src/overlays/actors/ovl_En_Sa/z_en_sa.c index 9fd6d1e41a..55fd9bfd03 100644 --- a/src/overlays/actors/ovl_En_Sa/z_en_sa.c +++ b/src/overlays/actors/ovl_En_Sa/z_en_sa.c @@ -738,7 +738,7 @@ void EnSa_Update(Actor* thisx, PlayState* play) { } if (this->actionFunc != func_80AF68E4) { - this->alpha = Actor_FadeInOut(&this->actor, play, this->alpha, 400.0f); + this->alpha = Actor_UpdateAlphaByDistance(&this->actor, play, this->alpha, 400.0f); } else { this->alpha = 255; }