LEVELMODE_TURRET

This commit is contained in:
Alejandro Javier Asenjo Nitti 2024-08-15 01:02:52 -03:00
parent e42657e8b5
commit e291a588e5
8 changed files with 14 additions and 14 deletions

View File

@ -54,7 +54,7 @@ typedef enum DrawMode {
typedef enum LevelMode { typedef enum LevelMode {
/* 0 */ LEVELMODE_ON_RAILS, /* 0 */ LEVELMODE_ON_RAILS,
/* 1 */ LEVELMODE_ALL_RANGE, /* 1 */ LEVELMODE_ALL_RANGE,
/* 2 */ LEVELMODE_UNK_2, /* 2 */ LEVELMODE_TURRET, // Unused scrapped turret mode
/* 3 */ LEVELMODE_MAX, /* 3 */ LEVELMODE_MAX,
} LevelMode; } LevelMode;

View File

@ -1890,7 +1890,7 @@ void Display_Update(void) {
} }
} }
if ((gLevelMode == LEVELMODE_UNK_2) && (gPlayer[0].state_1C8 == PLAYERSTATE_1C8_ACTIVE)) { if ((gLevelMode == LEVELMODE_TURRET) && (gPlayer[0].state_1C8 == PLAYERSTATE_1C8_ACTIVE)) {
Turret_Draw(gPlayer); Turret_Draw(gPlayer);
} }

View File

