summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDragorn421 <Dragorn421@users.noreply.github.com>2025-06-26 20:45:44 +0100
committerGitHub <noreply@github.com>2025-06-27 04:45:44 +0900
commit88f452af10b517e71c6c10e2ed424bdcb6a77490 (patch)
treedbd6cd954e55b69358edb8d7d0b93162729c1252 /src
parentd44c341c2d1d5b82cf35d73aeb66e77a8f62bbdb (diff)
Reevaluate player hit response names (#2640)
* PlayerHitResponseType * PLAYER_HIT_RESPONSE_ICE_TRAP -> FROZEN * PLAYER_KNOCKBACK_LARGE_SHOCK, PLAYER_HIT_RESPONSE_ELECTRIC_SHOCK -> PLAYER_KNOCKBACK_LARGE_ELECTRIFIED, PLAYER_HIT_RESPONSE_ELECTRIFIED * damageResponseType -> hitResponseType
Diffstat (limited to 'src')
-rw-r--r--src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c2
-rw-r--r--src/overlays/actors/ovl_player_actor/z_player.c23
2 files changed, 12 insertions, 13 deletions
diff --git a/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c b/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c
index 108dbbe35..e594e4229 100644
--- a/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c
+++ b/src/overlays/actors/ovl_En_Fhg_Fire/z_en_fhg_fire.c
@@ -550,7 +550,7 @@ void EnFhgFire_EnergyBall(EnFhgFire* this, PlayState* play) {
Actor_PlaySfx(&this->actor, NA_SE_EN_FANTOM_LAUGH);
}
Actor_SetPlayerKnockback(play, &this->actor, 3.0f, this->actor.world.rot.y, 0.0f,
- PLAYER_KNOCKBACK_LARGE_SHOCK, 0x10);
+ PLAYER_KNOCKBACK_LARGE_ELECTRIFIED, 0x10);
}
break;
case FHGFIRE_LIGHT_BLUE:
diff --git a/src/overlays/actors/ovl_player_actor/z_player.c b/src/overlays/actors/ovl_player_actor/z_player.c
index 10fd868cb..ff7fbb1b3 100644
--- a/src/overlays/actors/ovl_player_actor/z_player.c
+++ b/src/overlays/actors/ovl_player_actor/z_player.c
@@ -4619,7 +4619,7 @@ static LinkAnimationHeader* D_808544B0[] = {
&gPlayerAnim_link_normal_back_hit, &gPlayerAnim_link_anchor_back_hitR,
};
-void func_80837C0C(PlayState* play, Player* this, s32 damageResponseType, f32 speed, f32 yVelocity, s16 yRot,
+void func_80837C0C(PlayState* play, Player* this, s32 hitResponseType, f32 speed, f32 yVelocity, s16 yRot,
s32 invincibilityTimer) {
LinkAnimationHeader* anim = NULL;
LinkAnimationHeader** sp28;
@@ -4642,7 +4642,7 @@ void func_80837C0C(PlayState* play, Player* this, s32 damageResponseType, f32 sp
Player_SetIntangibility(this, invincibilityTimer);
- if (damageResponseType == PLAYER_HIT_RESPONSE_ICE_TRAP) {
+ if (hitResponseType == PLAYER_HIT_RESPONSE_FROZEN) {
Player_SetupAction(play, this, Player_Action_8084FB10, 0);
anim = &gPlayerAnim_link_normal_ice_down;
@@ -4652,7 +4652,7 @@ void func_80837C0C(PlayState* play, Player* this, s32 damageResponseType, f32 sp
Player_PlaySfx(this, NA_SE_PL_FREEZE_S);
Player_PlayVoiceSfx(this, NA_SE_VO_LI_FREEZE);
- } else if (damageResponseType == PLAYER_HIT_RESPONSE_ELECTRIC_SHOCK) {
+ } else if (hitResponseType == PLAYER_HIT_RESPONSE_ELECTRIFIED) {
Player_SetupAction(play, this, Player_Action_8084FBF4, 0);
Player_RequestRumble(this, 255, 80, 150, 0);
@@ -4673,8 +4673,8 @@ void func_80837C0C(PlayState* play, Player* this, s32 damageResponseType, f32 sp
anim = &gPlayerAnim_link_swimer_swim_hit;
Player_PlayVoiceSfx(this, NA_SE_VO_LI_DAMAGE_S);
- } else if ((damageResponseType == PLAYER_HIT_RESPONSE_KNOCKBACK_LARGE) ||
- (damageResponseType == PLAYER_HIT_RESPONSE_KNOCKBACK_SMALL) ||
+ } else if ((hitResponseType == PLAYER_HIT_RESPONSE_KNOCKBACK_LARGE) ||
+ (hitResponseType == PLAYER_HIT_RESPONSE_KNOCKBACK_SMALL) ||
!(this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) ||
(this->stateFlags1 & (PLAYER_STATE1_13 | PLAYER_STATE1_14 | PLAYER_STATE1_21))) {
Player_SetupAction(play, this, Player_Action_8084377C, 0);
@@ -4684,7 +4684,7 @@ void func_80837C0C(PlayState* play, Player* this, s32 damageResponseType, f32 sp
Player_RequestRumble(this, 255, 20, 150, 0);
func_80832224(this);
- if (damageResponseType == PLAYER_HIT_RESPONSE_KNOCKBACK_SMALL) {
+ if (hitResponseType == PLAYER_HIT_RESPONSE_KNOCKBACK_SMALL) {
this->av2.actionVar2 = 4;
this->actor.speed = 3.0f;
@@ -4867,7 +4867,7 @@ s32 func_808382DC(Player* this, PlayState* play) {
func_80838280(this);
- if (this->knockbackType == PLAYER_KNOCKBACK_LARGE_SHOCK) {
+ if (this->knockbackType == PLAYER_KNOCKBACK_LARGE_ELECTRIFIED) {
this->bodyShockTimer = 40;
}
@@ -4939,9 +4939,9 @@ s32 func_808382DC(Player* this, PlayState* play) {
if (this->stateFlags1 & PLAYER_STATE1_27) {
sp4C = PLAYER_HIT_RESPONSE_NONE;
} else if (this->actor.colChkInfo.acHitSpecialEffect == HIT_SPECIAL_EFFECT_ICE) {
- sp4C = PLAYER_HIT_RESPONSE_ICE_TRAP;
+ sp4C = PLAYER_HIT_RESPONSE_FROZEN;
} else if (this->actor.colChkInfo.acHitSpecialEffect == HIT_SPECIAL_EFFECT_ELECTRIC) {
- sp4C = PLAYER_HIT_RESPONSE_ELECTRIC_SHOCK;
+ sp4C = PLAYER_HIT_RESPONSE_ELECTRIFIED;
} else if (this->actor.colChkInfo.acHitSpecialEffect == HIT_SPECIAL_EFFECT_KNOCKBACK) {
sp4C = PLAYER_HIT_RESPONSE_KNOCKBACK_LARGE;
} else {
@@ -9147,8 +9147,7 @@ s32 func_80842DF4(PlayState* play, Player* this) {
if (this->actor.colChkInfo.atHitBacklash == HIT_BACKLASH_ELECTRIC) {
this->actor.colChkInfo.damage = 8;
- func_80837C0C(play, this, PLAYER_HIT_RESPONSE_ELECTRIC_SHOCK, 0.0f, 0.0f, this->actor.shape.rot.y,
- 20);
+ func_80837C0C(play, this, PLAYER_HIT_RESPONSE_ELECTRIFIED, 0.0f, 0.0f, this->actor.shape.rot.y, 20);
return 1;
}
}
@@ -13905,7 +13904,7 @@ void Player_Action_8084E6D4(Player* this, PlayState* play) {
func_8083C0E8(this, play);
} else {
this->actor.colChkInfo.damage = 0;
- func_80837C0C(play, this, PLAYER_HIT_RESPONSE_ICE_TRAP, 0.0f, 0.0f, 0, 20);
+ func_80837C0C(play, this, PLAYER_HIT_RESPONSE_FROZEN, 0.0f, 0.0f, 0, 20);
}
return;
}