summaryrefslogtreecommitdiff
path: root/src/engine/objects
diff options
context:
space:
mode:
Diffstat (limited to 'src/engine/objects')
-rw-r--r--src/engine/objects/BombKart.cpp2
-rw-r--r--src/engine/objects/Lakitu.cpp30
-rw-r--r--src/engine/objects/Mole.cpp4
-rw-r--r--src/engine/objects/Thwomp.cpp8
4 files changed, 22 insertions, 22 deletions
diff --git a/src/engine/objects/BombKart.cpp b/src/engine/objects/BombKart.cpp
index 3ba60d98a..f5a9f701b 100644
--- a/src/engine/objects/BombKart.cpp
+++ b/src/engine/objects/BombKart.cpp
@@ -149,7 +149,7 @@ void OBombKart::Tick() {
state = States::EXPLODE;
Behaviour = States::EXPLODE;
player->triggers |= VERTICAL_TUMBLE_TRIGGER;
- player->type &= ~0x2000;
+ player->type &= ~PLAYER_START_SEQUENCE;
}
}
} else {
diff --git a/src/engine/objects/Lakitu.cpp b/src/engine/objects/Lakitu.cpp
index a4f580952..be3474cb0 100644
--- a/src/engine/objects/Lakitu.cpp
+++ b/src/engine/objects/Lakitu.cpp
@@ -197,13 +197,13 @@ void OLakitu::func_800791F0(s32 objectIndex, s32 playerId) {
if ((gObjectList[objectIndex].unk_0D8 != 3) && (gObjectList[objectIndex].unk_0D8 != 7)) {
func_800722CC(objectIndex, 1);
if (CM_GetProps()->LakituTowType == LakituTowType::ICE) {
- player->unk_0CA &= 0xFFEF;
+ player->lakituProps &= ~FRIGID_EFFECT;
}
}
if (CM_GetProps()->LakituTowType == LakituTowType::ICE) {
func_800722CC(objectIndex, 0x00000010);
- player->unk_0CA &= 0xFFDF;
+ player->lakituProps &= ~THAWING_EFFECT;
}
func_800C9018(playerId, SOUND_ARG_LOAD(0x01, 0x00, 0xFA, 0x28));
}
@@ -429,10 +429,10 @@ void OLakitu::func_800797AC(s32 playerId) {
objectIndex = gIndexLakituList[playerId];
player = &gPlayerOne[playerId];
- // if ((IsSherbetLand()) && (player->unk_0CA & 1)) {
- if ((CM_GetProps()->LakituTowType == LakituTowType::ICE) && (player->unk_0CA & 1)) {
+ // if ((IsSherbetLand()) && (player->lakituProps & 1)) {
+ if ((CM_GetProps()->LakituTowType == LakituTowType::ICE) && (player->lakituProps & LAKITU_RETRIEVAL)) {
init_object(objectIndex, 7);
- player->unk_0CA |= 0x10;
+ player->lakituProps |= FRIGID_EFFECT;
} else {
init_object(objectIndex, 3);
}
@@ -447,14 +447,14 @@ void OLakitu::func_80079860(s32 playerId) {
player = &gPlayerOne[playerId];
if ((func_80072354(objectIndex, 1) != 0) &&
(((func_802ABDF4(player->collision.meshIndexZX) != 0) && (player->collision.surfaceDistance[2] <= 3.0f)) ||
- (player->unk_0CA & 1) || ((player->surfaceType == OUT_OF_BOUNDS) && !(player->effects & 8)))) {
+ (player->lakituProps & LAKITU_RETRIEVAL) || ((player->surfaceType == OUT_OF_BOUNDS) && !(player->effects & 8)))) {
func_80090778(player);
OLakitu::func_800797AC(playerId);
}
}
void OLakitu::func_8007993C(s32 objectIndex, Player* player) {
- if (player->unk_0CA & 4) {
+ if (player->lakituProps & LAKITU_FIZZLE) {
func_800722A4(objectIndex, 2);
gObjectList[objectIndex].primAlpha = player->alpha;
return;
@@ -544,7 +544,7 @@ void OLakitu::update_object_lakitu_fishing(s32 objectIndex, s32 playerId) {
func_80073654(objectIndex);
break;
case 3:
- if (!(player->unk_0CA & 2)) {
+ if (!(player->lakituProps & HELD_BY_LAKITU)) {
func_80086EAC(objectIndex, 0, 3);
func_80073654(objectIndex);
}
@@ -579,7 +579,7 @@ void OLakitu::update_object_lakitu_fishing2(s32 objectIndex, s32 playerId) {
case 2: /* switch 1 */
set_object_flag(objectIndex, 0x00000010);
func_800736E0(objectIndex);
- player->unk_0CA |= 0x80;
+ player->lakituProps |= FROZEN_EFFECT;
object_next_state(objectIndex);
break;
case 3: /* switch 1 */
@@ -599,11 +599,11 @@ void OLakitu::update_object_lakitu_fishing2(s32 objectIndex, s32 playerId) {
func_80073654(objectIndex);
break;
case 3:
- if ((player->surfaceType == ICE) && !(player->unk_0CA & 1) &&
+ if ((player->surfaceType == ICE) && !(player->lakituProps & LAKITU_RETRIEVAL) &&
((f64) player->collision.surfaceDistance[2] <= 30.0)) {
func_800722A4(objectIndex, 8);
}
- if (!(player->unk_0CA & 2)) {
+ if (!(player->lakituProps & HELD_BY_LAKITU)) {
func_80086EAC(objectIndex, 0, 3);
func_80073654(objectIndex);
}
@@ -612,7 +612,7 @@ void OLakitu::update_object_lakitu_fishing2(s32 objectIndex, s32 playerId) {
func_8007375C(objectIndex, 0x0000001E);
break;
case 5:
- player->unk_0CA &= 0xFF7F;
+ player->lakituProps &= ~FROZEN_EFFECT;
func_800722A4(objectIndex, 0x00000010);
func_800722A4(objectIndex, 0x00000020);
func_800722CC(objectIndex, 4);
@@ -623,8 +623,8 @@ void OLakitu::update_object_lakitu_fishing2(s32 objectIndex, s32 playerId) {
case 6:
if (func_8007375C(objectIndex, 0x000000A0) != 0) {
func_800722CC(objectIndex, 0x00000010);
- player->unk_0CA &= 0xFFEF;
- player->unk_0CA |= 0x20;
+ player->lakituProps &= ~FRIGID_EFFECT;
+ player->lakituProps |= THAWING_EFFECT;
}
break;
case 7:
@@ -633,7 +633,7 @@ void OLakitu::update_object_lakitu_fishing2(s32 objectIndex, s32 playerId) {
case 8:
func_80073720(objectIndex);
func_80072428(objectIndex);
- player->unk_0CA &= 0xFFDF;
+ player->lakituProps &= ~THAWING_EFFECT;
func_800722CC(objectIndex, 1);
func_800C9018((u8) playerId, SOUND_ARG_LOAD(0x01, 0x00, 0xFA, 0x28));
break;
diff --git a/src/engine/objects/Mole.cpp b/src/engine/objects/Mole.cpp
index 8cdfd0599..95c32ca0f 100644
--- a/src/engine/objects/Mole.cpp
+++ b/src/engine/objects/Mole.cpp
@@ -208,13 +208,13 @@ void OMole::func_80081D34(s32 objectIndex) {
for (size_t i = 0; i < D_8018D158; i++, player++, camera++) {
if ((is_obj_flag_status_active(objectIndex, 0x00000200) != 0) && !(player->effects & 0x80000000) &&
(has_collided_with_player(objectIndex, player) != 0)) {
- if ((player->type & 0x8000) && !(player->type & 0x100)) {
+ if ((player->type & PLAYER_EXISTS) && !(player->type & PLAYER_INVISIBLE_OR_BOMB)) {
var_s5 = 1;
object = &gObjectList[objectIndex];
if (is_obj_flag_status_active(objectIndex, 0x04000000) != 0) {
func_80072180();
}
- if (player->effects & 0x200) {
+ if (player->effects & STAR_EFFECT) {
func_800C9060(i, 0x1900A046U);
} else {
player->triggers |= HIGH_TUMBLE_TRIGGER;
diff --git a/src/engine/objects/Thwomp.cpp b/src/engine/objects/Thwomp.cpp
index 4a699c217..1bde243a9 100644
--- a/src/engine/objects/Thwomp.cpp
+++ b/src/engine/objects/Thwomp.cpp
@@ -648,11 +648,11 @@ void OThwomp::func_80080B28(s32 objectIndex, s32 playerId) {
temp_f0 = func_80088F54(objectIndex, player);
if ((temp_f0 <= 9.0) && !(player->effects & 0x04000000) &&
(has_collided_horizontally_with_player(objectIndex, player) != 0)) {
- if ((player->type & 0x8000) && !(player->type & 0x100)) {
- if (!(player->effects & 0x200)) {
+ if ((player->type & PLAYER_EXISTS) && !(player->type & PLAYER_INVISIBLE_OR_BOMB)) {
+ if (!(player->effects & STAR_EFFECT)) {
func_80089474(objectIndex, playerId, 1.4f, 1.1f, SOUND_ARG_LOAD(0x19, 0x00, 0xA0, 0x4C));
} else if (func_80072354(objectIndex, 0x00000040) != 0) {
- if (player->type & 0x1000) {
+ if (player->type & PLAYER_CPU) {
func_800C98B8(player->pos, player->velocity, SOUND_ARG_LOAD(0x19, 0x01, 0xA2, 0x4A));
} else {
func_800C9060((u8) playerId, SOUND_ARG_LOAD(0x19, 0x01, 0xA2, 0x4A));
@@ -668,7 +668,7 @@ void OThwomp::func_80080B28(s32 objectIndex, s32 playerId) {
} else if ((temp_f0 <= 17.5) && (func_80072320(objectIndex, 1) != 0) &&
(is_within_horizontal_distance_of_player(objectIndex, player,
(player->speed * 0.5) + BoundingBoxSize) != 0)) {
- if ((player->type & 0x8000) && !(player->type & 0x100)) {
+ if ((player->type & PLAYER_EXISTS) && !(player->type & PLAYER_INVISIBLE_OR_BOMB)) {
if (is_obj_flag_status_active(objectIndex, 0x04000000) != 0) {
func_80072180();
}