@ -1634,7 +1634,7 @@ void Object_DrawAll(s32 arg0) {
} }
switch (gLevelMode) { switch (gLevelMode) {
case LEVELMODE_ON_RAILS: case LEVELMODE_ON_RAILS:
case LEVELMODE_UNK_2: case LEVELMODE_TURRET:
Matrix_Push(&gGfxMatrix); Matrix_Push(&gGfxMatrix);
if ((gPlayer[0].state_1C8 == PLAYERSTATE_1C8_LEVEL_INTRO) || if ((gPlayer[0].state_1C8 == PLAYERSTATE_1C8_LEVEL_INTRO) ||
(gPlayer[0].state_1C8 == PLAYERSTATE_1C8_LEVEL_COMPLETE) || (gCurrentLevel == LEVEL_AQUAS)) { (gPlayer[0].state_1C8 == PLAYERSTATE_1C8_LEVEL_COMPLETE) || (gCurrentLevel == LEVEL_AQUAS)) {

View File

@ -146,7 +146,7 @@ bool func_enmy_80061148(Vec3f* arg0, f32 arg1) {
void Object_SetInfo(ObjectInfo* info, u32 objId) { void Object_SetInfo(ObjectInfo* info, u32 objId) {
*info = gObjectInfo[objId]; *info = gObjectInfo[objId];
info->hitbox = SEGMENTED_TO_VIRTUAL(gObjectInfo[objId].hitbox); info->hitbox = SEGMENTED_TO_VIRTUAL(gObjectInfo[objId].hitbox);
if (gLevelMode == LEVELMODE_UNK_2) { if (gLevelMode == LEVELMODE_TURRET) {
info->cullDistance += 200.0f; info->cullDistance += 200.0f;
} }
} }

View File

@ -2237,7 +2237,7 @@ void ActorEvent_800701E0(ActorEvent* this) {
func_effect_8007D10C(this->obj.pos.x, this->obj.pos.y, this->obj.pos.z, this->scale * 1.5f); func_effect_8007D10C(this->obj.pos.x, this->obj.pos.y, this->obj.pos.z, this->scale * 1.5f);
} }
if (((gLevelMode == LEVELMODE_ALL_RANGE) || (gLevelMode == LEVELMODE_UNK_2)) && if (((gLevelMode == LEVELMODE_ALL_RANGE) || (gLevelMode == LEVELMODE_TURRET)) &&
(this->eventType != EVID_A6_MISSILE) && (this->eventType != EVID_23)) { (this->eventType != EVID_A6_MISSILE) && (this->eventType != EVID_23)) {
this->fwork[13] = 20.0f; this->fwork[13] = 20.0f;
if (this->obj.pos.x < this->hitPos.x) { if (this->obj.pos.x < this->hitPos.x) {
@ -3362,7 +3362,7 @@ void ActorEvent_Update(ActorEvent* this) {
} }
if (this->iwork[6] != 0) { if (this->iwork[6] != 0) {
if ((gLevelMode == LEVELMODE_UNK_2) && (this->eventType == EVID_200)) { if ((gLevelMode == LEVELMODE_TURRET) && (this->eventType == EVID_200)) {
Math_SmoothStepToAngle(&this->obj.rot.x, this->rot_0F4.x, 0.1f, 10.0f, 0.00001f); Math_SmoothStepToAngle(&this->obj.rot.x, this->rot_0F4.x, 0.1f, 10.0f, 0.00001f);
Math_SmoothStepToAngle(&this->obj.rot.y, this->rot_0F4.y, 0.1f, 10.0f, 0.00001f); Math_SmoothStepToAngle(&this->obj.rot.y, this->rot_0F4.y, 0.1f, 10.0f, 0.00001f);
} else { } else {

View File

@ -3514,7 +3514,7 @@ void func_hud_8008F96C(void) {
RCP_SetupDL_36(); RCP_SetupDL_36();
if ((gLevelMode != LEVELMODE_UNK_2) && (D_hud_80161708 != 0)) { if ((gLevelMode != LEVELMODE_TURRET) && (D_hud_80161708 != 0)) {
func_hud_8008D4F0(246.0f, 28.0f); func_hud_8008D4F0(246.0f, 28.0f);
func_hud_8008EA14(250.0f, 38.0f); func_hud_8008EA14(250.0f, 38.0f);
} }

View File

@ -5422,7 +5422,7 @@ void Player_UpdateEffects(Player* player) {
player->xShake = 0.0f; player->xShake = 0.0f;
} }
if ((gLevelMode != LEVELMODE_UNK_2) && if ((gLevelMode != LEVELMODE_TURRET) &&
((player->knockback.x != 0.f) || (player->knockback.y != 0.f) || (player->knockback.z != 0.f)) && ((player->knockback.x != 0.f) || (player->knockback.y != 0.f) || (player->knockback.z != 0.f)) &&
((player->dmgType >= 40) || (player->dmgType == 21))) { ((player->dmgType >= 40) || (player->dmgType == 21))) {
player->boostCooldown = true; player->boostCooldown = true;
@ -5843,7 +5843,7 @@ void Player_Update(Player* player) {
} }
break; break;
case LEVELMODE_UNK_2: case LEVELMODE_TURRET:
gLoadLevelObjects = true; gLoadLevelObjects = true;
Turret_Update(player); Turret_Update(player);
Player_CollisionCheck(player); Player_CollisionCheck(player);
@ -6531,7 +6531,7 @@ void Camera_Update(Player* player) {
Camera_Update360(player, false); Camera_Update360(player, false);
break; break;
case LEVELMODE_UNK_2: case LEVELMODE_TURRET:
Turret_UpdateCamera(player); Turret_UpdateCamera(player);
break; break;
} }

View File

@ -5,10 +5,10 @@ OSContPad gControllerPress[4];
u8 gControllerPlugged[4]; u8 gControllerPlugged[4];
u32 gControllerLock; u32 gControllerLock;
u8 gControllerRumbleEnabled[4]; u8 gControllerRumbleEnabled[4];
OSContPad sNextController[4]; // OSContPad sNextController[4];
OSContPad sPrevController[4]; // OSContPad sPrevController[4];
OSContStatus sControllerStatus[4]; // OSContStatus sControllerStatus[4];
OSPfs sControllerMotor[4]; // OSPfs sControllerMotor[4];
void Controller_AddDeadZone(s32 contrNum) { void Controller_AddDeadZone(s32 contrNum) {
s32 temp_v0 = gControllerHold[contrNum].stick_x; s32 temp_v0 = gControllerHold[contrNum].stick_x;