From 5d95bf33ac79ef91a0792706b20fe2d0af092dd2 Mon Sep 17 00:00:00 2001 From: Dragorn421 Date: Sun, 1 Jun 2025 17:15:15 +0200 Subject: [PATCH] _DMG_REAC_ -> _DMG_REACT_ --- src/overlays/actors/ovl_En_Am/z_en_am.c | 92 +++++----- .../actors/ovl_En_Anubice/z_en_anubice.c | 72 ++++---- .../actors/ovl_En_Anubice/z_en_anubice.h | 2 +- src/overlays/actors/ovl_En_Bili/z_en_bili.c | 86 +++++----- .../actors/ovl_En_Dekubaba/z_en_dekubaba.c | 158 +++++++++--------- src/overlays/actors/ovl_En_GeldB/z_en_geldb.c | 88 +++++----- src/overlays/actors/ovl_En_Ik/z_en_ik.c | 80 ++++----- src/overlays/actors/ovl_En_Mb/z_en_mb.c | 150 ++++++++--------- .../actors/ovl_En_Peehat/z_en_peehat.c | 88 +++++----- src/overlays/actors/ovl_En_Rd/z_en_rd.c | 90 +++++----- src/overlays/actors/ovl_En_Reeba/z_en_reeba.c | 90 +++++----- src/overlays/actors/ovl_En_Rr/z_en_rr.c | 102 +++++------ src/overlays/actors/ovl_En_Test/z_en_test.c | 92 +++++----- src/overlays/actors/ovl_En_Tp/z_en_tp.c | 80 ++++----- src/overlays/actors/ovl_En_Vali/z_en_vali.c | 92 +++++----- .../actors/ovl_En_Wallmas/z_en_wallmas.c | 78 ++++----- src/overlays/actors/ovl_En_Wf/z_en_wf.c | 86 +++++----- src/overlays/actors/ovl_En_Zf/z_en_zf.c | 88 +++++----- 18 files changed, 807 insertions(+), 807 deletions(-) diff --git a/src/overlays/actors/ovl_En_Am/z_en_am.c b/src/overlays/actors/ovl_En_Am/z_en_am.c index af3c28e20d..507e29ba8f 100644 --- a/src/overlays/actors/ovl_En_Am/z_en_am.c +++ b/src/overlays/actors/ovl_En_Am/z_en_am.c @@ -128,47 +128,47 @@ static ColliderQuadInit sQuadInit = { }; typedef enum ArmosDamageReaction { - /* 0 */ AM_DMG_REAC_NONE, // used by anything that can't kill the armos - /* 1 */ AM_DMG_REAC_NUT, - /* 6 */ AM_DMG_REAC_STUN = 6, // doesn't include deku nuts - /* 13 */ AM_DMG_REAC_ICE = 13, - /* 14 */ AM_DMG_REAC_MAGIC_FIRE_LIGHT, - /* 15 */ AM_DMG_REAC_KILL // any damage source that can kill the armos (and isn't a special case) + /* 0 */ AM_DMG_REACT_NONE, // used by anything that can't kill the armos + /* 1 */ AM_DMG_REACT_NUT, + /* 6 */ AM_DMG_REACT_STUN = 6, // doesn't include deku nuts + /* 13 */ AM_DMG_REACT_ICE = 13, + /* 14 */ AM_DMG_REACT_MAGIC_FIRE_LIGHT, + /* 15 */ AM_DMG_REACT_KILL // any damage source that can kill the armos (and isn't a special case) } ArmosDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, AM_DMG_REAC_NUT), - /* Deku stick */ DMG_ENTRY(2, AM_DMG_REAC_NONE), - /* Slingshot */ DMG_ENTRY(1, AM_DMG_REAC_NONE), - /* Explosive */ DMG_ENTRY(2, AM_DMG_REAC_KILL), - /* Boomerang */ DMG_ENTRY(0, AM_DMG_REAC_STUN), - /* Normal arrow */ DMG_ENTRY(2, AM_DMG_REAC_KILL), - /* Hammer swing */ DMG_ENTRY(2, AM_DMG_REAC_KILL), - /* Hookshot */ DMG_ENTRY(0, AM_DMG_REAC_STUN), - /* Kokiri sword */ DMG_ENTRY(1, AM_DMG_REAC_NONE), - /* Master sword */ DMG_ENTRY(2, AM_DMG_REAC_KILL), - /* Giant's Knife */ DMG_ENTRY(4, AM_DMG_REAC_KILL), - /* Fire arrow */ DMG_ENTRY(2, AM_DMG_REAC_KILL), - /* Ice arrow */ DMG_ENTRY(4, AM_DMG_REAC_ICE), - /* Light arrow */ DMG_ENTRY(2, AM_DMG_REAC_KILL), - /* Unk arrow 1 */ DMG_ENTRY(2, AM_DMG_REAC_NONE), - /* Unk arrow 2 */ DMG_ENTRY(2, AM_DMG_REAC_NONE), - /* Unk arrow 3 */ DMG_ENTRY(2, AM_DMG_REAC_NONE), - /* Fire magic */ DMG_ENTRY(0, AM_DMG_REAC_MAGIC_FIRE_LIGHT), - /* Ice magic */ DMG_ENTRY(3, AM_DMG_REAC_ICE), - /* Light magic */ DMG_ENTRY(0, AM_DMG_REAC_MAGIC_FIRE_LIGHT), - /* Shield */ DMG_ENTRY(0, AM_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, AM_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, AM_DMG_REAC_NONE), - /* Giant spin */ DMG_ENTRY(4, AM_DMG_REAC_KILL), - /* Master spin */ DMG_ENTRY(2, AM_DMG_REAC_KILL), - /* Kokiri jump */ DMG_ENTRY(2, AM_DMG_REAC_NONE), - /* Giant jump */ DMG_ENTRY(8, AM_DMG_REAC_KILL), - /* Master jump */ DMG_ENTRY(4, AM_DMG_REAC_KILL), - /* Unknown 1 */ DMG_ENTRY(0, AM_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, AM_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, AM_DMG_REAC_KILL), - /* Unknown 2 */ DMG_ENTRY(0, AM_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, AM_DMG_REACT_NUT), + /* Deku stick */ DMG_ENTRY(2, AM_DMG_REACT_NONE), + /* Slingshot */ DMG_ENTRY(1, AM_DMG_REACT_NONE), + /* Explosive */ DMG_ENTRY(2, AM_DMG_REACT_KILL), + /* Boomerang */ DMG_ENTRY(0, AM_DMG_REACT_STUN), + /* Normal arrow */ DMG_ENTRY(2, AM_DMG_REACT_KILL), + /* Hammer swing */ DMG_ENTRY(2, AM_DMG_REACT_KILL), + /* Hookshot */ DMG_ENTRY(0, AM_DMG_REACT_STUN), + /* Kokiri sword */ DMG_ENTRY(1, AM_DMG_REACT_NONE), + /* Master sword */ DMG_ENTRY(2, AM_DMG_REACT_KILL), + /* Giant's Knife */ DMG_ENTRY(4, AM_DMG_REACT_KILL), + /* Fire arrow */ DMG_ENTRY(2, AM_DMG_REACT_KILL), + /* Ice arrow */ DMG_ENTRY(4, AM_DMG_REACT_ICE), + /* Light arrow */ DMG_ENTRY(2, AM_DMG_REACT_KILL), + /* Unk arrow 1 */ DMG_ENTRY(2, AM_DMG_REACT_NONE), + /* Unk arrow 2 */ DMG_ENTRY(2, AM_DMG_REACT_NONE), + /* Unk arrow 3 */ DMG_ENTRY(2, AM_DMG_REACT_NONE), + /* Fire magic */ DMG_ENTRY(0, AM_DMG_REACT_MAGIC_FIRE_LIGHT), + /* Ice magic */ DMG_ENTRY(3, AM_DMG_REACT_ICE), + /* Light magic */ DMG_ENTRY(0, AM_DMG_REACT_MAGIC_FIRE_LIGHT), + /* Shield */ DMG_ENTRY(0, AM_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, AM_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, AM_DMG_REACT_NONE), + /* Giant spin */ DMG_ENTRY(4, AM_DMG_REACT_KILL), + /* Master spin */ DMG_ENTRY(2, AM_DMG_REACT_KILL), + /* Kokiri jump */ DMG_ENTRY(2, AM_DMG_REACT_NONE), + /* Giant jump */ DMG_ENTRY(8, AM_DMG_REACT_KILL), + /* Master jump */ DMG_ENTRY(4, AM_DMG_REACT_KILL), + /* Unknown 1 */ DMG_ENTRY(0, AM_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, AM_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, AM_DMG_REACT_KILL), + /* Unknown 2 */ DMG_ENTRY(0, AM_DMG_REACT_NONE), }; static InitChainEntry sInitChain[] = { @@ -735,7 +735,7 @@ void EnAm_SetupStunned(EnAm* this, PlayState* play) { Actor_SetColorFilter(&this->dyna.actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 100); - if (this->damageReaction == AM_DMG_REAC_ICE) { + if (this->damageReaction == AM_DMG_REACT_ICE) { this->iceTimer = 48; } @@ -810,27 +810,27 @@ void EnAm_UpdateDamage(EnAm* this, PlayState* play) { } else if ((this->hurtCollider.base.acFlags & AC_HIT) && (this->behavior >= AM_BEHAVIOR_5)) { this->hurtCollider.base.acFlags &= ~AC_HIT; - if (this->dyna.actor.colChkInfo.damageReaction != AM_DMG_REAC_MAGIC_FIRE_LIGHT) { + if (this->dyna.actor.colChkInfo.damageReaction != AM_DMG_REACT_MAGIC_FIRE_LIGHT) { this->unk_264 = 0; this->damageReaction = this->dyna.actor.colChkInfo.damageReaction; Actor_SetDropFlag(&this->dyna.actor, &this->hurtCollider.elem, false); - if ((this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REAC_NUT) || - (this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REAC_STUN) || - (this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REAC_ICE)) { + if ((this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REACT_NUT) || + (this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REACT_STUN) || + (this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REACT_ICE)) { if (this->behavior != AM_BEHAVIOR_STUNNED) { EnAm_SetupStunned(this, play); if (this->dyna.actor.colChkInfo.damage != 0) { this->dyna.actor.colChkInfo.health = 0; } - } else if (this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REAC_STUN) { + } else if (this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REACT_STUN) { Vec3f sparkPos = this->dyna.actor.world.pos; sparkPos.y += 50.0f; CollisionCheck_SpawnShieldParticlesMetal(play, &sparkPos); } - } else if ((this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REAC_KILL) || + } else if ((this->dyna.actor.colChkInfo.damageReaction == AM_DMG_REACT_KILL) || (this->behavior == AM_BEHAVIOR_STUNNED)) { this->dyna.actor.colChkInfo.health = 0; @@ -857,7 +857,7 @@ void EnAm_Update(Actor* thisx, PlayState* play) { EnAm_UpdateDamage(this, play); } - if (this->dyna.actor.colChkInfo.damageReaction != AM_DMG_REAC_MAGIC_FIRE_LIGHT) { + if (this->dyna.actor.colChkInfo.damageReaction != AM_DMG_REACT_MAGIC_FIRE_LIGHT) { if (this->attackTimer != 0) { this->attackTimer--; } diff --git a/src/overlays/actors/ovl_En_Anubice/z_en_anubice.c b/src/overlays/actors/ovl_En_Anubice/z_en_anubice.c index b977bc8dc1..dca62ddf43 100644 --- a/src/overlays/actors/ovl_En_Anubice/z_en_anubice.c +++ b/src/overlays/actors/ovl_En_Anubice/z_en_anubice.c @@ -74,44 +74,44 @@ static ColliderCylinderInit sCylinderInit = { }; typedef enum AnubiceDamageReaction { - /* 0x0 */ ANUBICE_DMG_REAC_NONE, - /* 0x2 */ ANUBICE_DMG_REAC_FIRE = 2, - /* 0xF */ ANUBICE_DMG_REAC_0xF = 0xF // Treated the same as ANUBICE_DMG_REAC_NONE in code + /* 0x0 */ ANUBICE_DMG_REACT_NONE, + /* 0x2 */ ANUBICE_DMG_REACT_FIRE = 2, + /* 0xF */ ANUBICE_DMG_REACT_0xF = 0xF // Treated the same as ANUBICE_DMG_REACT_NONE in code } AnubiceDamageReaction; static DamageTable sDamageTable[] = { - /* Deku nut */ DMG_ENTRY(0, ANUBICE_DMG_REAC_NONE), - /* Deku stick */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Slingshot */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Explosive */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Boomerang */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Normal arrow */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Hammer swing */ DMG_ENTRY(1, ANUBICE_DMG_REAC_0xF), - /* Hookshot */ DMG_ENTRY(2, ANUBICE_DMG_REAC_0xF), - /* Kokiri sword */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Master sword */ DMG_ENTRY(2, ANUBICE_DMG_REAC_0xF), - /* Giant's Knife */ DMG_ENTRY(6, ANUBICE_DMG_REAC_0xF), - /* Fire arrow */ DMG_ENTRY(2, ANUBICE_DMG_REAC_FIRE), - /* Ice arrow */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Light arrow */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Unk arrow 1 */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Unk arrow 2 */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Unk arrow 3 */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Fire magic */ DMG_ENTRY(3, ANUBICE_DMG_REAC_FIRE), - /* Ice magic */ DMG_ENTRY(0, ANUBICE_DMG_REAC_NONE), - /* Light magic */ DMG_ENTRY(0, ANUBICE_DMG_REAC_NONE), - /* Shield */ DMG_ENTRY(0, ANUBICE_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, ANUBICE_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Giant spin */ DMG_ENTRY(6, ANUBICE_DMG_REAC_0xF), - /* Master spin */ DMG_ENTRY(2, ANUBICE_DMG_REAC_0xF), - /* Kokiri jump */ DMG_ENTRY(0, ANUBICE_DMG_REAC_0xF), - /* Giant jump */ DMG_ENTRY(12, ANUBICE_DMG_REAC_0xF), - /* Master jump */ DMG_ENTRY(4, ANUBICE_DMG_REAC_0xF), - /* Unknown 1 */ DMG_ENTRY(0, ANUBICE_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, ANUBICE_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(0, ANUBICE_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, ANUBICE_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, ANUBICE_DMG_REACT_NONE), + /* Deku stick */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Slingshot */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Explosive */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Boomerang */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Normal arrow */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Hammer swing */ DMG_ENTRY(1, ANUBICE_DMG_REACT_0xF), + /* Hookshot */ DMG_ENTRY(2, ANUBICE_DMG_REACT_0xF), + /* Kokiri sword */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Master sword */ DMG_ENTRY(2, ANUBICE_DMG_REACT_0xF), + /* Giant's Knife */ DMG_ENTRY(6, ANUBICE_DMG_REACT_0xF), + /* Fire arrow */ DMG_ENTRY(2, ANUBICE_DMG_REACT_FIRE), + /* Ice arrow */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Light arrow */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Unk arrow 1 */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Unk arrow 2 */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Unk arrow 3 */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Fire magic */ DMG_ENTRY(3, ANUBICE_DMG_REACT_FIRE), + /* Ice magic */ DMG_ENTRY(0, ANUBICE_DMG_REACT_NONE), + /* Light magic */ DMG_ENTRY(0, ANUBICE_DMG_REACT_NONE), + /* Shield */ DMG_ENTRY(0, ANUBICE_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, ANUBICE_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Giant spin */ DMG_ENTRY(6, ANUBICE_DMG_REACT_0xF), + /* Master spin */ DMG_ENTRY(2, ANUBICE_DMG_REACT_0xF), + /* Kokiri jump */ DMG_ENTRY(0, ANUBICE_DMG_REACT_0xF), + /* Giant jump */ DMG_ENTRY(12, ANUBICE_DMG_REACT_0xF), + /* Master jump */ DMG_ENTRY(4, ANUBICE_DMG_REACT_0xF), + /* Unknown 1 */ DMG_ENTRY(0, ANUBICE_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, ANUBICE_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(0, ANUBICE_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, ANUBICE_DMG_REACT_NONE), }; void EnAnubice_Hover(EnAnubice* this, PlayState* play) { @@ -399,7 +399,7 @@ void EnAnubice_Update(Actor* thisx, PlayState* play) { if (this->collider.base.acFlags & AC_HIT) { this->collider.base.acFlags &= ~AC_HIT; - if (this->actor.colChkInfo.damageReaction == ANUBICE_DMG_REAC_FIRE) { + if (this->actor.colChkInfo.damageReaction == ANUBICE_DMG_REACT_FIRE) { Actor_ChangeCategory(play, &play->actorCtx, &this->actor, ACTORCAT_PROP); this->actor.flags &= ~ACTOR_FLAG_ATTENTION_ENABLED; Enemy_StartFinishingBlow(play, &this->actor); diff --git a/src/overlays/actors/ovl_En_Anubice/z_en_anubice.h b/src/overlays/actors/ovl_En_Anubice/z_en_anubice.h index 740f3c2cc2..0ad49e2eb3 100644 --- a/src/overlays/actors/ovl_En_Anubice/z_en_anubice.h +++ b/src/overlays/actors/ovl_En_Anubice/z_en_anubice.h @@ -41,7 +41,7 @@ typedef struct EnAnubice { /* 0x025C */ s16 knockbackTimer; /* 0x025E */ s16 isMirroringPlayer; /* 0x0260 */ s16 isPlayerOutOfRange; - /* 0x0262 */ s16 isKnockedback; // Hit by an attack without ANUBICE_DMG_REAC_FIRE + /* 0x0262 */ s16 isKnockedback; // Hit by an attack without ANUBICE_DMG_REACT_FIRE /* 0x0264 */ s16 hasSearchedForFlameCircles; /* 0x0268 */ f32 hoverVelocityTimer; /* 0x026C */ f32 animLastFrame; diff --git a/src/overlays/actors/ovl_En_Bili/z_en_bili.c b/src/overlays/actors/ovl_En_Bili/z_en_bili.c index e9f63baedb..7a6b7fd78b 100644 --- a/src/overlays/actors/ovl_En_Bili/z_en_bili.c +++ b/src/overlays/actors/ovl_En_Bili/z_en_bili.c @@ -79,47 +79,47 @@ static ColliderCylinderInit sCylinderInit = { static CollisionCheckInfoInit2 sColChkInfoInit = { 1, 9, 28, -20, 30 }; typedef enum BiriDamageReaction { - /* 0x0 */ BIRI_DMG_REAC_NONE, - /* 0x1 */ BIRI_DMG_REAC_DEKUNUT, - /* 0x2 */ BIRI_DMG_REAC_FIRE, - /* 0x3 */ BIRI_DMG_REAC_ICE, - /* 0xE */ BIRI_DMG_REAC_SLINGSHOT = 0xE, - /* 0xF */ BIRI_DMG_REAC_SWORD + /* 0x0 */ BIRI_DMG_REACT_NONE, + /* 0x1 */ BIRI_DMG_REACT_DEKUNUT, + /* 0x2 */ BIRI_DMG_REACT_FIRE, + /* 0x3 */ BIRI_DMG_REACT_ICE, + /* 0xE */ BIRI_DMG_REACT_SLINGSHOT = 0xE, + /* 0xF */ BIRI_DMG_REACT_SWORD } BiriDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, BIRI_DMG_REAC_DEKUNUT), - /* Deku stick */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Slingshot */ DMG_ENTRY(0, BIRI_DMG_REAC_SLINGSHOT), - /* Explosive */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Boomerang */ DMG_ENTRY(1, BIRI_DMG_REAC_NONE), - /* Normal arrow */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Hammer swing */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Hookshot */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Kokiri sword */ DMG_ENTRY(1, BIRI_DMG_REAC_SWORD), - /* Master sword */ DMG_ENTRY(2, BIRI_DMG_REAC_SWORD), - /* Giant's Knife */ DMG_ENTRY(4, BIRI_DMG_REAC_SWORD), - /* Fire arrow */ DMG_ENTRY(4, BIRI_DMG_REAC_FIRE), - /* Ice arrow */ DMG_ENTRY(4, BIRI_DMG_REAC_ICE), - /* Light arrow */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Unk arrow 1 */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Unk arrow 2 */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Unk arrow 3 */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Fire magic */ DMG_ENTRY(4, BIRI_DMG_REAC_FIRE), - /* Ice magic */ DMG_ENTRY(4, BIRI_DMG_REAC_ICE), - /* Light magic */ DMG_ENTRY(0, BIRI_DMG_REAC_NONE), - /* Shield */ DMG_ENTRY(0, BIRI_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, BIRI_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, BIRI_DMG_REAC_NONE), - /* Giant spin */ DMG_ENTRY(4, BIRI_DMG_REAC_NONE), - /* Master spin */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Kokiri jump */ DMG_ENTRY(2, BIRI_DMG_REAC_NONE), - /* Giant jump */ DMG_ENTRY(8, BIRI_DMG_REAC_NONE), - /* Master jump */ DMG_ENTRY(4, BIRI_DMG_REAC_NONE), - /* Unknown 1 */ DMG_ENTRY(0, BIRI_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, BIRI_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, BIRI_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, BIRI_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, BIRI_DMG_REACT_DEKUNUT), + /* Deku stick */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Slingshot */ DMG_ENTRY(0, BIRI_DMG_REACT_SLINGSHOT), + /* Explosive */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Boomerang */ DMG_ENTRY(1, BIRI_DMG_REACT_NONE), + /* Normal arrow */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Hammer swing */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Hookshot */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Kokiri sword */ DMG_ENTRY(1, BIRI_DMG_REACT_SWORD), + /* Master sword */ DMG_ENTRY(2, BIRI_DMG_REACT_SWORD), + /* Giant's Knife */ DMG_ENTRY(4, BIRI_DMG_REACT_SWORD), + /* Fire arrow */ DMG_ENTRY(4, BIRI_DMG_REACT_FIRE), + /* Ice arrow */ DMG_ENTRY(4, BIRI_DMG_REACT_ICE), + /* Light arrow */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Unk arrow 1 */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Unk arrow 2 */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Unk arrow 3 */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Fire magic */ DMG_ENTRY(4, BIRI_DMG_REACT_FIRE), + /* Ice magic */ DMG_ENTRY(4, BIRI_DMG_REACT_ICE), + /* Light magic */ DMG_ENTRY(0, BIRI_DMG_REACT_NONE), + /* Shield */ DMG_ENTRY(0, BIRI_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, BIRI_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, BIRI_DMG_REACT_NONE), + /* Giant spin */ DMG_ENTRY(4, BIRI_DMG_REACT_NONE), + /* Master spin */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Kokiri jump */ DMG_ENTRY(2, BIRI_DMG_REACT_NONE), + /* Giant jump */ DMG_ENTRY(8, BIRI_DMG_REACT_NONE), + /* Master jump */ DMG_ENTRY(4, BIRI_DMG_REACT_NONE), + /* Unknown 1 */ DMG_ENTRY(0, BIRI_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, BIRI_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, BIRI_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, BIRI_DMG_REACT_NONE), }; static InitChainEntry sInitChain[] = { @@ -581,11 +581,11 @@ void EnBili_UpdateDamage(EnBili* this, PlayState* play) { damageReaction = this->actor.colChkInfo.damageReaction; - if (damageReaction == BIRI_DMG_REAC_DEKUNUT) { + if (damageReaction == BIRI_DMG_REACT_DEKUNUT) { if (this->actionFunc != EnBili_Stunned) { EnBili_SetupStunned(this); } - } else if (damageReaction == BIRI_DMG_REAC_SWORD) { + } else if (damageReaction == BIRI_DMG_REACT_SWORD) { if (this->actionFunc != EnBili_Stunned) { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 200, COLORFILTER_BUFFLAG_XLU, 10); @@ -596,12 +596,12 @@ void EnBili_UpdateDamage(EnBili* this, PlayState* play) { } else { EnBili_SetupBurnt(this); } - } else if (damageReaction == BIRI_DMG_REAC_FIRE) { + } else if (damageReaction == BIRI_DMG_REACT_FIRE) { EnBili_SetupBurnt(this); this->timer = 2; - } else if (damageReaction == BIRI_DMG_REAC_ICE) { + } else if (damageReaction == BIRI_DMG_REACT_ICE) { EnBili_SetupFrozen(this, play); - } else if (damageReaction == BIRI_DMG_REAC_SLINGSHOT) { + } else if (damageReaction == BIRI_DMG_REACT_SLINGSHOT) { EnBili_SetupRecoil(this); } else { EnBili_SetupBurnt(this); diff --git a/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c b/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c index 46f2cbf14e..f9bb260404 100644 --- a/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c +++ b/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c @@ -151,83 +151,83 @@ static ColliderJntSphInit sJntSphInit = { static CollisionCheckInfoInit sColChkInfoInit = { 2, 25, 25, MASS_IMMOVABLE }; typedef enum DekuBabaDamageReaction { - /* 0x0 */ DEKUBABA_DMG_REAC_NONE, - /* 0x1 */ DEKUBABA_DMG_REAC_DEKUNUT, - /* 0x2 */ DEKUBABA_DMG_REAC_FIRE, - /* 0xE */ DEKUBABA_DMG_REAC_BOOMERANG = 14, - /* 0xF */ DEKUBABA_DMG_REAC_SWORD + /* 0x0 */ DEKUBABA_DMG_REACT_NONE, + /* 0x1 */ DEKUBABA_DMG_REACT_DEKUNUT, + /* 0x2 */ DEKUBABA_DMG_REACT_FIRE, + /* 0xE */ DEKUBABA_DMG_REACT_BOOMERANG = 14, + /* 0xF */ DEKUBABA_DMG_REACT_SWORD } DekuBabaDamageReaction; static DamageTable sDekuBabaDamageTable = { - /* Deku nut */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_DEKUNUT), - /* Deku stick */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Slingshot */ DMG_ENTRY(1, DEKUBABA_DMG_REAC_NONE), - /* Explosive */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Boomerang */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_BOOMERANG), - /* Normal arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Hammer swing */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Hookshot */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Kokiri sword */ DMG_ENTRY(1, DEKUBABA_DMG_REAC_SWORD), - /* Master sword */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_SWORD), - /* Giant's Knife */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_SWORD), - /* Fire arrow */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_FIRE), - /* Ice arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Light arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Unk arrow 1 */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Unk arrow 2 */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Unk arrow 3 */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Fire magic */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_FIRE), - /* Ice magic */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Light magic */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Shield */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, DEKUBABA_DMG_REAC_SWORD), - /* Giant spin */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_SWORD), - /* Master spin */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_SWORD), - /* Kokiri jump */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_SWORD), - /* Giant jump */ DMG_ENTRY(8, DEKUBABA_DMG_REAC_SWORD), - /* Master jump */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_SWORD), - /* Unknown 1 */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_DEKUNUT), + /* Deku stick */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Slingshot */ DMG_ENTRY(1, DEKUBABA_DMG_REACT_NONE), + /* Explosive */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Boomerang */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_BOOMERANG), + /* Normal arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Hammer swing */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Hookshot */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Kokiri sword */ DMG_ENTRY(1, DEKUBABA_DMG_REACT_SWORD), + /* Master sword */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_SWORD), + /* Giant's Knife */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_SWORD), + /* Fire arrow */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_FIRE), + /* Ice arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Light arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Unk arrow 1 */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Unk arrow 2 */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Unk arrow 3 */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Fire magic */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_FIRE), + /* Ice magic */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Light magic */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Shield */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, DEKUBABA_DMG_REACT_SWORD), + /* Giant spin */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_SWORD), + /* Master spin */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_SWORD), + /* Kokiri jump */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_SWORD), + /* Giant jump */ DMG_ENTRY(8, DEKUBABA_DMG_REACT_SWORD), + /* Master jump */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_SWORD), + /* Unknown 1 */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), }; // The only difference is that for Big Deku Babas, Hookshot will act the same as Deku Nuts: i.e. it will stun, but // cannot kill. static DamageTable sBigDekuBabaDamageTable = { - /* Deku nut */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_DEKUNUT), - /* Deku stick */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Slingshot */ DMG_ENTRY(1, DEKUBABA_DMG_REAC_NONE), - /* Explosive */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Boomerang */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_BOOMERANG), - /* Normal arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Hammer swing */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Hookshot */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_DEKUNUT), - /* Kokiri sword */ DMG_ENTRY(1, DEKUBABA_DMG_REAC_SWORD), - /* Master sword */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_SWORD), - /* Giant's Knife */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_SWORD), - /* Fire arrow */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_FIRE), - /* Ice arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Light arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Unk arrow 1 */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Unk arrow 2 */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Unk arrow 3 */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_NONE), - /* Fire magic */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_FIRE), - /* Ice magic */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Light magic */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Shield */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, DEKUBABA_DMG_REAC_SWORD), - /* Giant spin */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_SWORD), - /* Master spin */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_SWORD), - /* Kokiri jump */ DMG_ENTRY(2, DEKUBABA_DMG_REAC_SWORD), - /* Giant jump */ DMG_ENTRY(8, DEKUBABA_DMG_REAC_SWORD), - /* Master jump */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_SWORD), - /* Unknown 1 */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, DEKUBABA_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, DEKUBABA_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_DEKUNUT), + /* Deku stick */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Slingshot */ DMG_ENTRY(1, DEKUBABA_DMG_REACT_NONE), + /* Explosive */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Boomerang */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_BOOMERANG), + /* Normal arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Hammer swing */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Hookshot */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_DEKUNUT), + /* Kokiri sword */ DMG_ENTRY(1, DEKUBABA_DMG_REACT_SWORD), + /* Master sword */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_SWORD), + /* Giant's Knife */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_SWORD), + /* Fire arrow */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_FIRE), + /* Ice arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Light arrow */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Unk arrow 1 */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Unk arrow 2 */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Unk arrow 3 */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_NONE), + /* Fire magic */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_FIRE), + /* Ice magic */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Light magic */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Shield */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, DEKUBABA_DMG_REACT_SWORD), + /* Giant spin */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_SWORD), + /* Master spin */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_SWORD), + /* Kokiri jump */ DMG_ENTRY(2, DEKUBABA_DMG_REACT_SWORD), + /* Giant jump */ DMG_ENTRY(8, DEKUBABA_DMG_REACT_SWORD), + /* Master jump */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_SWORD), + /* Unknown 1 */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, DEKUBABA_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, DEKUBABA_DMG_REACT_NONE), }; static InitChainEntry sInitChain[] = { @@ -257,7 +257,7 @@ void EnDekubaba_Init(Actor* thisx, PlayState* play) { // (Of course they reckoned without each age being able to use the other's items, so Stick and Master Sword // jumpslash can give the Stick drop as adult, and neither will as child.) if (!LINK_IS_ADULT) { - sBigDekuBabaDamageTable.table[0x1B] = DMG_ENTRY(4, DEKUBABA_DMG_REAC_NONE); // DMG_JUMP_MASTER + sBigDekuBabaDamageTable.table[0x1B] = DMG_ENTRY(4, DEKUBABA_DMG_REACT_NONE); // DMG_JUMP_MASTER } CollisionCheck_SetInfo(&this->actor.colChkInfo, &sBigDekuBabaDamageTable, &sColChkInfoInit); @@ -272,7 +272,7 @@ void EnDekubaba_Init(Actor* thisx, PlayState* play) { } if (!LINK_IS_ADULT) { - sDekuBabaDamageTable.table[0x1B] = DMG_ENTRY(4, DEKUBABA_DMG_REAC_NONE); // DMG_JUMP_MASTER + sDekuBabaDamageTable.table[0x1B] = DMG_ENTRY(4, DEKUBABA_DMG_REACT_NONE); // DMG_JUMP_MASTER } CollisionCheck_SetInfo(&this->actor.colChkInfo, &sDekuBabaDamageTable, &sColChkInfoInit); @@ -1049,15 +1049,15 @@ void EnDekubaba_UpdateDamage(EnDekubaba* this, PlayState* play) { Actor_SetDropFlagJntSph(&this->actor, &this->collider, true); if ((this->collider.base.colMaterial != COL_MATERIAL_HARD) && - ((this->actor.colChkInfo.damageReaction != DEKUBABA_DMG_REAC_NONE) || + ((this->actor.colChkInfo.damageReaction != DEKUBABA_DMG_REACT_NONE) || (this->actor.colChkInfo.damage != 0))) { phi_s0 = this->actor.colChkInfo.health - this->actor.colChkInfo.damage; if (this->actionFunc != EnDekubaba_StunnedVertical) { - if ((this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REAC_BOOMERANG) || - (this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REAC_DEKUNUT)) { - if (this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REAC_BOOMERANG) { + if ((this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REACT_BOOMERANG) || + (this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REACT_DEKUNUT)) { + if (this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REACT_BOOMERANG) { phi_s0 = this->actor.colChkInfo.health; } @@ -1071,14 +1071,14 @@ void EnDekubaba_UpdateDamage(EnDekubaba* this, PlayState* play) { } else { EnDekubaba_SetupHit(this, 0); } - } else if ((this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REAC_BOOMERANG) || - (this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REAC_SWORD)) { + } else if ((this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REACT_BOOMERANG) || + (this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REACT_SWORD)) { if (phi_s0 > 0) { EnDekubaba_SetupSway(this); } else { EnDekubaba_SetupPrunedSomersault(this); } - } else if (this->actor.colChkInfo.damageReaction != DEKUBABA_DMG_REAC_DEKUNUT) { + } else if (this->actor.colChkInfo.damageReaction != DEKUBABA_DMG_REACT_DEKUNUT) { EnDekubaba_SetupHit(this, 0); } else { return; @@ -1086,7 +1086,7 @@ void EnDekubaba_UpdateDamage(EnDekubaba* this, PlayState* play) { this->actor.colChkInfo.health = CLAMP_MIN(phi_s0, 0); - if (this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REAC_FIRE) { + if (this->actor.colChkInfo.damageReaction == DEKUBABA_DMG_REACT_FIRE) { firePos = &this->actor.world.pos; fireScale = (this->size * 70.0f); diff --git a/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c b/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c index 72bf4f98b3..e24904798e 100644 --- a/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c +++ b/src/overlays/actors/ovl_En_GeldB/z_en_geldb.c @@ -178,47 +178,47 @@ static ColliderQuadInit sSwordQuadInit = { }; typedef enum EnGeldBDamageReaction { - /* 0x0 */ GELDB_DMG_REAC_NORMAL, - /* 0x1 */ GELDB_DMG_REAC_STUN, - /* 0x6 */ GELDB_DMG_REAC_UNK_6 = 0x6, - /* 0xD */ GELDB_DMG_REAC_UNK_D = 0xD, - /* 0xE */ GELDB_DMG_REAC_UNK_E, - /* 0xF */ GELDB_DMG_REAC_FREEZE + /* 0x0 */ GELDB_DMG_REACT_NORMAL, + /* 0x1 */ GELDB_DMG_REACT_STUN, + /* 0x6 */ GELDB_DMG_REACT_UNK_6 = 0x6, + /* 0xD */ GELDB_DMG_REACT_UNK_D = 0xD, + /* 0xE */ GELDB_DMG_REACT_UNK_E, + /* 0xF */ GELDB_DMG_REACT_FREEZE } EnGeldBDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, GELDB_DMG_REAC_STUN), - /* Deku stick */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Slingshot */ DMG_ENTRY(1, GELDB_DMG_REAC_NORMAL), - /* Explosive */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Boomerang */ DMG_ENTRY(0, GELDB_DMG_REAC_STUN), - /* Normal arrow */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Hammer swing */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Hookshot */ DMG_ENTRY(0, GELDB_DMG_REAC_STUN), - /* Kokiri sword */ DMG_ENTRY(1, GELDB_DMG_REAC_NORMAL), - /* Master sword */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Giant's Knife */ DMG_ENTRY(4, GELDB_DMG_REAC_NORMAL), - /* Fire arrow */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Ice arrow */ DMG_ENTRY(2, GELDB_DMG_REAC_FREEZE), - /* Light arrow */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Unk arrow 1 */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Unk arrow 2 */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Unk arrow 3 */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Fire magic */ DMG_ENTRY(4, GELDB_DMG_REAC_UNK_E), - /* Ice magic */ DMG_ENTRY(0, GELDB_DMG_REAC_UNK_6), - /* Light magic */ DMG_ENTRY(3, GELDB_DMG_REAC_UNK_D), - /* Shield */ DMG_ENTRY(0, GELDB_DMG_REAC_NORMAL), - /* Mirror Ray */ DMG_ENTRY(0, GELDB_DMG_REAC_NORMAL), - /* Kokiri spin */ DMG_ENTRY(1, GELDB_DMG_REAC_NORMAL), - /* Giant spin */ DMG_ENTRY(4, GELDB_DMG_REAC_NORMAL), - /* Master spin */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Kokiri jump */ DMG_ENTRY(2, GELDB_DMG_REAC_NORMAL), - /* Giant jump */ DMG_ENTRY(8, GELDB_DMG_REAC_NORMAL), - /* Master jump */ DMG_ENTRY(4, GELDB_DMG_REAC_NORMAL), - /* Unknown 1 */ DMG_ENTRY(4, GELDB_DMG_REAC_NORMAL), - /* Unblockable */ DMG_ENTRY(0, GELDB_DMG_REAC_NORMAL), - /* Hammer jump */ DMG_ENTRY(4, GELDB_DMG_REAC_NORMAL), - /* Unknown 2 */ DMG_ENTRY(0, GELDB_DMG_REAC_NORMAL), + /* Deku nut */ DMG_ENTRY(0, GELDB_DMG_REACT_STUN), + /* Deku stick */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Slingshot */ DMG_ENTRY(1, GELDB_DMG_REACT_NORMAL), + /* Explosive */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Boomerang */ DMG_ENTRY(0, GELDB_DMG_REACT_STUN), + /* Normal arrow */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Hammer swing */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Hookshot */ DMG_ENTRY(0, GELDB_DMG_REACT_STUN), + /* Kokiri sword */ DMG_ENTRY(1, GELDB_DMG_REACT_NORMAL), + /* Master sword */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Giant's Knife */ DMG_ENTRY(4, GELDB_DMG_REACT_NORMAL), + /* Fire arrow */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Ice arrow */ DMG_ENTRY(2, GELDB_DMG_REACT_FREEZE), + /* Light arrow */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Unk arrow 1 */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Unk arrow 2 */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Unk arrow 3 */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Fire magic */ DMG_ENTRY(4, GELDB_DMG_REACT_UNK_E), + /* Ice magic */ DMG_ENTRY(0, GELDB_DMG_REACT_UNK_6), + /* Light magic */ DMG_ENTRY(3, GELDB_DMG_REACT_UNK_D), + /* Shield */ DMG_ENTRY(0, GELDB_DMG_REACT_NORMAL), + /* Mirror Ray */ DMG_ENTRY(0, GELDB_DMG_REACT_NORMAL), + /* Kokiri spin */ DMG_ENTRY(1, GELDB_DMG_REACT_NORMAL), + /* Giant spin */ DMG_ENTRY(4, GELDB_DMG_REACT_NORMAL), + /* Master spin */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Kokiri jump */ DMG_ENTRY(2, GELDB_DMG_REACT_NORMAL), + /* Giant jump */ DMG_ENTRY(8, GELDB_DMG_REACT_NORMAL), + /* Master jump */ DMG_ENTRY(4, GELDB_DMG_REACT_NORMAL), + /* Unknown 1 */ DMG_ENTRY(4, GELDB_DMG_REACT_NORMAL), + /* Unblockable */ DMG_ENTRY(0, GELDB_DMG_REACT_NORMAL), + /* Hammer jump */ DMG_ENTRY(4, GELDB_DMG_REACT_NORMAL), + /* Unknown 2 */ DMG_ENTRY(0, GELDB_DMG_REACT_NORMAL), }; static InitChainEntry sInitChain[] = { @@ -1030,10 +1030,10 @@ void EnGeldB_SetupStunned(EnGeldB* this) { if (this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) { this->actor.speed = 0.0f; } - if ((this->damageReaction != GELDB_DMG_REAC_FREEZE) || (this->action == GELDB_SPIN_ATTACK)) { + if ((this->damageReaction != GELDB_DMG_REACT_FREEZE) || (this->action == GELDB_SPIN_ATTACK)) { Animation_PlayOnceSetSpeed(&this->skelAnime, &gGerudoRedDamageAnim, 0.0f); } - if (this->damageReaction == GELDB_DMG_REAC_FREEZE) { + if (this->damageReaction == GELDB_DMG_REACT_FREEZE) { this->iceTimer = 36; } Actor_PlaySfx(&this->actor, NA_SE_EN_GOMA_JR_FREEZE); @@ -1390,12 +1390,12 @@ void EnGeldB_CollisionCheck(EnGeldB* this, PlayState* play) { } else if ((this->bodyCollider.base.acFlags & AC_HIT) && (this->action >= GELDB_READY) && (this->spinAttackState < 2)) { this->bodyCollider.base.acFlags &= ~AC_HIT; - if (this->actor.colChkInfo.damageReaction != GELDB_DMG_REAC_UNK_6) { + if (this->actor.colChkInfo.damageReaction != GELDB_DMG_REACT_UNK_6) { this->damageReaction = this->actor.colChkInfo.damageReaction; Actor_SetDropFlag(&this->actor, &this->bodyCollider.elem, true); Audio_StopSfxByPosAndId(&this->actor.projectedPos, NA_SE_EN_GERUDOFT_BREATH); - if ((this->actor.colChkInfo.damageReaction == GELDB_DMG_REAC_STUN) || - (this->actor.colChkInfo.damageReaction == GELDB_DMG_REAC_FREEZE)) { + if ((this->actor.colChkInfo.damageReaction == GELDB_DMG_REACT_STUN) || + (this->actor.colChkInfo.damageReaction == GELDB_DMG_REACT_FREEZE)) { if (this->action != GELDB_STUNNED) { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80); Actor_ApplyDamage(&this->actor); @@ -1429,7 +1429,7 @@ void EnGeldB_Update(Actor* thisx, PlayState* play) { EnGeldB* this = (EnGeldB*)thisx; EnGeldB_CollisionCheck(this, play); - if (this->actor.colChkInfo.damageReaction != GELDB_DMG_REAC_UNK_6) { + if (this->actor.colChkInfo.damageReaction != GELDB_DMG_REACT_UNK_6) { Actor_MoveXZGravity(&this->actor); Actor_UpdateBgCheckInfo(play, &this->actor, 15.0f, 30.0f, 60.0f, UPDBGCHECKINFO_FLAG_0 | UPDBGCHECKINFO_FLAG_2 | UPDBGCHECKINFO_FLAG_3 | diff --git a/src/overlays/actors/ovl_En_Ik/z_en_ik.c b/src/overlays/actors/ovl_En_Ik/z_en_ik.c index ab490283b9..690d2d29d9 100644 --- a/src/overlays/actors/ovl_En_Ik/z_en_ik.c +++ b/src/overlays/actors/ovl_En_Ik/z_en_ik.c @@ -53,11 +53,11 @@ typedef enum EnIkCsDrawMode { } EnIkCsDrawMode; typedef enum EnIkDamageReaction { - /* 0x0 */ EN_IK_DMG_REAC_NONE, - /* 0x6 */ EN_IK_DMG_REAC_ELEMENTAL_MAGIC = 0x6, - /* 0xD */ EN_IK_DMG_REAC_SPARKS_NO_DMG = 0xD, - /* 0xE */ EN_IK_DMG_REAC_PROJECTILE, - /* 0xF */ EN_IK_DMG_REAC_DAMAGE + /* 0x0 */ EN_IK_DMG_REACT_NONE, + /* 0x6 */ EN_IK_DMG_REACT_ELEMENTAL_MAGIC = 0x6, + /* 0xD */ EN_IK_DMG_REACT_SPARKS_NO_DMG = 0xD, + /* 0xE */ EN_IK_DMG_REACT_PROJECTILE, + /* 0xF */ EN_IK_DMG_REACT_DAMAGE } EnIkDamageReaction; void EnIk_UpdateEnemy(Actor* thisx, PlayState* play); @@ -166,38 +166,38 @@ static ColliderQuadInit sQuadInit = { }; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, EN_IK_DMG_REAC_SPARKS_NO_DMG), - /* Deku stick */ DMG_ENTRY(2, EN_IK_DMG_REAC_DAMAGE), - /* Slingshot */ DMG_ENTRY(1, EN_IK_DMG_REAC_PROJECTILE), - /* Explosive */ DMG_ENTRY(2, EN_IK_DMG_REAC_DAMAGE), - /* Boomerang */ DMG_ENTRY(0, EN_IK_DMG_REAC_SPARKS_NO_DMG), - /* Normal arrow */ DMG_ENTRY(2, EN_IK_DMG_REAC_PROJECTILE), - /* Hammer swing */ DMG_ENTRY(2, EN_IK_DMG_REAC_DAMAGE), - /* Hookshot */ DMG_ENTRY(0, EN_IK_DMG_REAC_SPARKS_NO_DMG), - /* Kokiri sword */ DMG_ENTRY(1, EN_IK_DMG_REAC_DAMAGE), - /* Master sword */ DMG_ENTRY(2, EN_IK_DMG_REAC_DAMAGE), - /* Giant's Knife */ DMG_ENTRY(4, EN_IK_DMG_REAC_DAMAGE), - /* Fire arrow */ DMG_ENTRY(2, EN_IK_DMG_REAC_PROJECTILE), - /* Ice arrow */ DMG_ENTRY(2, EN_IK_DMG_REAC_PROJECTILE), - /* Light arrow */ DMG_ENTRY(2, EN_IK_DMG_REAC_PROJECTILE), - /* Unk arrow 1 */ DMG_ENTRY(2, EN_IK_DMG_REAC_PROJECTILE), - /* Unk arrow 2 */ DMG_ENTRY(2, EN_IK_DMG_REAC_PROJECTILE), - /* Unk arrow 3 */ DMG_ENTRY(15, EN_IK_DMG_REAC_PROJECTILE), - /* Fire magic */ DMG_ENTRY(0, EN_IK_DMG_REAC_ELEMENTAL_MAGIC), - /* Ice magic */ DMG_ENTRY(0, EN_IK_DMG_REAC_ELEMENTAL_MAGIC), - /* Light magic */ DMG_ENTRY(0, EN_IK_DMG_REAC_ELEMENTAL_MAGIC), - /* Shield */ DMG_ENTRY(0, EN_IK_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, EN_IK_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, EN_IK_DMG_REAC_DAMAGE), - /* Giant spin */ DMG_ENTRY(4, EN_IK_DMG_REAC_DAMAGE), - /* Master spin */ DMG_ENTRY(2, EN_IK_DMG_REAC_DAMAGE), - /* Kokiri jump */ DMG_ENTRY(2, EN_IK_DMG_REAC_DAMAGE), - /* Giant jump */ DMG_ENTRY(8, EN_IK_DMG_REAC_DAMAGE), - /* Master jump */ DMG_ENTRY(4, EN_IK_DMG_REAC_DAMAGE), - /* Unknown 1 */ DMG_ENTRY(10, EN_IK_DMG_REAC_DAMAGE), - /* Unblockable */ DMG_ENTRY(0, EN_IK_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, EN_IK_DMG_REAC_DAMAGE), - /* Unknown 2 */ DMG_ENTRY(0, EN_IK_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, EN_IK_DMG_REACT_SPARKS_NO_DMG), + /* Deku stick */ DMG_ENTRY(2, EN_IK_DMG_REACT_DAMAGE), + /* Slingshot */ DMG_ENTRY(1, EN_IK_DMG_REACT_PROJECTILE), + /* Explosive */ DMG_ENTRY(2, EN_IK_DMG_REACT_DAMAGE), + /* Boomerang */ DMG_ENTRY(0, EN_IK_DMG_REACT_SPARKS_NO_DMG), + /* Normal arrow */ DMG_ENTRY(2, EN_IK_DMG_REACT_PROJECTILE), + /* Hammer swing */ DMG_ENTRY(2, EN_IK_DMG_REACT_DAMAGE), + /* Hookshot */ DMG_ENTRY(0, EN_IK_DMG_REACT_SPARKS_NO_DMG), + /* Kokiri sword */ DMG_ENTRY(1, EN_IK_DMG_REACT_DAMAGE), + /* Master sword */ DMG_ENTRY(2, EN_IK_DMG_REACT_DAMAGE), + /* Giant's Knife */ DMG_ENTRY(4, EN_IK_DMG_REACT_DAMAGE), + /* Fire arrow */ DMG_ENTRY(2, EN_IK_DMG_REACT_PROJECTILE), + /* Ice arrow */ DMG_ENTRY(2, EN_IK_DMG_REACT_PROJECTILE), + /* Light arrow */ DMG_ENTRY(2, EN_IK_DMG_REACT_PROJECTILE), + /* Unk arrow 1 */ DMG_ENTRY(2, EN_IK_DMG_REACT_PROJECTILE), + /* Unk arrow 2 */ DMG_ENTRY(2, EN_IK_DMG_REACT_PROJECTILE), + /* Unk arrow 3 */ DMG_ENTRY(15, EN_IK_DMG_REACT_PROJECTILE), + /* Fire magic */ DMG_ENTRY(0, EN_IK_DMG_REACT_ELEMENTAL_MAGIC), + /* Ice magic */ DMG_ENTRY(0, EN_IK_DMG_REACT_ELEMENTAL_MAGIC), + /* Light magic */ DMG_ENTRY(0, EN_IK_DMG_REACT_ELEMENTAL_MAGIC), + /* Shield */ DMG_ENTRY(0, EN_IK_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, EN_IK_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, EN_IK_DMG_REACT_DAMAGE), + /* Giant spin */ DMG_ENTRY(4, EN_IK_DMG_REACT_DAMAGE), + /* Master spin */ DMG_ENTRY(2, EN_IK_DMG_REACT_DAMAGE), + /* Kokiri jump */ DMG_ENTRY(2, EN_IK_DMG_REACT_DAMAGE), + /* Giant jump */ DMG_ENTRY(8, EN_IK_DMG_REACT_DAMAGE), + /* Master jump */ DMG_ENTRY(4, EN_IK_DMG_REACT_DAMAGE), + /* Unknown 1 */ DMG_ENTRY(10, EN_IK_DMG_REACT_DAMAGE), + /* Unblockable */ DMG_ENTRY(0, EN_IK_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, EN_IK_DMG_REACT_DAMAGE), + /* Unknown 2 */ DMG_ENTRY(0, EN_IK_DMG_REACT_NONE), }; void EnIk_Destroy(Actor* thisx, PlayState* play) { @@ -757,9 +757,9 @@ void EnIk_UpdateDamage(EnIk* this, PlayState* play) { this->damageReaction = this->actor.colChkInfo.damageReaction; this->bodyCollider.base.acFlags &= ~AC_HIT; - if ((this->damageReaction == EN_IK_DMG_REAC_NONE) || (this->damageReaction == EN_IK_DMG_REAC_SPARKS_NO_DMG) || - ((this->armorStatusFlag == 0) && (this->damageReaction == EN_IK_DMG_REAC_PROJECTILE))) { - if (this->damageReaction != EN_IK_DMG_REAC_NONE) { + if ((this->damageReaction == EN_IK_DMG_REACT_NONE) || (this->damageReaction == EN_IK_DMG_REACT_SPARKS_NO_DMG) || + ((this->armorStatusFlag == 0) && (this->damageReaction == EN_IK_DMG_REACT_PROJECTILE))) { + if (this->damageReaction != EN_IK_DMG_REACT_NONE) { // spawn sparks and don't damage CollisionCheck_SpawnShieldParticlesMetal(play, &sparksPos); } diff --git a/src/overlays/actors/ovl_En_Mb/z_en_mb.c b/src/overlays/actors/ovl_En_Mb/z_en_mb.c index d0a17ef703..a2700bd6b5 100644 --- a/src/overlays/actors/ovl_En_Mb/z_en_mb.c +++ b/src/overlays/actors/ovl_En_Mb/z_en_mb.c @@ -185,81 +185,81 @@ static ColliderQuadInit sAttackColliderQuadInit = { }; typedef enum EnMbDamageReaction { - /* 0x0 */ ENMB_DMG_REAC_IGNORE, - /* 0x1 */ ENMB_DMG_REAC_STUN, - /* 0x5 */ ENMB_DMG_REAC_FREEZE = 0x5, - /* 0x6 */ ENMB_DMG_REAC_STUN_ICE, - /* 0xF */ ENMB_DMG_REAC_DEFAULT = 0xF + /* 0x0 */ ENMB_DMG_REACT_IGNORE, + /* 0x1 */ ENMB_DMG_REACT_STUN, + /* 0x5 */ ENMB_DMG_REACT_FREEZE = 0x5, + /* 0x6 */ ENMB_DMG_REACT_STUN_ICE, + /* 0xF */ ENMB_DMG_REACT_DEFAULT = 0xF } EnMbDamageReaction; static DamageTable sSpearMoblinDamageTable = { - /* Deku nut */ DMG_ENTRY(0, ENMB_DMG_REAC_FREEZE), - /* Deku stick */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Slingshot */ DMG_ENTRY(1, ENMB_DMG_REAC_DEFAULT), - /* Explosive */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Boomerang */ DMG_ENTRY(0, ENMB_DMG_REAC_STUN), - /* Normal arrow */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Hammer swing */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Hookshot */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Kokiri sword */ DMG_ENTRY(1, ENMB_DMG_REAC_DEFAULT), - /* Master sword */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Giant's Knife */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Fire arrow */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Ice arrow */ DMG_ENTRY(4, ENMB_DMG_REAC_STUN_ICE), - /* Light arrow */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Unk arrow 1 */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Unk arrow 2 */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Unk arrow 3 */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Fire magic */ DMG_ENTRY(0, ENMB_DMG_REAC_FREEZE), - /* Ice magic */ DMG_ENTRY(3, ENMB_DMG_REAC_STUN_ICE), - /* Light magic */ DMG_ENTRY(0, ENMB_DMG_REAC_FREEZE), - /* Shield */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), - /* Mirror Ray */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), - /* Kokiri spin */ DMG_ENTRY(1, ENMB_DMG_REAC_DEFAULT), - /* Giant spin */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Master spin */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Kokiri jump */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Giant jump */ DMG_ENTRY(8, ENMB_DMG_REAC_DEFAULT), - /* Master jump */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Unknown 1 */ DMG_ENTRY(0, ENMB_DMG_REAC_FREEZE), - /* Unblockable */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), - /* Hammer jump */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Unknown 2 */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), + /* Deku nut */ DMG_ENTRY(0, ENMB_DMG_REACT_FREEZE), + /* Deku stick */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Slingshot */ DMG_ENTRY(1, ENMB_DMG_REACT_DEFAULT), + /* Explosive */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Boomerang */ DMG_ENTRY(0, ENMB_DMG_REACT_STUN), + /* Normal arrow */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Hammer swing */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Hookshot */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Kokiri sword */ DMG_ENTRY(1, ENMB_DMG_REACT_DEFAULT), + /* Master sword */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Giant's Knife */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Fire arrow */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Ice arrow */ DMG_ENTRY(4, ENMB_DMG_REACT_STUN_ICE), + /* Light arrow */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Unk arrow 1 */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Unk arrow 2 */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Unk arrow 3 */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Fire magic */ DMG_ENTRY(0, ENMB_DMG_REACT_FREEZE), + /* Ice magic */ DMG_ENTRY(3, ENMB_DMG_REACT_STUN_ICE), + /* Light magic */ DMG_ENTRY(0, ENMB_DMG_REACT_FREEZE), + /* Shield */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), + /* Mirror Ray */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), + /* Kokiri spin */ DMG_ENTRY(1, ENMB_DMG_REACT_DEFAULT), + /* Giant spin */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Master spin */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Kokiri jump */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Giant jump */ DMG_ENTRY(8, ENMB_DMG_REACT_DEFAULT), + /* Master jump */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Unknown 1 */ DMG_ENTRY(0, ENMB_DMG_REACT_FREEZE), + /* Unblockable */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), + /* Hammer jump */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Unknown 2 */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), }; static DamageTable sClubMoblinDamageTable = { - /* Deku nut */ DMG_ENTRY(0, ENMB_DMG_REAC_FREEZE), - /* Deku stick */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Slingshot */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), - /* Explosive */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Boomerang */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), - /* Normal arrow */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Hammer swing */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Hookshot */ DMG_ENTRY(0, ENMB_DMG_REAC_STUN), - /* Kokiri sword */ DMG_ENTRY(1, ENMB_DMG_REAC_DEFAULT), - /* Master sword */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Giant's Knife */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Fire arrow */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Ice arrow */ DMG_ENTRY(4, ENMB_DMG_REAC_STUN_ICE), - /* Light arrow */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Unk arrow 1 */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Unk arrow 2 */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Unk arrow 3 */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Fire magic */ DMG_ENTRY(0, ENMB_DMG_REAC_FREEZE), - /* Ice magic */ DMG_ENTRY(3, ENMB_DMG_REAC_STUN_ICE), - /* Light magic */ DMG_ENTRY(0, ENMB_DMG_REAC_FREEZE), - /* Shield */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), - /* Mirror Ray */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), - /* Kokiri spin */ DMG_ENTRY(1, ENMB_DMG_REAC_DEFAULT), - /* Giant spin */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Master spin */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Kokiri jump */ DMG_ENTRY(2, ENMB_DMG_REAC_DEFAULT), - /* Giant jump */ DMG_ENTRY(8, ENMB_DMG_REAC_DEFAULT), - /* Master jump */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Unknown 1 */ DMG_ENTRY(0, ENMB_DMG_REAC_FREEZE), - /* Unblockable */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), - /* Hammer jump */ DMG_ENTRY(4, ENMB_DMG_REAC_DEFAULT), - /* Unknown 2 */ DMG_ENTRY(0, ENMB_DMG_REAC_IGNORE), + /* Deku nut */ DMG_ENTRY(0, ENMB_DMG_REACT_FREEZE), + /* Deku stick */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Slingshot */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), + /* Explosive */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Boomerang */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), + /* Normal arrow */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Hammer swing */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Hookshot */ DMG_ENTRY(0, ENMB_DMG_REACT_STUN), + /* Kokiri sword */ DMG_ENTRY(1, ENMB_DMG_REACT_DEFAULT), + /* Master sword */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Giant's Knife */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Fire arrow */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Ice arrow */ DMG_ENTRY(4, ENMB_DMG_REACT_STUN_ICE), + /* Light arrow */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Unk arrow 1 */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Unk arrow 2 */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Unk arrow 3 */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Fire magic */ DMG_ENTRY(0, ENMB_DMG_REACT_FREEZE), + /* Ice magic */ DMG_ENTRY(3, ENMB_DMG_REACT_STUN_ICE), + /* Light magic */ DMG_ENTRY(0, ENMB_DMG_REACT_FREEZE), + /* Shield */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), + /* Mirror Ray */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), + /* Kokiri spin */ DMG_ENTRY(1, ENMB_DMG_REACT_DEFAULT), + /* Giant spin */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Master spin */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Kokiri jump */ DMG_ENTRY(2, ENMB_DMG_REACT_DEFAULT), + /* Giant jump */ DMG_ENTRY(8, ENMB_DMG_REACT_DEFAULT), + /* Master jump */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Unknown 1 */ DMG_ENTRY(0, ENMB_DMG_REACT_FREEZE), + /* Unblockable */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), + /* Hammer jump */ DMG_ENTRY(4, ENMB_DMG_REACT_DEFAULT), + /* Unknown 2 */ DMG_ENTRY(0, ENMB_DMG_REACT_IGNORE), }; static InitChainEntry sInitChain[] = { @@ -605,7 +605,7 @@ void EnMb_SetupStunned(EnMb* this) { this->state = ENMB_STATE_STUNNED; this->actor.speed = 0.0f; Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80); - if (this->damageReaction == ENMB_DMG_REAC_STUN_ICE) { + if (this->damageReaction == ENMB_DMG_REACT_STUN_ICE) { this->iceEffectTimer = 40; } else { if (this->actor.params != ENMB_TYPE_CLUB) { @@ -1440,8 +1440,8 @@ void EnMb_CheckColliding(EnMb* this, PlayState* play) { this->bodyCollider.base.acFlags &= ~AC_HIT; } else if ((this->bodyCollider.base.acFlags & AC_HIT) && this->state >= ENMB_STATE_STUNNED) { this->bodyCollider.base.acFlags &= ~AC_HIT; - if (this->actor.colChkInfo.damageReaction != ENMB_DMG_REAC_IGNORE && - this->actor.colChkInfo.damageReaction != ENMB_DMG_REAC_FREEZE) { + if (this->actor.colChkInfo.damageReaction != ENMB_DMG_REACT_IGNORE && + this->actor.colChkInfo.damageReaction != ENMB_DMG_REACT_FREEZE) { if ((player->stateFlags2 & PLAYER_STATE2_7) && player->actor.parent == &this->actor) { player->stateFlags2 &= ~PLAYER_STATE2_7; player->actor.parent = NULL; @@ -1453,8 +1453,8 @@ void EnMb_CheckColliding(EnMb* this, PlayState* play) { this->damageReaction = this->actor.colChkInfo.damageReaction; this->attack = ENMB_ATTACK_NONE; Actor_SetDropFlag(&this->actor, &this->bodyCollider.elem, false); - if (this->actor.colChkInfo.damageReaction == ENMB_DMG_REAC_STUN || - this->actor.colChkInfo.damageReaction == ENMB_DMG_REAC_STUN_ICE) { + if (this->actor.colChkInfo.damageReaction == ENMB_DMG_REACT_STUN || + this->actor.colChkInfo.damageReaction == ENMB_DMG_REACT_STUN_ICE) { if (this->state != ENMB_STATE_STUNNED) { Actor_ApplyDamage(&this->actor); EnMb_SetupStunned(this); @@ -1485,7 +1485,7 @@ void EnMb_Update(Actor* thisx, PlayState* play) { s32 pad; EnMb_CheckColliding(this, play); - if (thisx->colChkInfo.damageReaction != ENMB_DMG_REAC_FREEZE) { + if (thisx->colChkInfo.damageReaction != ENMB_DMG_REACT_FREEZE) { this->actionFunc(this, play); Actor_MoveXZGravity(thisx); Actor_UpdateBgCheckInfo(play, thisx, 40.0f, 40.0f, 70.0f, diff --git a/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c b/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c index 882200362d..ec59725c25 100644 --- a/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c +++ b/src/overlays/actors/ovl_En_Peehat/z_en_peehat.c @@ -138,47 +138,47 @@ static ColliderQuadInit sQuadInit = { }; typedef enum EnPeehatDamageReaction { - /* 00 */ PEAHAT_DMG_REAC_ATTACK = 0, - /* 06 */ PEAHAT_DMG_REAC_LIGHT_ICE_ARROW = 6, - /* 12 */ PEAHAT_DMG_REAC_FIRE = 12, - /* 13 */ PEAHAT_DMG_REAC_HOOKSHOT = 13, - /* 14 */ PEAHAT_DMG_REAC_BOOMERANG = 14, - /* 15 */ PEAHAT_DMG_REAC_NUT = 15 + /* 00 */ PEAHAT_DMG_REACT_ATTACK = 0, + /* 06 */ PEAHAT_DMG_REACT_LIGHT_ICE_ARROW = 6, + /* 12 */ PEAHAT_DMG_REACT_FIRE = 12, + /* 13 */ PEAHAT_DMG_REACT_HOOKSHOT = 13, + /* 14 */ PEAHAT_DMG_REACT_BOOMERANG = 14, + /* 15 */ PEAHAT_DMG_REACT_NUT = 15 } EnPeehatDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, PEAHAT_DMG_REAC_NUT), - /* Deku stick */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Slingshot */ DMG_ENTRY(1, PEAHAT_DMG_REAC_ATTACK), - /* Explosive */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Boomerang */ DMG_ENTRY(0, PEAHAT_DMG_REAC_BOOMERANG), - /* Normal arrow */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Hammer swing */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Hookshot */ DMG_ENTRY(2, PEAHAT_DMG_REAC_HOOKSHOT), - /* Kokiri sword */ DMG_ENTRY(1, PEAHAT_DMG_REAC_ATTACK), - /* Master sword */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Giant's Knife */ DMG_ENTRY(4, PEAHAT_DMG_REAC_ATTACK), - /* Fire arrow */ DMG_ENTRY(4, PEAHAT_DMG_REAC_FIRE), - /* Ice arrow */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Light arrow */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Unk arrow 1 */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Unk arrow 2 */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Unk arrow 3 */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Fire magic */ DMG_ENTRY(3, PEAHAT_DMG_REAC_FIRE), - /* Ice magic */ DMG_ENTRY(0, PEAHAT_DMG_REAC_LIGHT_ICE_ARROW), - /* Light magic */ DMG_ENTRY(0, PEAHAT_DMG_REAC_LIGHT_ICE_ARROW), - /* Shield */ DMG_ENTRY(0, PEAHAT_DMG_REAC_ATTACK), - /* Mirror Ray */ DMG_ENTRY(0, PEAHAT_DMG_REAC_ATTACK), - /* Kokiri spin */ DMG_ENTRY(1, PEAHAT_DMG_REAC_ATTACK), - /* Giant spin */ DMG_ENTRY(4, PEAHAT_DMG_REAC_ATTACK), - /* Master spin */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Kokiri jump */ DMG_ENTRY(2, PEAHAT_DMG_REAC_ATTACK), - /* Giant jump */ DMG_ENTRY(8, PEAHAT_DMG_REAC_ATTACK), - /* Master jump */ DMG_ENTRY(4, PEAHAT_DMG_REAC_ATTACK), - /* Unknown 1 */ DMG_ENTRY(0, PEAHAT_DMG_REAC_ATTACK), - /* Unblockable */ DMG_ENTRY(0, PEAHAT_DMG_REAC_ATTACK), - /* Hammer jump */ DMG_ENTRY(4, PEAHAT_DMG_REAC_ATTACK), - /* Unknown 2 */ DMG_ENTRY(0, PEAHAT_DMG_REAC_ATTACK), + /* Deku nut */ DMG_ENTRY(0, PEAHAT_DMG_REACT_NUT), + /* Deku stick */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Slingshot */ DMG_ENTRY(1, PEAHAT_DMG_REACT_ATTACK), + /* Explosive */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Boomerang */ DMG_ENTRY(0, PEAHAT_DMG_REACT_BOOMERANG), + /* Normal arrow */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Hammer swing */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Hookshot */ DMG_ENTRY(2, PEAHAT_DMG_REACT_HOOKSHOT), + /* Kokiri sword */ DMG_ENTRY(1, PEAHAT_DMG_REACT_ATTACK), + /* Master sword */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Giant's Knife */ DMG_ENTRY(4, PEAHAT_DMG_REACT_ATTACK), + /* Fire arrow */ DMG_ENTRY(4, PEAHAT_DMG_REACT_FIRE), + /* Ice arrow */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Light arrow */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Unk arrow 1 */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Unk arrow 2 */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Unk arrow 3 */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Fire magic */ DMG_ENTRY(3, PEAHAT_DMG_REACT_FIRE), + /* Ice magic */ DMG_ENTRY(0, PEAHAT_DMG_REACT_LIGHT_ICE_ARROW), + /* Light magic */ DMG_ENTRY(0, PEAHAT_DMG_REACT_LIGHT_ICE_ARROW), + /* Shield */ DMG_ENTRY(0, PEAHAT_DMG_REACT_ATTACK), + /* Mirror Ray */ DMG_ENTRY(0, PEAHAT_DMG_REACT_ATTACK), + /* Kokiri spin */ DMG_ENTRY(1, PEAHAT_DMG_REACT_ATTACK), + /* Giant spin */ DMG_ENTRY(4, PEAHAT_DMG_REACT_ATTACK), + /* Master spin */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Kokiri jump */ DMG_ENTRY(2, PEAHAT_DMG_REACT_ATTACK), + /* Giant jump */ DMG_ENTRY(8, PEAHAT_DMG_REACT_ATTACK), + /* Master jump */ DMG_ENTRY(4, PEAHAT_DMG_REACT_ATTACK), + /* Unknown 1 */ DMG_ENTRY(0, PEAHAT_DMG_REACT_ATTACK), + /* Unblockable */ DMG_ENTRY(0, PEAHAT_DMG_REACT_ATTACK), + /* Hammer jump */ DMG_ENTRY(4, PEAHAT_DMG_REACT_ATTACK), + /* Unknown 2 */ DMG_ENTRY(0, PEAHAT_DMG_REACT_ATTACK), }; typedef enum PeahatState { @@ -902,13 +902,13 @@ void EnPeehat_Adult_CollisionCheck(EnPeehat* this, PlayState* play) { } else if (this->colliderJntSph.base.acFlags & AC_HIT) { this->colliderJntSph.base.acFlags &= ~AC_HIT; Actor_SetDropFlagJntSph(&this->actor, &this->colliderJntSph, true); - if (this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REAC_NUT || - this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REAC_LIGHT_ICE_ARROW) { + if (this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REACT_NUT || + this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REACT_LIGHT_ICE_ARROW) { return; } - if (this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REAC_HOOKSHOT) { + if (this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REACT_HOOKSHOT) { this->actor.colChkInfo.health = 0; - } else if (this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REAC_BOOMERANG) { + } else if (this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REACT_BOOMERANG) { if (this->state != PEAHAT_STATE_STUNNED) { EnPeehat_SetStateBoomerangStunned(this); } @@ -919,7 +919,7 @@ void EnPeehat_Adult_CollisionCheck(EnPeehat* this, PlayState* play) { Actor_PlaySfx(&this->actor, NA_SE_EN_PIHAT_DAMAGE); } - if (this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REAC_FIRE) { + if (this->actor.colChkInfo.damageReaction == PEAHAT_DMG_REACT_FIRE) { Vec3f pos; s32 i; for (i = 4; i >= 0; i--) { @@ -949,7 +949,7 @@ void EnPeehat_Update(Actor* thisx, PlayState* play) { if (thisx->params <= 0) { EnPeehat_Adult_CollisionCheck(this, play); } - if (thisx->colChkInfo.damageReaction != PEAHAT_DMG_REAC_LIGHT_ICE_ARROW) { + if (thisx->colChkInfo.damageReaction != PEAHAT_DMG_REACT_LIGHT_ICE_ARROW) { if (thisx->speed != 0.0f || thisx->velocity.y != 0.0f) { Actor_MoveXZGravity(thisx); Actor_UpdateBgCheckInfo(play, thisx, 25.0f, 30.0f, 30.0f, UPDBGCHECKINFO_FLAG_0 | UPDBGCHECKINFO_FLAG_2); diff --git a/src/overlays/actors/ovl_En_Rd/z_en_rd.c b/src/overlays/actors/ovl_En_Rd/z_en_rd.c index 9ed28aab8c..e1fea6292a 100644 --- a/src/overlays/actors/ovl_En_Rd/z_en_rd.c +++ b/src/overlays/actors/ovl_En_Rd/z_en_rd.c @@ -109,47 +109,47 @@ static ColliderCylinderInit sCylinderInit = { }; typedef enum EnRdDamageReaction { - /* 0x0 */ REDEAD_DMG_REAC_NONE, // Does not interact with the Gibdo/Redead at all - /* 0x1 */ REDEAD_DMG_REAC_HOOKSHOT, // Stuns the Gibdo/Redead - /* 0x6 */ REDEAD_DMG_REAC_ICE_MAGIC = 0x6, // Does not interact with the Gibdo/Redead at all - /* 0xD */ REDEAD_DMG_REAC_LIGHT_MAGIC = 0xD, // Stuns the Gibdo/Redead - /* 0xE */ REDEAD_DMG_REAC_FIRE_MAGIC, // Applies a fire effect - /* 0xF */ REDEAD_DMG_REAC_DAMAGE // Deals damage without stunning or applying an effect + /* 0x0 */ REDEAD_DMG_REACT_NONE, // Does not interact with the Gibdo/Redead at all + /* 0x1 */ REDEAD_DMG_REACT_HOOKSHOT, // Stuns the Gibdo/Redead + /* 0x6 */ REDEAD_DMG_REACT_ICE_MAGIC = 0x6, // Does not interact with the Gibdo/Redead at all + /* 0xD */ REDEAD_DMG_REACT_LIGHT_MAGIC = 0xD, // Stuns the Gibdo/Redead + /* 0xE */ REDEAD_DMG_REACT_FIRE_MAGIC, // Applies a fire effect + /* 0xF */ REDEAD_DMG_REACT_DAMAGE // Deals damage without stunning or applying an effect } EnRdDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Deku stick */ DMG_ENTRY(2, REDEAD_DMG_REAC_DAMAGE), - /* Slingshot */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Explosive */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Boomerang */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Normal arrow */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Hammer swing */ DMG_ENTRY(2, REDEAD_DMG_REAC_DAMAGE), - /* Hookshot */ DMG_ENTRY(0, REDEAD_DMG_REAC_HOOKSHOT), - /* Kokiri sword */ DMG_ENTRY(1, REDEAD_DMG_REAC_DAMAGE), - /* Master sword */ DMG_ENTRY(2, REDEAD_DMG_REAC_DAMAGE), - /* Giant's Knife */ DMG_ENTRY(4, REDEAD_DMG_REAC_DAMAGE), - /* Fire arrow */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Ice arrow */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Light arrow */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Unk arrow 1 */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Unk arrow 2 */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Unk arrow 3 */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Fire magic */ DMG_ENTRY(4, REDEAD_DMG_REAC_FIRE_MAGIC), - /* Ice magic */ DMG_ENTRY(0, REDEAD_DMG_REAC_ICE_MAGIC), - /* Light magic */ DMG_ENTRY(3, REDEAD_DMG_REAC_LIGHT_MAGIC), - /* Shield */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, REDEAD_DMG_REAC_DAMAGE), - /* Giant spin */ DMG_ENTRY(4, REDEAD_DMG_REAC_DAMAGE), - /* Master spin */ DMG_ENTRY(2, REDEAD_DMG_REAC_DAMAGE), - /* Kokiri jump */ DMG_ENTRY(2, REDEAD_DMG_REAC_DAMAGE), - /* Giant jump */ DMG_ENTRY(8, REDEAD_DMG_REAC_DAMAGE), - /* Master jump */ DMG_ENTRY(4, REDEAD_DMG_REAC_DAMAGE), - /* Unknown 1 */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, REDEAD_DMG_REAC_DAMAGE), - /* Unknown 2 */ DMG_ENTRY(0, REDEAD_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Deku stick */ DMG_ENTRY(2, REDEAD_DMG_REACT_DAMAGE), + /* Slingshot */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Explosive */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Boomerang */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Normal arrow */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Hammer swing */ DMG_ENTRY(2, REDEAD_DMG_REACT_DAMAGE), + /* Hookshot */ DMG_ENTRY(0, REDEAD_DMG_REACT_HOOKSHOT), + /* Kokiri sword */ DMG_ENTRY(1, REDEAD_DMG_REACT_DAMAGE), + /* Master sword */ DMG_ENTRY(2, REDEAD_DMG_REACT_DAMAGE), + /* Giant's Knife */ DMG_ENTRY(4, REDEAD_DMG_REACT_DAMAGE), + /* Fire arrow */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Ice arrow */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Light arrow */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Unk arrow 1 */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Unk arrow 2 */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Unk arrow 3 */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Fire magic */ DMG_ENTRY(4, REDEAD_DMG_REACT_FIRE_MAGIC), + /* Ice magic */ DMG_ENTRY(0, REDEAD_DMG_REACT_ICE_MAGIC), + /* Light magic */ DMG_ENTRY(3, REDEAD_DMG_REACT_LIGHT_MAGIC), + /* Shield */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, REDEAD_DMG_REACT_DAMAGE), + /* Giant spin */ DMG_ENTRY(4, REDEAD_DMG_REACT_DAMAGE), + /* Master spin */ DMG_ENTRY(2, REDEAD_DMG_REACT_DAMAGE), + /* Kokiri jump */ DMG_ENTRY(2, REDEAD_DMG_REACT_DAMAGE), + /* Giant jump */ DMG_ENTRY(8, REDEAD_DMG_REACT_DAMAGE), + /* Master jump */ DMG_ENTRY(4, REDEAD_DMG_REACT_DAMAGE), + /* Unknown 1 */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, REDEAD_DMG_REACT_DAMAGE), + /* Unknown 2 */ DMG_ENTRY(0, REDEAD_DMG_REACT_NONE), }; static InitChainEntry sInitChain[] = { @@ -768,7 +768,7 @@ void EnRd_SetupStunned(EnRd* this) { Actor_PlaySfx(&this->actor, NA_SE_EN_LIGHT_ARROW_HIT); Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, COLORFILTER_INTENSITY_FLAG | 200, COLORFILTER_BUFFLAG_OPA, 255); - } else if (this->damageReaction == REDEAD_DMG_REAC_HOOKSHOT) { + } else if (this->damageReaction == REDEAD_DMG_REACT_HOOKSHOT) { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 200, COLORFILTER_BUFFLAG_OPA, 80); } else { Actor_PlaySfx(&this->actor, NA_SE_EN_LIGHT_ARROW_HIT); @@ -843,9 +843,9 @@ void EnRd_UpdateDamage(EnRd* this, PlayState* play) { this->unk_31D = player->unk_845; } - if ((this->damageReaction != REDEAD_DMG_REAC_NONE) && (this->damageReaction != REDEAD_DMG_REAC_ICE_MAGIC)) { - if (((this->damageReaction == REDEAD_DMG_REAC_HOOKSHOT) || - (this->damageReaction == REDEAD_DMG_REAC_LIGHT_MAGIC)) && + if ((this->damageReaction != REDEAD_DMG_REACT_NONE) && (this->damageReaction != REDEAD_DMG_REACT_ICE_MAGIC)) { + if (((this->damageReaction == REDEAD_DMG_REACT_HOOKSHOT) || + (this->damageReaction == REDEAD_DMG_REACT_LIGHT_MAGIC)) && (this->action != REDEAD_ACTION_STUNNED)) { Actor_ApplyDamage(&this->actor); EnRd_SetupStunned(this); @@ -855,7 +855,7 @@ void EnRd_UpdateDamage(EnRd* this, PlayState* play) { this->stunnedBySunsSong = false; this->sunsSongStunTimer = 0; - if (this->damageReaction == REDEAD_DMG_REAC_FIRE_MAGIC) { + if (this->damageReaction == REDEAD_DMG_REACT_FIRE_MAGIC) { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 80); this->fireTimer = 40; } else { @@ -887,8 +887,8 @@ void EnRd_Update(Actor* thisx, PlayState* play) { gSaveContext.sunsSongState = SUNSSONG_INACTIVE; } - if (this->damageReaction != REDEAD_DMG_REAC_ICE_MAGIC && - ((this->action != REDEAD_ACTION_RISE_FROM_COFFIN) || (this->damageReaction != REDEAD_DMG_REAC_FIRE_MAGIC))) { + if (this->damageReaction != REDEAD_DMG_REACT_ICE_MAGIC && + ((this->action != REDEAD_ACTION_RISE_FROM_COFFIN) || (this->damageReaction != REDEAD_DMG_REACT_FIRE_MAGIC))) { if (this->playerStunWaitTimer != 0) { this->playerStunWaitTimer--; } diff --git a/src/overlays/actors/ovl_En_Reeba/z_en_reeba.c b/src/overlays/actors/ovl_En_Reeba/z_en_reeba.c index 98ac2530d0..fe78b085c4 100644 --- a/src/overlays/actors/ovl_En_Reeba/z_en_reeba.c +++ b/src/overlays/actors/ovl_En_Reeba/z_en_reeba.c @@ -49,48 +49,48 @@ void EnReeba_Stunned(EnReeba* this, PlayState* play); void EnReeba_StunDie(EnReeba* this, PlayState* play); typedef enum LeeverDamageReaction { - /* 0x00 */ LEEVER_DMG_REAC_NONE, // used by anything that cant kill the Leever - /* 0x01 */ LEEVER_DMG_REAC_UNK, // used by "unknown 1" attack - /* 0x03 */ LEEVER_DMG_REAC_ICE = 3, - /* 0x0B */ LEEVER_DMG_REAC_UNUSED = 11, // not used in the damage table, but still checked for. - /* 0x0C */ LEEVER_DMG_REAC_BOOMERANG, - /* 0x0D */ LEEVER_DMG_REAC_HOOKSHOT, - /* 0x0E */ LEEVER_DMG_REAC_OTHER + /* 0x00 */ LEEVER_DMG_REACT_NONE, // used by anything that cant kill the Leever + /* 0x01 */ LEEVER_DMG_REACT_UNK, // used by "unknown 1" attack + /* 0x03 */ LEEVER_DMG_REACT_ICE = 3, + /* 0x0B */ LEEVER_DMG_REACT_UNUSED = 11, // not used in the damage table, but still checked for. + /* 0x0C */ LEEVER_DMG_REACT_BOOMERANG, + /* 0x0D */ LEEVER_DMG_REACT_HOOKSHOT, + /* 0x0E */ LEEVER_DMG_REACT_OTHER } LeeverDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, LEEVER_DMG_REAC_NONE), - /* Deku stick */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Slingshot */ DMG_ENTRY(1, LEEVER_DMG_REAC_OTHER), - /* Explosive */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Boomerang */ DMG_ENTRY(1, LEEVER_DMG_REAC_BOOMERANG), - /* Normal arrow */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Hammer swing */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Hookshot */ DMG_ENTRY(2, LEEVER_DMG_REAC_HOOKSHOT), - /* Kokiri sword */ DMG_ENTRY(1, LEEVER_DMG_REAC_OTHER), - /* Master sword */ DMG_ENTRY(4, LEEVER_DMG_REAC_OTHER), - /* Giant's Knife */ DMG_ENTRY(6, LEEVER_DMG_REAC_OTHER), - /* Fire arrow */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Ice arrow */ DMG_ENTRY(4, LEEVER_DMG_REAC_ICE), - /* Light arrow */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Unk arrow 1 */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Unk arrow 2 */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Unk arrow 3 */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Fire magic */ DMG_ENTRY(0, LEEVER_DMG_REAC_NONE), - /* Ice magic */ DMG_ENTRY(4, LEEVER_DMG_REAC_ICE), - /* Light magic */ DMG_ENTRY(0, LEEVER_DMG_REAC_NONE), - /* Shield */ DMG_ENTRY(0, LEEVER_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, LEEVER_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Giant spin */ DMG_ENTRY(8, LEEVER_DMG_REAC_OTHER), - /* Master spin */ DMG_ENTRY(4, LEEVER_DMG_REAC_OTHER), - /* Kokiri jump */ DMG_ENTRY(2, LEEVER_DMG_REAC_OTHER), - /* Giant jump */ DMG_ENTRY(8, LEEVER_DMG_REAC_OTHER), - /* Master jump */ DMG_ENTRY(4, LEEVER_DMG_REAC_OTHER), - /* Unknown 1 */ DMG_ENTRY(0, LEEVER_DMG_REAC_UNK), - /* Unblockable */ DMG_ENTRY(0, LEEVER_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(0, LEEVER_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, LEEVER_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, LEEVER_DMG_REACT_NONE), + /* Deku stick */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Slingshot */ DMG_ENTRY(1, LEEVER_DMG_REACT_OTHER), + /* Explosive */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Boomerang */ DMG_ENTRY(1, LEEVER_DMG_REACT_BOOMERANG), + /* Normal arrow */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Hammer swing */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Hookshot */ DMG_ENTRY(2, LEEVER_DMG_REACT_HOOKSHOT), + /* Kokiri sword */ DMG_ENTRY(1, LEEVER_DMG_REACT_OTHER), + /* Master sword */ DMG_ENTRY(4, LEEVER_DMG_REACT_OTHER), + /* Giant's Knife */ DMG_ENTRY(6, LEEVER_DMG_REACT_OTHER), + /* Fire arrow */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Ice arrow */ DMG_ENTRY(4, LEEVER_DMG_REACT_ICE), + /* Light arrow */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Unk arrow 1 */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Unk arrow 2 */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Unk arrow 3 */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Fire magic */ DMG_ENTRY(0, LEEVER_DMG_REACT_NONE), + /* Ice magic */ DMG_ENTRY(4, LEEVER_DMG_REACT_ICE), + /* Light magic */ DMG_ENTRY(0, LEEVER_DMG_REACT_NONE), + /* Shield */ DMG_ENTRY(0, LEEVER_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, LEEVER_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Giant spin */ DMG_ENTRY(8, LEEVER_DMG_REACT_OTHER), + /* Master spin */ DMG_ENTRY(4, LEEVER_DMG_REACT_OTHER), + /* Kokiri jump */ DMG_ENTRY(2, LEEVER_DMG_REACT_OTHER), + /* Giant jump */ DMG_ENTRY(8, LEEVER_DMG_REACT_OTHER), + /* Master jump */ DMG_ENTRY(4, LEEVER_DMG_REACT_OTHER), + /* Unknown 1 */ DMG_ENTRY(0, LEEVER_DMG_REACT_UNK), + /* Unblockable */ DMG_ENTRY(0, LEEVER_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(0, LEEVER_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, LEEVER_DMG_REACT_NONE), }; ActorProfile En_Reeba_Profile = { @@ -556,8 +556,8 @@ void EnReeba_CheckDamage(EnReeba* this, PlayState* play) { this->stunType = LEEVER_STUN_NONE; switch (this->actor.colChkInfo.damageReaction) { - case LEEVER_DMG_REAC_UNUSED: - case LEEVER_DMG_REAC_BOOMERANG: + case LEEVER_DMG_REACT_UNUSED: + case LEEVER_DMG_REACT_BOOMERANG: if ((this->actor.colChkInfo.health > 1) && (this->stunType != LEEVER_STUN_OTHER)) { this->stunType = LEEVER_STUN_OTHER; Actor_PlaySfx(&this->actor, NA_SE_EN_GOMA_JR_FREEZE); @@ -567,7 +567,7 @@ void EnReeba_CheckDamage(EnReeba* this, PlayState* play) { break; } FALLTHROUGH; - case LEEVER_DMG_REAC_HOOKSHOT: + case LEEVER_DMG_REACT_HOOKSHOT: if ((this->actor.colChkInfo.health > 2) && (this->stunType != LEEVER_STUN_OTHER)) { this->stunType = LEEVER_STUN_OTHER; Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, @@ -577,7 +577,7 @@ void EnReeba_CheckDamage(EnReeba* this, PlayState* play) { break; } FALLTHROUGH; - case LEEVER_DMG_REAC_OTHER: + case LEEVER_DMG_REACT_OTHER: this->unkDamageField = 6; Actor_ApplyDamage(&this->actor); if (this->actor.colChkInfo.health == 0) { @@ -593,7 +593,7 @@ void EnReeba_CheckDamage(EnReeba* this, PlayState* play) { } break; - case LEEVER_DMG_REAC_ICE: + case LEEVER_DMG_REACT_ICE: Actor_ApplyDamage(&this->actor); this->unkDamageField = 2; this->stunType = LEEVER_STUN_ICE; @@ -601,7 +601,7 @@ void EnReeba_CheckDamage(EnReeba* this, PlayState* play) { this->actionfunc = EnReeba_SetupStunned; break; - case LEEVER_DMG_REAC_UNK: + case LEEVER_DMG_REACT_UNK: if (this->stunType != LEEVER_STUN_OTHER) { this->stunType = LEEVER_STUN_OTHER; Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_OPA, diff --git a/src/overlays/actors/ovl_En_Rr/z_en_rr.c b/src/overlays/actors/ovl_En_Rr/z_en_rr.c index e2f487c410..9623bb42c9 100644 --- a/src/overlays/actors/ovl_En_Rr/z_en_rr.c +++ b/src/overlays/actors/ovl_En_Rr/z_en_rr.c @@ -45,16 +45,16 @@ typedef enum EnRrReachState { } EnRrReachState; typedef enum EnRrDamageReaction { - /* 0x0 */ RR_DMG_REAC_NONE, - /* 0x1 */ RR_DMG_REAC_STUN, - /* 0x2 */ RR_DMG_REAC_FIRE, - /* 0x3 */ RR_DMG_REAC_ICE, - /* 0x4 */ RR_DMG_REAC_LIGHT_MAGIC, - /* 0xB */ RR_DMG_REAC_LIGHT_ARROW = 11, - /* 0xC */ RR_DMG_REAC_SHDW_ARROW, - /* 0xD */ RR_DMG_REAC_WIND_ARROW, - /* 0xE */ RR_DMG_REAC_SPRT_ARROW, - /* 0xF */ RR_DMG_REAC_NORMAL + /* 0x0 */ RR_DMG_REACT_NONE, + /* 0x1 */ RR_DMG_REACT_STUN, + /* 0x2 */ RR_DMG_REACT_FIRE, + /* 0x3 */ RR_DMG_REACT_ICE, + /* 0x4 */ RR_DMG_REACT_LIGHT_MAGIC, + /* 0xB */ RR_DMG_REACT_LIGHT_ARROW = 11, + /* 0xC */ RR_DMG_REACT_SHDW_ARROW, + /* 0xD */ RR_DMG_REACT_WIND_ARROW, + /* 0xE */ RR_DMG_REACT_SPRT_ARROW, + /* 0xF */ RR_DMG_REACT_NORMAL } EnRrDamageReaction; typedef enum EnRrDropType { @@ -142,38 +142,38 @@ static ColliderCylinderInitType1 sCylinderInit2 = { }; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, RR_DMG_REAC_NONE), - /* Deku stick */ DMG_ENTRY(2, RR_DMG_REAC_NORMAL), - /* Slingshot */ DMG_ENTRY(1, RR_DMG_REAC_NORMAL), - /* Explosive */ DMG_ENTRY(2, RR_DMG_REAC_NORMAL), - /* Boomerang */ DMG_ENTRY(0, RR_DMG_REAC_STUN), - /* Normal arrow */ DMG_ENTRY(2, RR_DMG_REAC_NORMAL), - /* Hammer swing */ DMG_ENTRY(2, RR_DMG_REAC_NORMAL), - /* Hookshot */ DMG_ENTRY(0, RR_DMG_REAC_STUN), - /* Kokiri sword */ DMG_ENTRY(1, RR_DMG_REAC_NORMAL), - /* Master sword */ DMG_ENTRY(2, RR_DMG_REAC_NORMAL), - /* Giant's Knife */ DMG_ENTRY(4, RR_DMG_REAC_NORMAL), - /* Fire arrow */ DMG_ENTRY(4, RR_DMG_REAC_FIRE), - /* Ice arrow */ DMG_ENTRY(4, RR_DMG_REAC_ICE), - /* Light arrow */ DMG_ENTRY(15, RR_DMG_REAC_LIGHT_ARROW), - /* Unk arrow 1 */ DMG_ENTRY(4, RR_DMG_REAC_WIND_ARROW), - /* Unk arrow 2 */ DMG_ENTRY(15, RR_DMG_REAC_SHDW_ARROW), - /* Unk arrow 3 */ DMG_ENTRY(15, RR_DMG_REAC_SPRT_ARROW), - /* Fire magic */ DMG_ENTRY(4, RR_DMG_REAC_FIRE), - /* Ice magic */ DMG_ENTRY(3, RR_DMG_REAC_ICE), - /* Light magic */ DMG_ENTRY(10, RR_DMG_REAC_LIGHT_MAGIC), - /* Shield */ DMG_ENTRY(0, RR_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, RR_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, RR_DMG_REAC_NORMAL), - /* Giant spin */ DMG_ENTRY(4, RR_DMG_REAC_NORMAL), - /* Master spin */ DMG_ENTRY(2, RR_DMG_REAC_NORMAL), - /* Kokiri jump */ DMG_ENTRY(2, RR_DMG_REAC_NORMAL), - /* Giant jump */ DMG_ENTRY(8, RR_DMG_REAC_NORMAL), - /* Master jump */ DMG_ENTRY(4, RR_DMG_REAC_NORMAL), - /* Unknown 1 */ DMG_ENTRY(10, RR_DMG_REAC_SPRT_ARROW), - /* Unblockable */ DMG_ENTRY(0, RR_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(0, RR_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, RR_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, RR_DMG_REACT_NONE), + /* Deku stick */ DMG_ENTRY(2, RR_DMG_REACT_NORMAL), + /* Slingshot */ DMG_ENTRY(1, RR_DMG_REACT_NORMAL), + /* Explosive */ DMG_ENTRY(2, RR_DMG_REACT_NORMAL), + /* Boomerang */ DMG_ENTRY(0, RR_DMG_REACT_STUN), + /* Normal arrow */ DMG_ENTRY(2, RR_DMG_REACT_NORMAL), + /* Hammer swing */ DMG_ENTRY(2, RR_DMG_REACT_NORMAL), + /* Hookshot */ DMG_ENTRY(0, RR_DMG_REACT_STUN), + /* Kokiri sword */ DMG_ENTRY(1, RR_DMG_REACT_NORMAL), + /* Master sword */ DMG_ENTRY(2, RR_DMG_REACT_NORMAL), + /* Giant's Knife */ DMG_ENTRY(4, RR_DMG_REACT_NORMAL), + /* Fire arrow */ DMG_ENTRY(4, RR_DMG_REACT_FIRE), + /* Ice arrow */ DMG_ENTRY(4, RR_DMG_REACT_ICE), + /* Light arrow */ DMG_ENTRY(15, RR_DMG_REACT_LIGHT_ARROW), + /* Unk arrow 1 */ DMG_ENTRY(4, RR_DMG_REACT_WIND_ARROW), + /* Unk arrow 2 */ DMG_ENTRY(15, RR_DMG_REACT_SHDW_ARROW), + /* Unk arrow 3 */ DMG_ENTRY(15, RR_DMG_REACT_SPRT_ARROW), + /* Fire magic */ DMG_ENTRY(4, RR_DMG_REACT_FIRE), + /* Ice magic */ DMG_ENTRY(3, RR_DMG_REACT_ICE), + /* Light magic */ DMG_ENTRY(10, RR_DMG_REACT_LIGHT_MAGIC), + /* Shield */ DMG_ENTRY(0, RR_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, RR_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, RR_DMG_REACT_NORMAL), + /* Giant spin */ DMG_ENTRY(4, RR_DMG_REACT_NORMAL), + /* Master spin */ DMG_ENTRY(2, RR_DMG_REACT_NORMAL), + /* Kokiri jump */ DMG_ENTRY(2, RR_DMG_REACT_NORMAL), + /* Giant jump */ DMG_ENTRY(8, RR_DMG_REACT_NORMAL), + /* Master jump */ DMG_ENTRY(4, RR_DMG_REACT_NORMAL), + /* Unknown 1 */ DMG_ENTRY(10, RR_DMG_REACT_SPRT_ARROW), + /* Unblockable */ DMG_ENTRY(0, RR_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(0, RR_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, RR_DMG_REACT_NONE), }; static InitChainEntry sInitChain[] = { @@ -455,19 +455,19 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) { CollisionCheck_BlueBlood(play, NULL, &hitPos); } switch (this->actor.colChkInfo.damageReaction) { - case RR_DMG_REAC_LIGHT_ARROW: + case RR_DMG_REACT_LIGHT_ARROW: dropType++; // purple rupee FALLTHROUGH; - case RR_DMG_REAC_SHDW_ARROW: + case RR_DMG_REACT_SHDW_ARROW: dropType++; // flexible FALLTHROUGH; - case RR_DMG_REAC_WIND_ARROW: + case RR_DMG_REACT_WIND_ARROW: dropType++; // arrow FALLTHROUGH; - case RR_DMG_REAC_SPRT_ARROW: + case RR_DMG_REACT_SPRT_ARROW: dropType++; // magic jar FALLTHROUGH; - case RR_DMG_REAC_NORMAL: + case RR_DMG_REACT_NORMAL: // "ouch" PRINTF(VT_FGCOL(RED) "いてっ( %d : LIFE %d : DAMAGE %d : %x )!!" VT_RST "\n", this->frameCount, this->actor.colChkInfo.health, this->actor.colChkInfo.damage, @@ -486,7 +486,7 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) { EnRr_SetupDeath(this); } return; - case RR_DMG_REAC_FIRE: // Fire Arrow and Din's Fire + case RR_DMG_REACT_FIRE: // Fire Arrow and Din's Fire Actor_ApplyDamage(&this->actor); if (this->actor.colChkInfo.health == 0) { this->dropType = RR_DROP_RANDOM_RUPEE; @@ -495,7 +495,7 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) { this->effectTimer = 20; EnRr_SetupStunned(this); return; - case RR_DMG_REAC_ICE: // Ice Arrow and unused ice magic + case RR_DMG_REACT_ICE: // Ice Arrow and unused ice magic Actor_ApplyDamage(&this->actor); if (this->actor.colChkInfo.health == 0) { this->dropType = RR_DROP_RANDOM_RUPEE; @@ -512,7 +512,7 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) { #endif EnRr_SetupStunned(this); return; - case RR_DMG_REAC_LIGHT_MAGIC: // Unused light magic + case RR_DMG_REACT_LIGHT_MAGIC: // Unused light magic Actor_ApplyDamage(&this->actor); if (this->actor.colChkInfo.health == 0) { this->dropType = RR_DROP_RUPEE_RED; @@ -520,7 +520,7 @@ void EnRr_CollisionCheck(EnRr* this, PlayState* play) { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, 255, COLORFILTER_BUFFLAG_XLU, 80); EnRr_SetupStunned(this); return; - case RR_DMG_REAC_STUN: // Boomerang and Hookshot + case RR_DMG_REACT_STUN: // Boomerang and Hookshot Actor_PlaySfx(&this->actor, NA_SE_EN_GOMA_JR_FREEZE); Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 255, COLORFILTER_BUFFLAG_XLU, 80); EnRr_SetupStunned(this); diff --git a/src/overlays/actors/ovl_En_Test/z_en_test.c b/src/overlays/actors/ovl_En_Test/z_en_test.c index fadb17b88b..aba5f6d564 100644 --- a/src/overlays/actors/ovl_En_Test/z_en_test.c +++ b/src/overlays/actors/ovl_En_Test/z_en_test.c @@ -213,47 +213,47 @@ static ColliderQuadInit sSwordColliderQuadInit = { }; typedef enum StalfosDamageReaction { - /* 0x0 */ STALFOS_DMG_REAC_NORMAL, - /* 0x1 */ STALFOS_DMG_REAC_STUN, - /* 0x6 */ STALFOS_DMG_REAC_FIREMAGIC = 6, - /* 0xD */ STALFOS_DMG_REAC_SLING = 0xD, - /* 0xE */ STALFOS_DMG_REAC_LIGHT, - /* 0xF */ STALFOS_DMG_REAC_FREEZE + /* 0x0 */ STALFOS_DMG_REACT_NORMAL, + /* 0x1 */ STALFOS_DMG_REACT_STUN, + /* 0x6 */ STALFOS_DMG_REACT_FIREMAGIC = 6, + /* 0xD */ STALFOS_DMG_REACT_SLING = 0xD, + /* 0xE */ STALFOS_DMG_REACT_LIGHT, + /* 0xF */ STALFOS_DMG_REACT_FREEZE } StalfosDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, STALFOS_DMG_REAC_STUN), - /* Deku stick */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Slingshot */ DMG_ENTRY(1, STALFOS_DMG_REAC_SLING), - /* Explosive */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Boomerang */ DMG_ENTRY(0, STALFOS_DMG_REAC_STUN), - /* Normal arrow */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Hammer swing */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Hookshot */ DMG_ENTRY(0, STALFOS_DMG_REAC_STUN), - /* Kokiri sword */ DMG_ENTRY(1, STALFOS_DMG_REAC_NORMAL), - /* Master sword */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Giant's Knife */ DMG_ENTRY(4, STALFOS_DMG_REAC_NORMAL), - /* Fire arrow */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Ice arrow */ DMG_ENTRY(4, STALFOS_DMG_REAC_FREEZE), - /* Light arrow */ DMG_ENTRY(2, STALFOS_DMG_REAC_LIGHT), - /* Unk arrow 1 */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Unk arrow 2 */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Unk arrow 3 */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Fire magic */ DMG_ENTRY(0, STALFOS_DMG_REAC_FIREMAGIC), - /* Ice magic */ DMG_ENTRY(3, STALFOS_DMG_REAC_FREEZE), - /* Light magic */ DMG_ENTRY(0, STALFOS_DMG_REAC_LIGHT), - /* Shield */ DMG_ENTRY(0, STALFOS_DMG_REAC_NORMAL), - /* Mirror Ray */ DMG_ENTRY(0, STALFOS_DMG_REAC_NORMAL), - /* Kokiri spin */ DMG_ENTRY(1, STALFOS_DMG_REAC_NORMAL), - /* Giant spin */ DMG_ENTRY(4, STALFOS_DMG_REAC_NORMAL), - /* Master spin */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Kokiri jump */ DMG_ENTRY(2, STALFOS_DMG_REAC_NORMAL), - /* Giant jump */ DMG_ENTRY(8, STALFOS_DMG_REAC_NORMAL), - /* Master jump */ DMG_ENTRY(4, STALFOS_DMG_REAC_NORMAL), - /* Unknown 1 */ DMG_ENTRY(0, STALFOS_DMG_REAC_NORMAL), - /* Unblockable */ DMG_ENTRY(0, STALFOS_DMG_REAC_NORMAL), - /* Hammer jump */ DMG_ENTRY(4, STALFOS_DMG_REAC_NORMAL), - /* Unknown 2 */ DMG_ENTRY(0, STALFOS_DMG_REAC_NORMAL), + /* Deku nut */ DMG_ENTRY(0, STALFOS_DMG_REACT_STUN), + /* Deku stick */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Slingshot */ DMG_ENTRY(1, STALFOS_DMG_REACT_SLING), + /* Explosive */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Boomerang */ DMG_ENTRY(0, STALFOS_DMG_REACT_STUN), + /* Normal arrow */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Hammer swing */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Hookshot */ DMG_ENTRY(0, STALFOS_DMG_REACT_STUN), + /* Kokiri sword */ DMG_ENTRY(1, STALFOS_DMG_REACT_NORMAL), + /* Master sword */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Giant's Knife */ DMG_ENTRY(4, STALFOS_DMG_REACT_NORMAL), + /* Fire arrow */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Ice arrow */ DMG_ENTRY(4, STALFOS_DMG_REACT_FREEZE), + /* Light arrow */ DMG_ENTRY(2, STALFOS_DMG_REACT_LIGHT), + /* Unk arrow 1 */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Unk arrow 2 */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Unk arrow 3 */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Fire magic */ DMG_ENTRY(0, STALFOS_DMG_REACT_FIREMAGIC), + /* Ice magic */ DMG_ENTRY(3, STALFOS_DMG_REACT_FREEZE), + /* Light magic */ DMG_ENTRY(0, STALFOS_DMG_REACT_LIGHT), + /* Shield */ DMG_ENTRY(0, STALFOS_DMG_REACT_NORMAL), + /* Mirror Ray */ DMG_ENTRY(0, STALFOS_DMG_REACT_NORMAL), + /* Kokiri spin */ DMG_ENTRY(1, STALFOS_DMG_REACT_NORMAL), + /* Giant spin */ DMG_ENTRY(4, STALFOS_DMG_REACT_NORMAL), + /* Master spin */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Kokiri jump */ DMG_ENTRY(2, STALFOS_DMG_REACT_NORMAL), + /* Giant jump */ DMG_ENTRY(8, STALFOS_DMG_REACT_NORMAL), + /* Master jump */ DMG_ENTRY(4, STALFOS_DMG_REACT_NORMAL), + /* Unknown 1 */ DMG_ENTRY(0, STALFOS_DMG_REACT_NORMAL), + /* Unblockable */ DMG_ENTRY(0, STALFOS_DMG_REACT_NORMAL), + /* Hammer jump */ DMG_ENTRY(4, STALFOS_DMG_REACT_NORMAL), + /* Unknown 2 */ DMG_ENTRY(0, STALFOS_DMG_REACT_NORMAL), }; static InitChainEntry sInitChain[] = { @@ -1313,12 +1313,12 @@ void EnTest_SetupStunned(EnTest* this) { this->skelAnime.playSpeed = 0.0f; this->actor.speed = -4.0f; - if (this->lastDamageReaction == STALFOS_DMG_REAC_LIGHT) { + if (this->lastDamageReaction == STALFOS_DMG_REACT_LIGHT) { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_GRAY, 120, COLORFILTER_BUFFLAG_OPA, 80); } else { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80); - if (this->lastDamageReaction == STALFOS_DMG_REAC_FREEZE) { + if (this->lastDamageReaction == STALFOS_DMG_REACT_FREEZE) { this->iceTimer = 36; } else { Animation_PlayOnceSetSpeed(&this->skelAnime, &gStalfosFlinchFromHitFrontAnim, 0.0f); @@ -1678,8 +1678,8 @@ void EnTest_UpdateDamage(EnTest* this, PlayState* play) { } else if (this->bodyCollider.base.acFlags & AC_HIT) { this->bodyCollider.base.acFlags &= ~AC_HIT; - if ((this->actor.colChkInfo.damageReaction != STALFOS_DMG_REAC_SLING) && - (this->actor.colChkInfo.damageReaction != STALFOS_DMG_REAC_FIREMAGIC)) { + if ((this->actor.colChkInfo.damageReaction != STALFOS_DMG_REACT_SLING) && + (this->actor.colChkInfo.damageReaction != STALFOS_DMG_REACT_FIREMAGIC)) { this->lastDamageReaction = this->actor.colChkInfo.damageReaction; if (this->swordState >= 1) { this->swordState = 0; @@ -1689,9 +1689,9 @@ void EnTest_UpdateDamage(EnTest* this, PlayState* play) { Actor_SetDropFlag(&this->actor, &this->bodyCollider.elem, false); Audio_StopSfxByPosAndId(&this->actor.projectedPos, NA_SE_EN_STAL_WARAU); - if ((this->actor.colChkInfo.damageReaction == STALFOS_DMG_REAC_STUN) || - (this->actor.colChkInfo.damageReaction == STALFOS_DMG_REAC_FREEZE) || - (this->actor.colChkInfo.damageReaction == STALFOS_DMG_REAC_LIGHT)) { + if ((this->actor.colChkInfo.damageReaction == STALFOS_DMG_REACT_STUN) || + (this->actor.colChkInfo.damageReaction == STALFOS_DMG_REACT_FREEZE) || + (this->actor.colChkInfo.damageReaction == STALFOS_DMG_REACT_LIGHT)) { if (this->unk_7C8 != 0xB) { Actor_ApplyDamage(&this->actor); EnTest_SetupStunned(this); @@ -1723,7 +1723,7 @@ void EnTest_Update(Actor* thisx, PlayState* play) { EnTest_UpdateDamage(this, play); - if (this->actor.colChkInfo.damageReaction != STALFOS_DMG_REAC_FIREMAGIC) { + if (this->actor.colChkInfo.damageReaction != STALFOS_DMG_REACT_FIREMAGIC) { Actor_MoveXZGravity(&this->actor); Actor_UpdateBgCheckInfo(play, &this->actor, 75.0f, 30.0f, 30.0f, UPDBGCHECKINFO_FLAG_0 | UPDBGCHECKINFO_FLAG_2 | UPDBGCHECKINFO_FLAG_3 | diff --git a/src/overlays/actors/ovl_En_Tp/z_en_tp.c b/src/overlays/actors/ovl_En_Tp/z_en_tp.c index f1aca3cf0a..3b29e01601 100644 --- a/src/overlays/actors/ovl_En_Tp/z_en_tp.c +++ b/src/overlays/actors/ovl_En_Tp/z_en_tp.c @@ -96,45 +96,45 @@ static ColliderJntSphInit sJntSphInit = { }; typedef enum TailpasaranDamageReaction { - /* 00 */ TAILPASARAN_DMG_REAC_NONE, - /* 01 */ TAILPASARAN_DMG_REAC_DEKUNUT, - /* 14 */ TAILPASARAN_DMG_REAC_SHOCKING = 14, // Kills the Tailpasaran but shocks Player - /* 15 */ TAILPASARAN_DMG_REAC_INSULATING // Kills the Tailpasaran and does not shock Player + /* 00 */ TAILPASARAN_DMG_REACT_NONE, + /* 01 */ TAILPASARAN_DMG_REACT_DEKUNUT, + /* 14 */ TAILPASARAN_DMG_REACT_SHOCKING = 14, // Kills the Tailpasaran but shocks Player + /* 15 */ TAILPASARAN_DMG_REACT_INSULATING // Kills the Tailpasaran and does not shock Player } TailpasaranDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_DEKUNUT), - /* Deku stick */ DMG_ENTRY(2, TAILPASARAN_DMG_REAC_INSULATING), - /* Slingshot */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Explosive */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Boomerang */ DMG_ENTRY(1, TAILPASARAN_DMG_REAC_INSULATING), - /* Normal arrow */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Hammer swing */ DMG_ENTRY(2, TAILPASARAN_DMG_REAC_SHOCKING), - /* Hookshot */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Kokiri sword */ DMG_ENTRY(1, TAILPASARAN_DMG_REAC_SHOCKING), - /* Master sword */ DMG_ENTRY(2, TAILPASARAN_DMG_REAC_SHOCKING), - /* Giant's Knife */ DMG_ENTRY(4, TAILPASARAN_DMG_REAC_SHOCKING), - /* Fire arrow */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Ice arrow */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Light arrow */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Unk arrow 1 */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Unk arrow 2 */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Unk arrow 3 */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Fire magic */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Ice magic */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Light magic */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Shield */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, TAILPASARAN_DMG_REAC_SHOCKING), - /* Giant spin */ DMG_ENTRY(4, TAILPASARAN_DMG_REAC_SHOCKING), - /* Master spin */ DMG_ENTRY(2, TAILPASARAN_DMG_REAC_SHOCKING), - /* Kokiri jump */ DMG_ENTRY(2, TAILPASARAN_DMG_REAC_SHOCKING), - /* Giant jump */ DMG_ENTRY(8, TAILPASARAN_DMG_REAC_SHOCKING), - /* Master jump */ DMG_ENTRY(4, TAILPASARAN_DMG_REAC_SHOCKING), - /* Unknown 1 */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, TAILPASARAN_DMG_REAC_SHOCKING), - /* Unknown 2 */ DMG_ENTRY(0, TAILPASARAN_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_DEKUNUT), + /* Deku stick */ DMG_ENTRY(2, TAILPASARAN_DMG_REACT_INSULATING), + /* Slingshot */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Explosive */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Boomerang */ DMG_ENTRY(1, TAILPASARAN_DMG_REACT_INSULATING), + /* Normal arrow */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Hammer swing */ DMG_ENTRY(2, TAILPASARAN_DMG_REACT_SHOCKING), + /* Hookshot */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Kokiri sword */ DMG_ENTRY(1, TAILPASARAN_DMG_REACT_SHOCKING), + /* Master sword */ DMG_ENTRY(2, TAILPASARAN_DMG_REACT_SHOCKING), + /* Giant's Knife */ DMG_ENTRY(4, TAILPASARAN_DMG_REACT_SHOCKING), + /* Fire arrow */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Ice arrow */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Light arrow */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Unk arrow 1 */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Unk arrow 2 */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Unk arrow 3 */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Fire magic */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Ice magic */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Light magic */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Shield */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, TAILPASARAN_DMG_REACT_SHOCKING), + /* Giant spin */ DMG_ENTRY(4, TAILPASARAN_DMG_REACT_SHOCKING), + /* Master spin */ DMG_ENTRY(2, TAILPASARAN_DMG_REACT_SHOCKING), + /* Kokiri jump */ DMG_ENTRY(2, TAILPASARAN_DMG_REACT_SHOCKING), + /* Giant jump */ DMG_ENTRY(8, TAILPASARAN_DMG_REACT_SHOCKING), + /* Master jump */ DMG_ENTRY(4, TAILPASARAN_DMG_REACT_SHOCKING), + /* Unknown 1 */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, TAILPASARAN_DMG_REACT_SHOCKING), + /* Unknown 2 */ DMG_ENTRY(0, TAILPASARAN_DMG_REACT_NONE), }; static InitChainEntry sInitChain[] = { @@ -606,8 +606,8 @@ void EnTp_UpdateDamage(EnTp* this, PlayState* play) { Actor_SetDropFlagJntSph(&this->actor, &this->collider, true); this->damageReaction = this->actor.colChkInfo.damageReaction; - if (this->actor.colChkInfo.damageReaction != TAILPASARAN_DMG_REAC_NONE) { - if (this->actor.colChkInfo.damageReaction == TAILPASARAN_DMG_REAC_DEKUNUT) { + if (this->actor.colChkInfo.damageReaction != TAILPASARAN_DMG_REACT_NONE) { + if (this->actor.colChkInfo.damageReaction == TAILPASARAN_DMG_REACT_DEKUNUT) { phi_s4 = 1; } @@ -686,7 +686,7 @@ void EnTp_Update(Actor* thisx, PlayState* play) { s16 yawToWall; if (player->stateFlags1 & PLAYER_STATE1_26) { // Shielding - this->damageReaction = TAILPASARAN_DMG_REAC_NONE; + this->damageReaction = TAILPASARAN_DMG_REACT_NONE; } if (this->actor.colChkInfo.health != 0) { @@ -737,7 +737,7 @@ void EnTp_Update(Actor* thisx, PlayState* play) { this->actor.focus.pos = this->actor.world.pos; - if (this->damageReaction == TAILPASARAN_DMG_REAC_SHOCKING) { + if (this->damageReaction == TAILPASARAN_DMG_REACT_SHOCKING) { CollisionCheck_SetAT(play, &play->colChkCtx, &this->collider.base); } diff --git a/src/overlays/actors/ovl_En_Vali/z_en_vali.c b/src/overlays/actors/ovl_En_Vali/z_en_vali.c index 40562e6473..9a188bca56 100644 --- a/src/overlays/actors/ovl_En_Vali/z_en_vali.c +++ b/src/overlays/actors/ovl_En_Vali/z_en_vali.c @@ -98,47 +98,47 @@ static ColliderCylinderInit sCylinderInit = { static CollisionCheckInfoInit sColChkInfoInit = { 2, 18, 32, MASS_HEAVY }; typedef enum BariDamageReaction { - /* 0x0 */ BARI_DMG_REAC_NONE, - /* 0x1 */ BARI_DMG_REAC_STUN, - /* 0x2 */ BARI_DMG_REAC_FIRE, - /* 0x3 */ BARI_DMG_REAC_ICE, - /* 0xE */ BARI_DMG_REAC_SLINGSHOT = 0xE, - /* 0xF */ BARI_DMG_REAC_SWORD + /* 0x0 */ BARI_DMG_REACT_NONE, + /* 0x1 */ BARI_DMG_REACT_STUN, + /* 0x2 */ BARI_DMG_REACT_FIRE, + /* 0x3 */ BARI_DMG_REACT_ICE, + /* 0xE */ BARI_DMG_REACT_SLINGSHOT = 0xE, + /* 0xF */ BARI_DMG_REACT_SWORD } BariDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, BARI_DMG_REAC_STUN), - /* Deku stick */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Slingshot */ DMG_ENTRY(0, BARI_DMG_REAC_SLINGSHOT), - /* Explosive */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Boomerang */ DMG_ENTRY(0, BARI_DMG_REAC_STUN), - /* Normal arrow */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Hammer swing */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Hookshot */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Kokiri sword */ DMG_ENTRY(1, BARI_DMG_REAC_SWORD), - /* Master sword */ DMG_ENTRY(2, BARI_DMG_REAC_SWORD), - /* Giant's Knife */ DMG_ENTRY(4, BARI_DMG_REAC_SWORD), - /* Fire arrow */ DMG_ENTRY(4, BARI_DMG_REAC_FIRE), - /* Ice arrow */ DMG_ENTRY(4, BARI_DMG_REAC_ICE), - /* Light arrow */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Unk arrow 1 */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Unk arrow 2 */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Unk arrow 3 */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Fire magic */ DMG_ENTRY(4, BARI_DMG_REAC_FIRE), - /* Ice magic */ DMG_ENTRY(4, BARI_DMG_REAC_ICE), - /* Light magic */ DMG_ENTRY(0, BARI_DMG_REAC_NONE), - /* Shield */ DMG_ENTRY(0, BARI_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, BARI_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, BARI_DMG_REAC_NONE), - /* Giant spin */ DMG_ENTRY(4, BARI_DMG_REAC_NONE), - /* Master spin */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Kokiri jump */ DMG_ENTRY(2, BARI_DMG_REAC_NONE), - /* Giant jump */ DMG_ENTRY(8, BARI_DMG_REAC_NONE), - /* Master jump */ DMG_ENTRY(4, BARI_DMG_REAC_NONE), - /* Unknown 1 */ DMG_ENTRY(0, BARI_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, BARI_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, BARI_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, BARI_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, BARI_DMG_REACT_STUN), + /* Deku stick */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Slingshot */ DMG_ENTRY(0, BARI_DMG_REACT_SLINGSHOT), + /* Explosive */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Boomerang */ DMG_ENTRY(0, BARI_DMG_REACT_STUN), + /* Normal arrow */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Hammer swing */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Hookshot */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Kokiri sword */ DMG_ENTRY(1, BARI_DMG_REACT_SWORD), + /* Master sword */ DMG_ENTRY(2, BARI_DMG_REACT_SWORD), + /* Giant's Knife */ DMG_ENTRY(4, BARI_DMG_REACT_SWORD), + /* Fire arrow */ DMG_ENTRY(4, BARI_DMG_REACT_FIRE), + /* Ice arrow */ DMG_ENTRY(4, BARI_DMG_REACT_ICE), + /* Light arrow */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Unk arrow 1 */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Unk arrow 2 */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Unk arrow 3 */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Fire magic */ DMG_ENTRY(4, BARI_DMG_REACT_FIRE), + /* Ice magic */ DMG_ENTRY(4, BARI_DMG_REACT_ICE), + /* Light magic */ DMG_ENTRY(0, BARI_DMG_REACT_NONE), + /* Shield */ DMG_ENTRY(0, BARI_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, BARI_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, BARI_DMG_REACT_NONE), + /* Giant spin */ DMG_ENTRY(4, BARI_DMG_REACT_NONE), + /* Master spin */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Kokiri jump */ DMG_ENTRY(2, BARI_DMG_REACT_NONE), + /* Giant jump */ DMG_ENTRY(8, BARI_DMG_REACT_NONE), + /* Master jump */ DMG_ENTRY(4, BARI_DMG_REACT_NONE), + /* Unknown 1 */ DMG_ENTRY(0, BARI_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, BARI_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, BARI_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, BARI_DMG_REACT_NONE), }; static InitChainEntry sInitChain[] = { @@ -512,21 +512,21 @@ void EnVali_UpdateDamage(EnVali* this, PlayState* play) { this->bodyCollider.base.acFlags &= ~AC_HIT; Actor_SetDropFlag(&this->actor, &this->bodyCollider.elem, true); - if ((this->actor.colChkInfo.damageReaction != BARI_DMG_REAC_NONE) || (this->actor.colChkInfo.damage != 0)) { + if ((this->actor.colChkInfo.damageReaction != BARI_DMG_REACT_NONE) || (this->actor.colChkInfo.damage != 0)) { if (Actor_ApplyDamage(&this->actor) == 0) { Actor_PlaySfx(&this->actor, NA_SE_EN_BARI_DEAD); Enemy_StartFinishingBlow(play, &this->actor); this->actor.flags &= ~ACTOR_FLAG_ATTENTION_ENABLED; - } else if ((this->actor.colChkInfo.damageReaction != BARI_DMG_REAC_STUN) && - (this->actor.colChkInfo.damageReaction != BARI_DMG_REAC_SLINGSHOT)) { + } else if ((this->actor.colChkInfo.damageReaction != BARI_DMG_REACT_STUN) && + (this->actor.colChkInfo.damageReaction != BARI_DMG_REACT_SLINGSHOT)) { Actor_PlaySfx(&this->actor, NA_SE_EN_BARI_DAMAGE); } - if (this->actor.colChkInfo.damageReaction == BARI_DMG_REAC_STUN) { + if (this->actor.colChkInfo.damageReaction == BARI_DMG_REACT_STUN) { if (this->actionFunc != EnVali_Stunned) { EnVali_SetupStunned(this); } - } else if (this->actor.colChkInfo.damageReaction == BARI_DMG_REAC_SWORD) { + } else if (this->actor.colChkInfo.damageReaction == BARI_DMG_REACT_SWORD) { if (this->actionFunc != EnVali_Stunned) { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 150, COLORFILTER_BUFFLAG_XLU, 30); this->actor.params = BARI_TYPE_SWORD_DAMAGE; @@ -534,11 +534,11 @@ void EnVali_UpdateDamage(EnVali* this, PlayState* play) { } else { EnVali_SetupRetaliate(this); } - } else if (this->actor.colChkInfo.damageReaction == BARI_DMG_REAC_FIRE) { + } else if (this->actor.colChkInfo.damageReaction == BARI_DMG_REACT_FIRE) { EnVali_SetupBurnt(this); - } else if (this->actor.colChkInfo.damageReaction == BARI_DMG_REAC_ICE) { + } else if (this->actor.colChkInfo.damageReaction == BARI_DMG_REACT_ICE) { EnVali_SetupFrozen(this); - } else if (this->actor.colChkInfo.damageReaction == BARI_DMG_REAC_SLINGSHOT) { + } else if (this->actor.colChkInfo.damageReaction == BARI_DMG_REACT_SLINGSHOT) { if (this->slingshotReactionTimer == 0) { this->slingshotReactionTimer = 20; } diff --git a/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c b/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c index acb60fc4c6..9c6a27e026 100644 --- a/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c +++ b/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c @@ -83,45 +83,45 @@ static ColliderCylinderInit sCylinderInit = { static CollisionCheckInfoInit sColChkInfoInit = { 4, 30, 40, 150 }; typedef enum EnWallmasDamageReaction { - /* 0 */ WALLMAS_DMG_REAC_NONE, - /* 1 */ WALLMAS_DMG_REAC_STUN_BLUE, - /* 2 */ WALLMAS_DMG_REAC_BURN, - /* 4 */ WALLMAS_DMG_REAC_STUN_WHITE = 4 + /* 0 */ WALLMAS_DMG_REACT_NONE, + /* 1 */ WALLMAS_DMG_REACT_STUN_BLUE, + /* 2 */ WALLMAS_DMG_REACT_BURN, + /* 4 */ WALLMAS_DMG_REACT_STUN_WHITE = 4 } EnWallmasDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, WALLMAS_DMG_REAC_STUN_BLUE), - /* Deku stick */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Slingshot */ DMG_ENTRY(1, WALLMAS_DMG_REAC_NONE), - /* Explosive */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Boomerang */ DMG_ENTRY(0, WALLMAS_DMG_REAC_STUN_BLUE), - /* Normal arrow */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Hammer swing */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Hookshot */ DMG_ENTRY(0, WALLMAS_DMG_REAC_STUN_BLUE), - /* Kokiri sword */ DMG_ENTRY(1, WALLMAS_DMG_REAC_NONE), - /* Master sword */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Giant's Knife */ DMG_ENTRY(4, WALLMAS_DMG_REAC_NONE), - /* Fire arrow */ DMG_ENTRY(4, WALLMAS_DMG_REAC_BURN), - /* Ice arrow */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Light arrow */ DMG_ENTRY(4, WALLMAS_DMG_REAC_STUN_WHITE), - /* Unk arrow 1 */ DMG_ENTRY(4, WALLMAS_DMG_REAC_NONE), - /* Unk arrow 2 */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Unk arrow 3 */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Fire magic */ DMG_ENTRY(4, WALLMAS_DMG_REAC_BURN), - /* Ice magic */ DMG_ENTRY(0, WALLMAS_DMG_REAC_NONE), - /* Light magic */ DMG_ENTRY(4, WALLMAS_DMG_REAC_STUN_WHITE), - /* Shield */ DMG_ENTRY(0, WALLMAS_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, WALLMAS_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, WALLMAS_DMG_REAC_NONE), - /* Giant spin */ DMG_ENTRY(4, WALLMAS_DMG_REAC_NONE), - /* Master spin */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Kokiri jump */ DMG_ENTRY(2, WALLMAS_DMG_REAC_NONE), - /* Giant jump */ DMG_ENTRY(8, WALLMAS_DMG_REAC_NONE), - /* Master jump */ DMG_ENTRY(4, WALLMAS_DMG_REAC_NONE), - /* Unknown 1 */ DMG_ENTRY(0, WALLMAS_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, WALLMAS_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, WALLMAS_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, WALLMAS_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, WALLMAS_DMG_REACT_STUN_BLUE), + /* Deku stick */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Slingshot */ DMG_ENTRY(1, WALLMAS_DMG_REACT_NONE), + /* Explosive */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Boomerang */ DMG_ENTRY(0, WALLMAS_DMG_REACT_STUN_BLUE), + /* Normal arrow */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Hammer swing */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Hookshot */ DMG_ENTRY(0, WALLMAS_DMG_REACT_STUN_BLUE), + /* Kokiri sword */ DMG_ENTRY(1, WALLMAS_DMG_REACT_NONE), + /* Master sword */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Giant's Knife */ DMG_ENTRY(4, WALLMAS_DMG_REACT_NONE), + /* Fire arrow */ DMG_ENTRY(4, WALLMAS_DMG_REACT_BURN), + /* Ice arrow */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Light arrow */ DMG_ENTRY(4, WALLMAS_DMG_REACT_STUN_WHITE), + /* Unk arrow 1 */ DMG_ENTRY(4, WALLMAS_DMG_REACT_NONE), + /* Unk arrow 2 */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Unk arrow 3 */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Fire magic */ DMG_ENTRY(4, WALLMAS_DMG_REACT_BURN), + /* Ice magic */ DMG_ENTRY(0, WALLMAS_DMG_REACT_NONE), + /* Light magic */ DMG_ENTRY(4, WALLMAS_DMG_REACT_STUN_WHITE), + /* Shield */ DMG_ENTRY(0, WALLMAS_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, WALLMAS_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, WALLMAS_DMG_REACT_NONE), + /* Giant spin */ DMG_ENTRY(4, WALLMAS_DMG_REACT_NONE), + /* Master spin */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Kokiri jump */ DMG_ENTRY(2, WALLMAS_DMG_REACT_NONE), + /* Giant jump */ DMG_ENTRY(8, WALLMAS_DMG_REACT_NONE), + /* Master jump */ DMG_ENTRY(4, WALLMAS_DMG_REACT_NONE), + /* Unknown 1 */ DMG_ENTRY(0, WALLMAS_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, WALLMAS_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, WALLMAS_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, WALLMAS_DMG_REACT_NONE), }; static InitChainEntry sInitChain[] = { @@ -536,13 +536,13 @@ void EnWallmas_ColUpdate(EnWallmas* this, PlayState* play) { } } - if ((this->actor.colChkInfo.damageReaction == WALLMAS_DMG_REAC_STUN_WHITE) || - (this->actor.colChkInfo.damageReaction == WALLMAS_DMG_REAC_STUN_BLUE)) { + if ((this->actor.colChkInfo.damageReaction == WALLMAS_DMG_REACT_STUN_WHITE) || + (this->actor.colChkInfo.damageReaction == WALLMAS_DMG_REACT_STUN_BLUE)) { if (this->actionFunc != EnWallmas_Stun) { EnWallmas_SetupStun(this); } } else { - if (this->actor.colChkInfo.damageReaction == WALLMAS_DMG_REAC_BURN) { + if (this->actor.colChkInfo.damageReaction == WALLMAS_DMG_REACT_BURN) { EffectSsFCircle_Spawn(play, &this->actor, &this->actor.world.pos, 40, 40); } diff --git a/src/overlays/actors/ovl_En_Wf/z_en_wf.c b/src/overlays/actors/ovl_En_Wf/z_en_wf.c index ed0137f99e..978c2a4012 100644 --- a/src/overlays/actors/ovl_En_Wf/z_en_wf.c +++ b/src/overlays/actors/ovl_En_Wf/z_en_wf.c @@ -163,47 +163,47 @@ static ColliderCylinderInit sTailCylinderInit = { }; typedef enum EnWfDamageReaction { - /* 0 */ ENWF_DMG_REAC_NONE, - /* 1 */ ENWF_DMG_REAC_STUN, - /* 6 */ ENWF_DMG_REAC_ICE_MAGIC = 6, - /* 13 */ ENWF_DMG_REAC_LIGHT_MAGIC = 13, - /* 14 */ ENWF_DMG_REAC_FIRE, - /* 15 */ ENWF_DMG_REAC_UNDEF // used like STUN in the code, but not in the table + /* 0 */ ENWF_DMG_REACT_NONE, + /* 1 */ ENWF_DMG_REACT_STUN, + /* 6 */ ENWF_DMG_REACT_ICE_MAGIC = 6, + /* 13 */ ENWF_DMG_REACT_LIGHT_MAGIC = 13, + /* 14 */ ENWF_DMG_REACT_FIRE, + /* 15 */ ENWF_DMG_REACT_UNDEF // used like STUN in the code, but not in the table } EnWfDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, ENWF_DMG_REAC_STUN), - /* Deku stick */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Slingshot */ DMG_ENTRY(1, ENWF_DMG_REAC_NONE), - /* Explosive */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Boomerang */ DMG_ENTRY(0, ENWF_DMG_REAC_STUN), - /* Normal arrow */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Hammer swing */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Hookshot */ DMG_ENTRY(0, ENWF_DMG_REAC_STUN), - /* Kokiri sword */ DMG_ENTRY(1, ENWF_DMG_REAC_NONE), - /* Master sword */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Giant's Knife */ DMG_ENTRY(4, ENWF_DMG_REAC_NONE), - /* Fire arrow */ DMG_ENTRY(4, ENWF_DMG_REAC_FIRE), - /* Ice arrow */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Light arrow */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Unk arrow 1 */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Unk arrow 2 */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Unk arrow 3 */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Fire magic */ DMG_ENTRY(4, ENWF_DMG_REAC_FIRE), - /* Ice magic */ DMG_ENTRY(0, ENWF_DMG_REAC_ICE_MAGIC), - /* Light magic */ DMG_ENTRY(3, ENWF_DMG_REAC_LIGHT_MAGIC), - /* Shield */ DMG_ENTRY(0, ENWF_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, ENWF_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, ENWF_DMG_REAC_NONE), - /* Giant spin */ DMG_ENTRY(4, ENWF_DMG_REAC_NONE), - /* Master spin */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Kokiri jump */ DMG_ENTRY(2, ENWF_DMG_REAC_NONE), - /* Giant jump */ DMG_ENTRY(8, ENWF_DMG_REAC_NONE), - /* Master jump */ DMG_ENTRY(4, ENWF_DMG_REAC_NONE), - /* Unknown 1 */ DMG_ENTRY(0, ENWF_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, ENWF_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, ENWF_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, ENWF_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, ENWF_DMG_REACT_STUN), + /* Deku stick */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Slingshot */ DMG_ENTRY(1, ENWF_DMG_REACT_NONE), + /* Explosive */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Boomerang */ DMG_ENTRY(0, ENWF_DMG_REACT_STUN), + /* Normal arrow */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Hammer swing */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Hookshot */ DMG_ENTRY(0, ENWF_DMG_REACT_STUN), + /* Kokiri sword */ DMG_ENTRY(1, ENWF_DMG_REACT_NONE), + /* Master sword */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Giant's Knife */ DMG_ENTRY(4, ENWF_DMG_REACT_NONE), + /* Fire arrow */ DMG_ENTRY(4, ENWF_DMG_REACT_FIRE), + /* Ice arrow */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Light arrow */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Unk arrow 1 */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Unk arrow 2 */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Unk arrow 3 */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Fire magic */ DMG_ENTRY(4, ENWF_DMG_REACT_FIRE), + /* Ice magic */ DMG_ENTRY(0, ENWF_DMG_REACT_ICE_MAGIC), + /* Light magic */ DMG_ENTRY(3, ENWF_DMG_REACT_LIGHT_MAGIC), + /* Shield */ DMG_ENTRY(0, ENWF_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, ENWF_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, ENWF_DMG_REACT_NONE), + /* Giant spin */ DMG_ENTRY(4, ENWF_DMG_REACT_NONE), + /* Master spin */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Kokiri jump */ DMG_ENTRY(2, ENWF_DMG_REACT_NONE), + /* Giant jump */ DMG_ENTRY(8, ENWF_DMG_REACT_NONE), + /* Master jump */ DMG_ENTRY(4, ENWF_DMG_REACT_NONE), + /* Unknown 1 */ DMG_ENTRY(0, ENWF_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, ENWF_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, ENWF_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, ENWF_DMG_REACT_NONE), }; ActorProfile En_Wf_Profile = { @@ -1283,15 +1283,15 @@ void EnWf_UpdateDamage(EnWf* this, PlayState* play) { this->bodyColliderCylinder.base.acFlags &= ~AC_HIT; this->tailColliderCylinder.base.acFlags &= ~AC_HIT; - if (this->actor.colChkInfo.damageReaction != ENWF_DMG_REAC_ICE_MAGIC) { + if (this->actor.colChkInfo.damageReaction != ENWF_DMG_REACT_ICE_MAGIC) { this->damageReaction = this->actor.colChkInfo.damageReaction; Actor_SetDropFlag(&this->actor, &this->bodyColliderCylinder.elem, true); #if OOT_VERSION >= PAL_1_0 this->slashStatus = 0; #endif - if ((this->actor.colChkInfo.damageReaction == ENWF_DMG_REAC_STUN) || - (this->actor.colChkInfo.damageReaction == ENWF_DMG_REAC_UNDEF)) { + if ((this->actor.colChkInfo.damageReaction == ENWF_DMG_REACT_STUN) || + (this->actor.colChkInfo.damageReaction == ENWF_DMG_REACT_UNDEF)) { if (this->action != WOLFOS_ACTION_STUNNED) { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80); @@ -1301,7 +1301,7 @@ void EnWf_UpdateDamage(EnWf* this, PlayState* play) { } else { // LIGHT_MAGIC, FIRE, NONE Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_RED, 255, COLORFILTER_BUFFLAG_OPA, 8); - if (this->damageReaction == ENWF_DMG_REAC_FIRE) { + if (this->damageReaction == ENWF_DMG_REACT_FIRE) { this->fireTimer = 40; } @@ -1323,7 +1323,7 @@ void EnWf_Update(Actor* thisx, PlayState* play) { EnWf_UpdateDamage(this, play); - if (this->actor.colChkInfo.damageReaction != ENWF_DMG_REAC_ICE_MAGIC) { + if (this->actor.colChkInfo.damageReaction != ENWF_DMG_REACT_ICE_MAGIC) { Actor_MoveXZGravity(&this->actor); Actor_UpdateBgCheckInfo(play, &this->actor, 32.0f, 30.0f, 60.0f, UPDBGCHECKINFO_FLAG_0 | UPDBGCHECKINFO_FLAG_2 | UPDBGCHECKINFO_FLAG_3 | diff --git a/src/overlays/actors/ovl_En_Zf/z_en_zf.c b/src/overlays/actors/ovl_En_Zf/z_en_zf.c index 57ff1b554d..48f02b074e 100644 --- a/src/overlays/actors/ovl_En_Zf/z_en_zf.c +++ b/src/overlays/actors/ovl_En_Zf/z_en_zf.c @@ -170,46 +170,46 @@ static ColliderQuadInit sSwordQuadInit = { }; typedef enum EnZfDamageReaction { - /* 0x0 */ ENZF_DMG_REAC_NONE, - /* 0x1 */ ENZF_DMG_REAC_STUN, - /* 0x6 */ ENZF_DMG_REAC_IMMUNE = 6, // Skips damage code, but also skips the top half of Update - /* 0xD */ ENZF_DMG_REAC_PROJECTILE = 0xD, // Projectiles that don't have another damageeffect - /* 0xF */ ENZF_DMG_REAC_ICE = 0xF + /* 0x0 */ ENZF_DMG_REACT_NONE, + /* 0x1 */ ENZF_DMG_REACT_STUN, + /* 0x6 */ ENZF_DMG_REACT_IMMUNE = 6, // Skips damage code, but also skips the top half of Update + /* 0xD */ ENZF_DMG_REACT_PROJECTILE = 0xD, // Projectiles that don't have another damageeffect + /* 0xF */ ENZF_DMG_REACT_ICE = 0xF } EnZfDamageReaction; static DamageTable sDamageTable = { - /* Deku nut */ DMG_ENTRY(0, ENZF_DMG_REAC_STUN), - /* Deku stick */ DMG_ENTRY(2, ENZF_DMG_REAC_NONE), - /* Slingshot */ DMG_ENTRY(1, ENZF_DMG_REAC_PROJECTILE), - /* Explosive */ DMG_ENTRY(2, ENZF_DMG_REAC_NONE), - /* Boomerang */ DMG_ENTRY(0, ENZF_DMG_REAC_STUN), - /* Normal arrow */ DMG_ENTRY(2, ENZF_DMG_REAC_NONE), - /* Hammer swing */ DMG_ENTRY(2, ENZF_DMG_REAC_NONE), - /* Hookshot */ DMG_ENTRY(0, ENZF_DMG_REAC_STUN), - /* Kokiri sword */ DMG_ENTRY(1, ENZF_DMG_REAC_NONE), - /* Master sword */ DMG_ENTRY(2, ENZF_DMG_REAC_NONE), - /* Giant's Knife */ DMG_ENTRY(4, ENZF_DMG_REAC_NONE), - /* Fire arrow */ DMG_ENTRY(2, ENZF_DMG_REAC_PROJECTILE), - /* Ice arrow */ DMG_ENTRY(4, ENZF_DMG_REAC_ICE), - /* Light arrow */ DMG_ENTRY(2, ENZF_DMG_REAC_PROJECTILE), - /* Unk arrow 1 */ DMG_ENTRY(2, ENZF_DMG_REAC_PROJECTILE), - /* Unk arrow 2 */ DMG_ENTRY(2, ENZF_DMG_REAC_PROJECTILE), - /* Unk arrow 3 */ DMG_ENTRY(2, ENZF_DMG_REAC_PROJECTILE), - /* Fire magic */ DMG_ENTRY(0, ENZF_DMG_REAC_IMMUNE), - /* Ice magic */ DMG_ENTRY(3, ENZF_DMG_REAC_ICE), - /* Light magic */ DMG_ENTRY(0, ENZF_DMG_REAC_IMMUNE), - /* Shield */ DMG_ENTRY(0, ENZF_DMG_REAC_NONE), - /* Mirror Ray */ DMG_ENTRY(0, ENZF_DMG_REAC_NONE), - /* Kokiri spin */ DMG_ENTRY(1, ENZF_DMG_REAC_NONE), - /* Giant spin */ DMG_ENTRY(4, ENZF_DMG_REAC_NONE), - /* Master spin */ DMG_ENTRY(2, ENZF_DMG_REAC_NONE), - /* Kokiri jump */ DMG_ENTRY(2, ENZF_DMG_REAC_NONE), - /* Giant jump */ DMG_ENTRY(8, ENZF_DMG_REAC_NONE), - /* Master jump */ DMG_ENTRY(4, ENZF_DMG_REAC_NONE), - /* Unknown 1 */ DMG_ENTRY(0, ENZF_DMG_REAC_NONE), - /* Unblockable */ DMG_ENTRY(0, ENZF_DMG_REAC_NONE), - /* Hammer jump */ DMG_ENTRY(4, ENZF_DMG_REAC_NONE), - /* Unknown 2 */ DMG_ENTRY(0, ENZF_DMG_REAC_NONE), + /* Deku nut */ DMG_ENTRY(0, ENZF_DMG_REACT_STUN), + /* Deku stick */ DMG_ENTRY(2, ENZF_DMG_REACT_NONE), + /* Slingshot */ DMG_ENTRY(1, ENZF_DMG_REACT_PROJECTILE), + /* Explosive */ DMG_ENTRY(2, ENZF_DMG_REACT_NONE), + /* Boomerang */ DMG_ENTRY(0, ENZF_DMG_REACT_STUN), + /* Normal arrow */ DMG_ENTRY(2, ENZF_DMG_REACT_NONE), + /* Hammer swing */ DMG_ENTRY(2, ENZF_DMG_REACT_NONE), + /* Hookshot */ DMG_ENTRY(0, ENZF_DMG_REACT_STUN), + /* Kokiri sword */ DMG_ENTRY(1, ENZF_DMG_REACT_NONE), + /* Master sword */ DMG_ENTRY(2, ENZF_DMG_REACT_NONE), + /* Giant's Knife */ DMG_ENTRY(4, ENZF_DMG_REACT_NONE), + /* Fire arrow */ DMG_ENTRY(2, ENZF_DMG_REACT_PROJECTILE), + /* Ice arrow */ DMG_ENTRY(4, ENZF_DMG_REACT_ICE), + /* Light arrow */ DMG_ENTRY(2, ENZF_DMG_REACT_PROJECTILE), + /* Unk arrow 1 */ DMG_ENTRY(2, ENZF_DMG_REACT_PROJECTILE), + /* Unk arrow 2 */ DMG_ENTRY(2, ENZF_DMG_REACT_PROJECTILE), + /* Unk arrow 3 */ DMG_ENTRY(2, ENZF_DMG_REACT_PROJECTILE), + /* Fire magic */ DMG_ENTRY(0, ENZF_DMG_REACT_IMMUNE), + /* Ice magic */ DMG_ENTRY(3, ENZF_DMG_REACT_ICE), + /* Light magic */ DMG_ENTRY(0, ENZF_DMG_REACT_IMMUNE), + /* Shield */ DMG_ENTRY(0, ENZF_DMG_REACT_NONE), + /* Mirror Ray */ DMG_ENTRY(0, ENZF_DMG_REACT_NONE), + /* Kokiri spin */ DMG_ENTRY(1, ENZF_DMG_REACT_NONE), + /* Giant spin */ DMG_ENTRY(4, ENZF_DMG_REACT_NONE), + /* Master spin */ DMG_ENTRY(2, ENZF_DMG_REACT_NONE), + /* Kokiri jump */ DMG_ENTRY(2, ENZF_DMG_REACT_NONE), + /* Giant jump */ DMG_ENTRY(8, ENZF_DMG_REACT_NONE), + /* Master jump */ DMG_ENTRY(4, ENZF_DMG_REACT_NONE), + /* Unknown 1 */ DMG_ENTRY(0, ENZF_DMG_REACT_NONE), + /* Unblockable */ DMG_ENTRY(0, ENZF_DMG_REACT_NONE), + /* Hammer jump */ DMG_ENTRY(4, ENZF_DMG_REACT_NONE), + /* Unknown 2 */ DMG_ENTRY(0, ENZF_DMG_REACT_NONE), }; static InitChainEntry sInitChain[] = { @@ -1324,7 +1324,7 @@ void EnZf_SetupStunned(EnZf* this) { this->hopAnimIndex = 1; } - if (this->damageReaction == ENZF_DMG_REAC_ICE) { + if (this->damageReaction == ENZF_DMG_REACT_ICE) { this->iceTimer = 36; } else { Animation_PlayOnceSetSpeed(&this->skelAnime, &gZfKnockedBackAnim, 0.0f); @@ -1685,7 +1685,7 @@ void EnZf_Damaged(EnZf* this, PlayState* play) { SkelAnime_Update(&this->skelAnime) && (this->actor.bgCheckFlags & BGCHECKFLAG_GROUND)) { if (D_80B4A1B4 != -1) { - if (this->damageReaction == ENZF_DMG_REAC_PROJECTILE) { + if (this->damageReaction == ENZF_DMG_REACT_PROJECTILE) { D_80B4A1B0++; } else { this->actor.world.rot.y = this->actor.shape.rot.y; @@ -2028,12 +2028,12 @@ void EnZf_UpdateDamage(EnZf* this, PlayState* play) { if (((this->actor.params < ENZF_TYPE_LIZALFOS_MINIBOSS_A) /* not miniboss */ || (D_80B4A1B4 != this->actor.params)) && - (this->actor.colChkInfo.damageReaction != ENZF_DMG_REAC_IMMUNE)) { + (this->actor.colChkInfo.damageReaction != ENZF_DMG_REACT_IMMUNE)) { this->damageReaction = this->actor.colChkInfo.damageReaction; Actor_SetDropFlag(&this->actor, &this->bodyCollider.elem, false); - if ((this->actor.colChkInfo.damageReaction == ENZF_DMG_REAC_STUN) || - (this->actor.colChkInfo.damageReaction == ENZF_DMG_REAC_ICE)) { + if ((this->actor.colChkInfo.damageReaction == ENZF_DMG_REACT_STUN) || + (this->actor.colChkInfo.damageReaction == ENZF_DMG_REACT_ICE)) { if (this->action != ENZF_ACTION_STUNNED) { Actor_SetColorFilter(&this->actor, COLORFILTER_COLORFLAG_BLUE, 120, COLORFILTER_BUFFLAG_OPA, 80); Actor_ApplyDamage(&this->actor); @@ -2056,7 +2056,7 @@ void EnZf_UpdateDamage(EnZf* this, PlayState* play) { } else { if ((D_80B4A1B4 != -1) && ((this->actor.colChkInfo.health + this->actor.colChkInfo.damage) >= 4) && (this->actor.colChkInfo.health < 4)) { - this->damageReaction = ENZF_DMG_REAC_PROJECTILE; + this->damageReaction = ENZF_DMG_REACT_PROJECTILE; } EnZf_SetupDamaged(this); @@ -2072,7 +2072,7 @@ void EnZf_Update(Actor* thisx, PlayState* play) { s32 pad2; EnZf_UpdateDamage(this, play); - if (this->actor.colChkInfo.damageReaction != ENZF_DMG_REAC_IMMUNE) { + if (this->actor.colChkInfo.damageReaction != ENZF_DMG_REACT_IMMUNE) { this->unk_3F8 = false; if ((this->hopAnimIndex != 1) && (this->action != ENZF_ACTION_HOP_AWAY)) { if (this->actor.speed != 0.0f) {