diff options
Diffstat (limited to 'src/object')
| -rw-r--r-- | src/object/barrelSpiderweb.c | 6 | ||||
| -rw-r--r-- | src/object/dirtParticle.c | 4 | ||||
| -rw-r--r-- | src/object/eyeSwitch.c | 2 | ||||
| -rw-r--r-- | src/object/fairy.c | 2 | ||||
| -rw-r--r-- | src/object/hittableLever.c | 2 | ||||
| -rw-r--r-- | src/object/itemOnGround.c | 2 | ||||
| -rw-r--r-- | src/object/jarPortal.c | 2 | ||||
| -rw-r--r-- | src/object/lavaPlatform.c | 4 | ||||
| -rw-r--r-- | src/object/lightableSwitch.c | 4 | ||||
| -rw-r--r-- | src/object/objectA8.c | 2 | ||||
| -rw-r--r-- | src/object/objectOnSpinyBeetle.c | 2 | ||||
| -rw-r--r-- | src/object/sanctuaryStoneTablet.c | 2 | ||||
| -rw-r--r-- | src/object/smallIceBlock.c | 2 | ||||
| -rw-r--r-- | src/object/unusedSkull.c | 2 |
14 files changed, 19 insertions, 19 deletions
diff --git a/src/object/barrelSpiderweb.c b/src/object/barrelSpiderweb.c index 386f2c74..d4d821dd 100644 --- a/src/object/barrelSpiderweb.c +++ b/src/object/barrelSpiderweb.c @@ -64,7 +64,7 @@ void sub_0808BBE0(Entity* this) { ptr = &gUnk_0812144C[diff * 2]; SetAffineInfo(this, ptr[0], ptr[1], 0); } else { - this->contactFlags &= ~0x80; + this->contactFlags &= ~CONTACT_TAKE_DAMAGE; } } @@ -74,7 +74,7 @@ void BarrelSpiderweb_Action1(Entity* this) { tmp = -0x170; this->y.HALF.HI = gRoomControls.origin_y - ((this->parent)->zVelocity + tmp); sub_0808BBE0(this); - if (this->contactFlags == 0x93) { + if (this->contactFlags == (CONTACT_TAKE_DAMAGE | 0x13)) { this->timer--; this->spriteSettings.draw = 1; if (this->timer == 0) { @@ -114,7 +114,7 @@ void BarrelSpiderweb_Action2(Entity* this) { this->subtimer -= 8; SetAffineInfo(this, 0x200 - this->subtimer, 0x200 - this->subtimer, 0); } - if (this->contactFlags == 0x93) { + if (this->contactFlags == (CONTACT_TAKE_DAMAGE | 0x13)) { this->direction = GetFacingDirection(this, &gPlayerEntity.base); LinearMoveUpdate(this); if (EntityWithinDistance(this, gPlayerEntity.base.x.HALF.HI, gPlayerEntity.base.y.HALF.HI - 6, 0x1c)) { diff --git a/src/object/dirtParticle.c b/src/object/dirtParticle.c index 827456c2..ac7e848e 100644 --- a/src/object/dirtParticle.c +++ b/src/object/dirtParticle.c @@ -101,7 +101,7 @@ void DirtParticle_Init(DirtParticleEntity* this) { void DirtParticle_Action1(DirtParticleEntity* this) { DirtParticleEntity* entity; - if ((super->contactFlags & 0x80) == 0) { + if ((super->contactFlags & CONTACT_TAKE_DAMAGE) == 0) { return; } switch (super->contactFlags & 0x7f) { @@ -128,7 +128,7 @@ void DirtParticle_Action3(DirtParticleEntity* this) { sub_08087B9C, sub_08087B9C, }; - if ((super->contactFlags & 0x80) != 0) { + if ((super->contactFlags & CONTACT_TAKE_DAMAGE) != 0) { gUnk_08120A80[super->subAction](this); } else { super->action = 1; diff --git a/src/object/eyeSwitch.c b/src/object/eyeSwitch.c index 152d511a..60310e5c 100644 --- a/src/object/eyeSwitch.c +++ b/src/object/eyeSwitch.c @@ -50,7 +50,7 @@ void EyeSwitch_Init(EyeSwitchEntity* this) { } void EyeSwitch_Action1(EyeSwitchEntity* this) { - if ((super->contactFlags == 0x95 || super->contactFlags == 0x8e) && + if ((super->contactFlags == (CONTACT_TAKE_DAMAGE | 0x15) || super->contactFlags == (CONTACT_TAKE_DAMAGE | 0xe)) && (DirectionRoundUp(super->contactedEntity->direction) >> 3 == (super->animationState & 3))) { super->action = 2; COLLISION_OFF(super); diff --git a/src/object/fairy.c b/src/object/fairy.c index 871da3dd..38026906 100644 --- a/src/object/fairy.c +++ b/src/object/fairy.c @@ -40,7 +40,7 @@ void Fairy(FairyEntity* this) { Fairy_Init, Fairy_Action1, Fairy_Action2, Fairy_Action3, Fairy_Action4, }; - if (((super->contactFlags & 0x80) != 0)) { + if (((super->contactFlags & CONTACT_TAKE_DAMAGE) != 0)) { switch (super->contactFlags & 0x7f) { case 0x14: super->action = 3; diff --git a/src/object/hittableLever.c b/src/object/hittableLever.c index 8e6b63be..0bf530ac 100644 --- a/src/object/hittableLever.c +++ b/src/object/hittableLever.c @@ -47,7 +47,7 @@ void HittableLever_Init(HittableLeverEntity* this) { } void HittableLever_Idle(HittableLeverEntity* this) { - if (((super->contactFlags & 0x80) != 0) && (this->wasHit == 0)) { + if (((super->contactFlags & CONTACT_TAKE_DAMAGE) != 0) && (this->wasHit == 0)) { this->wasHit = 1; super->type ^= 1; super->iframes = -0x18; diff --git a/src/object/itemOnGround.c b/src/object/itemOnGround.c index dc9d0975..b3f6f045 100644 --- a/src/object/itemOnGround.c +++ b/src/object/itemOnGround.c @@ -63,7 +63,7 @@ void ItemOnGround(ItemOnGroundEntity* this) { static void (*const ItemOnGround_Actions[])(ItemOnGroundEntity*) = { ItemOnGround_Init, ItemOnGround_Action1, ItemOnGround_Action2, ItemOnGround_Action3, ItemOnGround_Action4, }; - if (super->contactFlags & 0x80) { + if (super->contactFlags & CONTACT_TAKE_DAMAGE) { switch (super->contactFlags & 0x7F) { case 20: super->action = 3; diff --git a/src/object/jarPortal.c b/src/object/jarPortal.c index aa94b26f..f2e4f852 100644 --- a/src/object/jarPortal.c +++ b/src/object/jarPortal.c @@ -170,7 +170,7 @@ void JarPortal_Action4(JarPortalEntity* this) { } u32 sub_0808C128(JarPortalEntity* this) { - return super->contactFlags == 157; + return super->contactFlags == (CONTACT_TAKE_DAMAGE | 0x1d); } void sub_0808C13C(JarPortalEntity* this) { diff --git a/src/object/lavaPlatform.c b/src/object/lavaPlatform.c index 5db1f0b9..619bc685 100644 --- a/src/object/lavaPlatform.c +++ b/src/object/lavaPlatform.c @@ -131,7 +131,7 @@ void LavaPlatform_Type1Action1(LavaPlatformEntity* this) { } void LavaPlatform_Type1Action2(LavaPlatformEntity* this) { - if (super->contactFlags == 0x9d) { + if (super->contactFlags == (CONTACT_TAKE_DAMAGE | 0x1d)) { sub_08092620(this); } else { if (LavaPlatform_IsPlayerOnPlatform(this)) { @@ -223,7 +223,7 @@ void LavaPlatform_Type1Action6(LavaPlatformEntity* this) { } void LavaPlatform_Type1Action7(LavaPlatformEntity* this) { - if (super->contactFlags == 0x9d) { + if (super->contactFlags == (CONTACT_TAKE_DAMAGE | 0x1d)) { sub_08092620(this); } } diff --git a/src/object/lightableSwitch.c b/src/object/lightableSwitch.c index 927a4c9d..8c68f708 100644 --- a/src/object/lightableSwitch.c +++ b/src/object/lightableSwitch.c @@ -67,7 +67,7 @@ void LightableSwitch_Type0_Init(LightableSwitchEntity* this) { void LightableSwitch_Type0_Action1(LightableSwitchEntity* this) { - if ((super->contactFlags & 0x80) != 0) { + if ((super->contactFlags & CONTACT_TAKE_DAMAGE) != 0) { if (CheckFlags(this->unk_86) != 0) { ClearFlag(this->unk_86); } else { @@ -147,7 +147,7 @@ void LightableSwitch_Type1_Init(LightableSwitchEntity* this) { } void LightableSwitch_Type1_Action1(LightableSwitchEntity* this) { - if ((super->contactFlags & 0x80) != 0) { + if ((super->contactFlags & CONTACT_TAKE_DAMAGE) != 0) { super->action = 2; super->timer = 16; super->frameIndex = 2; diff --git a/src/object/objectA8.c b/src/object/objectA8.c index 4de9ccae..6f47de25 100644 --- a/src/object/objectA8.c +++ b/src/object/objectA8.c @@ -39,7 +39,7 @@ void ObjectA8(ObjectA8Entity* this) { ObjectA8_Init, ObjectA8_Action1, ObjectA8_Action2, ObjectA8_Action3, ObjectA8_Action4, ObjectA8_Action5, ObjectA8_Action6, }; - if ((super->contactFlags & 0x80) != 0) { + if ((super->contactFlags & CONTACT_TAKE_DAMAGE) != 0) { switch (super->contactFlags & 0x7f) { case 0: case 1: diff --git a/src/object/objectOnSpinyBeetle.c b/src/object/objectOnSpinyBeetle.c index 17597f8f..aa28ae96 100644 --- a/src/object/objectOnSpinyBeetle.c +++ b/src/object/objectOnSpinyBeetle.c @@ -72,7 +72,7 @@ void ObjectOnSpinyBeetle_Action1(ObjectOnSpinyBeetleEntity* this) { sub_080989C0(this); return; } - if ((super->contactFlags & 0x80) != 0) { + if ((super->contactFlags & CONTACT_TAKE_DAMAGE) != 0) { switch (super->contactFlags & 0x3f) { case 0x13: super->action = 3; diff --git a/src/object/sanctuaryStoneTablet.c b/src/object/sanctuaryStoneTablet.c index 31201381..b612f487 100644 --- a/src/object/sanctuaryStoneTablet.c +++ b/src/object/sanctuaryStoneTablet.c @@ -44,7 +44,7 @@ void SanctuaryStoneTablet_Init(SanctuaryStoneTabletEntity* this) { void SanctuaryStoneTablet_Action1(SanctuaryStoneTabletEntity* this) { Entity* fxEnt; - if (super->contactFlags == 0xa1) { + if (super->contactFlags == (CONTACT_TAKE_DAMAGE | 0x21)) { fxEnt = CreateFx(super, FX_MAGIC_STORM, 0); if (fxEnt != NULL) { fxEnt->spritePriority.b0 = 3; diff --git a/src/object/smallIceBlock.c b/src/object/smallIceBlock.c index e5a6c3f1..836dc648 100644 --- a/src/object/smallIceBlock.c +++ b/src/object/smallIceBlock.c @@ -281,7 +281,7 @@ bool32 sub_0809963C(SmallIceBlockEntity* this) { } } } - if (super->contactFlags == 0x87) { + if (super->contactFlags == (CONTACT_TAKE_DAMAGE | 0x7)) { return TRUE; } return FALSE; diff --git a/src/object/unusedSkull.c b/src/object/unusedSkull.c index 204fc9b6..40303016 100644 --- a/src/object/unusedSkull.c +++ b/src/object/unusedSkull.c @@ -49,7 +49,7 @@ void UnusedSkull_Init(UnusedSkullEntity* this) { } void UnusedSkull_Action1(UnusedSkullEntity* this) { - if (super->contactFlags == 0x9c) { + if (super->contactFlags == (CONTACT_TAKE_DAMAGE | 0x1c)) { super->action = 2; super->flags &= ~0x80; CreateFx(super, FX_ICE, 0); |
