1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-21 06:21:16 +00:00

Colliders: change "touch, bump" to AT and AC (elems) (#1637)

* toucherFlags, bumperFlags -> atElemFlags, acElemFlags

* TOUCH_ -> ATELEM_

* BUMP_ -> ACELEM_

* ColliderElementTouch,Bump -> ColliderElementDamageInfoAT,AC

* toucher,bumper -> atDmgInfo,acDmgInfo

* Update docs and zcolchk funcs names

* run formatter

* remove the last mentions of "bump" for colliders

* Update renamed functions in disasm
This commit is contained in:
Dragorn421 2024-03-05 01:33:08 +01:00 committed by GitHub
parent bf37ad1368
commit 68a86d2d00
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
253 changed files with 1509 additions and 1509 deletions

View file

@ -144,8 +144,8 @@ static ColliderCylinderInit sCylinderInitBlasts = {
ELEMTYPE_UNK0,
{ 0xFFCFFFFF, 0x00, 0x30 },
{ 0x00100000, 0x00, 0x00 },
TOUCH_ON | TOUCH_SFX_NORMAL,
BUMP_ON,
ATELEM_ON | ATELEM_SFX_NORMAL,
ACELEM_ON,
OCELEM_ON,
},
{ 25, 35, -17, { 0, 0, 0 } },
@ -164,8 +164,8 @@ static ColliderCylinderInit sCylinderInitKoumeKotake = {
ELEMTYPE_UNK0,
{ 0xFFCFFFFF, 0x00, 0x20 },
{ 0xFFCDFFFE, 0x00, 0x00 },
TOUCH_ON | TOUCH_SFX_NORMAL,
BUMP_ON,
ATELEM_ON | ATELEM_SFX_NORMAL,
ACELEM_ON,
OCELEM_ON,
},
{ 45, 120, -30, { 0, 0, 0 } },
@ -184,8 +184,8 @@ static ColliderCylinderInit sCylinderInitTwinrova = {
ELEMTYPE_UNK0,
{ 0xFFCFFFFF, 0x00, 0x20 },
{ 0xFFCDFFFE, 0x00, 0x00 },
TOUCH_ON | TOUCH_SFX_NORMAL,
BUMP_ON | BUMP_HOOKABLE,
ATELEM_ON | ATELEM_SFX_NORMAL,
ACELEM_ON | ACELEM_HOOKABLE,
OCELEM_ON,
},
{ 45, 120, -30, { 0, 0, 0 } },
@ -464,7 +464,7 @@ void BossTw_Init(Actor* thisx, PlayState* play2) {
if (this->actor.params == TW_FIRE_BLAST || this->actor.params == TW_FIRE_BLAST_GROUND) {
this->actionFunc = BossTw_BlastFire;
this->collider.elem.toucher.effect = 1;
this->collider.elem.atDmgInfo.effect = 1;
} else if (this->actor.params == TW_ICE_BLAST || this->actor.params == TW_ICE_BLAST_GROUND) {
this->actionFunc = BossTw_BlastIce;
} else if (this->actor.params >= TW_DEATHBALL_KOTAKE) {
@ -3097,7 +3097,7 @@ void BossTw_TwinrovaUpdate(Actor* thisx, PlayState* play2) {
ColliderElement* acHitElem = this->collider.elem.acHitElem;
this->collider.base.acFlags &= ~AC_HIT;
if (acHitElem->toucher.dmgFlags & (DMG_SLINGSHOT | DMG_ARROW)) {}
if (acHitElem->atDmgInfo.dmgFlags & (DMG_SLINGSHOT | DMG_ARROW)) {}
}
} else if (this->collider.base.acFlags & AC_HIT) {
u8 damage;
@ -3106,7 +3106,7 @@ void BossTw_TwinrovaUpdate(Actor* thisx, PlayState* play2) {
this->collider.base.acFlags &= ~AC_HIT;
swordDamage = false;
damage = CollisionCheck_GetSwordDamage(acHitElem->toucher.dmgFlags);
damage = CollisionCheck_GetSwordDamage(acHitElem->atDmgInfo.dmgFlags);
if (damage == 0) {
damage = 2;
@ -3114,7 +3114,7 @@ void BossTw_TwinrovaUpdate(Actor* thisx, PlayState* play2) {
swordDamage = true;
}
if (!(acHitElem->toucher.dmgFlags & DMG_HOOKSHOT)) {
if (!(acHitElem->atDmgInfo.dmgFlags & DMG_HOOKSHOT)) {
if (((s8)this->actor.colChkInfo.health < 3) && !swordDamage) {
damage = 0;
}
@ -4338,7 +4338,7 @@ s32 BossTw_BlastShieldCheck(BossTw* this, PlayState* play) {
this->collider.base.atFlags &= ~AT_HIT;
acHitElem = this->collider.elem.acHitElem;
if (acHitElem->toucher.dmgFlags & DMG_SHIELD) {
if (acHitElem->atDmgInfo.dmgFlags & DMG_SHIELD) {
this->work[INVINC_TIMER] = 7;
play->envCtx.lightBlend = 1.0f;
Rumble_Request(0.0f, 100, 5, 4);