Remove buggy Free Camera C-Up

This commit is contained in:
Agent X 2024-03-23 09:18:12 -04:00
parent 7c799d58b7
commit e24a446c05
5 changed files with 3 additions and 40 deletions

View file

@ -358,17 +358,6 @@ static void newcam_rotate_button(void) {
}
newcam_framessincec[1] = 0;
}
if ((gPlayer1Controller->buttonPressed & U_CBUTTONS) && newcam_modeflags & NC_FLAG_YTURN && !(newcam_modeflags & NC_FLAG_8D) && newcam_analogue == 0 && configCameraCUp) {
if (newcam_framessincec[1] < 6 && gMarioState->action & ACT_FLAG_ALLOW_FIRST_PERSON) {
gCameraMovementFlags |= CAM_MOVE_C_UP_MODE;
#ifndef nosound
play_sound(SOUND_MENU_CAMERA_ZOOM_IN, gGlobalSoundSource);
#endif
newcam_init_settings();
return;
}
newcam_framessincec[1] = 0;
}
//There's not much point in keeping this behind a check, but it wouldn't hurt, just incase any 2player shenanigans ever happen, it makes it easy to disable.

View file

@ -2690,27 +2690,9 @@ s32 exit_c_up(struct Camera *c) {
gCameraMovementFlags |= CAM_MOVE_STARTED_EXITING_C_UP;
transition_next_state(c, 15);
} else {
newcam_init_settings();
if (newcam_active == 1) {
// Retrieve the previous position and focus
vec3f_copy(c->pos, sCameraStoreCUp.pos);
vec3f_add(c->pos, sMarioCamState->pos);
vec3f_copy(c->focus, sCameraStoreCUp.focus);
vec3f_add(c->focus, sMarioCamState->pos);
// Make Mario look forward
sMarioCamState->headRotation[0] = 0;
sMarioCamState->headRotation[1] = 0;
// Finished exiting C-Up
gCameraMovementFlags &= ~(CAM_MOVE_STARTED_EXITING_C_UP | CAM_MOVE_C_UP_MODE);
gMarioStates[0].area->camera->mode = CAMERA_MODE_NEWCAM;
gLakituState.mode = CAMERA_MODE_NEWCAM;
} else {
// Let the next camera mode handle it
gCameraMovementFlags &= ~(CAM_MOVE_STARTED_EXITING_C_UP | CAM_MOVE_C_UP_MODE);
vec3f_set_dist_and_angle(checkFoc, c->pos, curDist, curPitch, curYaw + checkYaw);
}
// Let the next camera mode handle it
gCameraMovementFlags &= ~(CAM_MOVE_STARTED_EXITING_C_UP | CAM_MOVE_C_UP_MODE);
vec3f_set_dist_and_angle(checkFoc, c->pos, curDist, curPitch, curYaw + checkYaw);
}
play_sound_cbutton_down();
}
@ -2962,10 +2944,6 @@ void set_camera_mode(struct Camera *c, s16 mode, s16 frames) {
return;
}
if (mode == CAMERA_MODE_C_UP && gLakituState.mode == CAMERA_MODE_NEWCAM) {
newcam_init_settings_override(false);
}
if (mode != CAMERA_MODE_NEWCAM && gLakituState.mode != CAMERA_MODE_NEWCAM) {
if (!(mode == CAMERA_MODE_WATER_SURFACE && gCurrLevelArea == AREA_TTM_OUTSIDE)) {
// Clear movement flags that would affect the transition

View file

@ -114,7 +114,6 @@ bool configCameraInvertX = false;
bool configCameraInvertY = true;
bool configEnableCamera = false;
bool configCameraAnalog = false;
bool configCameraCUp = false;
bool configCameraMouse = false;
// coop-specific
bool configSkipIntro = 0;
@ -212,7 +211,6 @@ static const struct ConfigOption options[] = {
{.name = "rumble_strength", .type = CONFIG_TYPE_UINT, .uintValue = &configRumbleStrength},
{.name = "bettercam_enable", .type = CONFIG_TYPE_BOOL, .boolValue = &configEnableCamera},
{.name = "bettercam_analog", .type = CONFIG_TYPE_BOOL, .boolValue = &configCameraAnalog},
{.name = "bettercam_cup", .type = CONFIG_TYPE_BOOL, .boolValue = &configCameraCUp},
{.name = "bettercam_mouse_look", .type = CONFIG_TYPE_BOOL, .boolValue = &configCameraMouse},
{.name = "bettercam_invertx", .type = CONFIG_TYPE_BOOL, .boolValue = &configCameraInvertX},
{.name = "bettercam_inverty", .type = CONFIG_TYPE_BOOL, .boolValue = &configCameraInvertY},

View file

@ -75,7 +75,6 @@ extern bool configCameraInvertY;
extern bool configEnableCamera;
extern bool configCameraMouse;
extern bool configCameraAnalog;
extern bool configCameraCUp;
extern bool configSkipIntro;
extern bool configBubbleDeath;
extern unsigned int configAmountofPlayers;

View file

@ -15,7 +15,6 @@ void djui_panel_camera_create(struct DjuiBase* caller) {
{
djui_checkbox_create(body, DLANG(CAMERA, FREE_CAMERA), &configEnableCamera, djui_panel_camera_value_changed);
djui_checkbox_create(body, DLANG(CAMERA, ANALOG_CAMERA), &configCameraAnalog, djui_panel_camera_value_changed);
djui_checkbox_create(body, DLANG(CAMERA, C_UP), &configCameraCUp, djui_panel_camera_value_changed);
djui_checkbox_create(body, DLANG(CAMERA, MOUSE_LOOK), &configCameraMouse, djui_panel_camera_value_changed);
djui_checkbox_create(body, DLANG(CAMERA, INVERT_X), &configCameraInvertX, djui_panel_camera_value_changed);
djui_checkbox_create(body, DLANG(CAMERA, INVERT_Y), &configCameraInvertY, djui_panel_camera_value_changed);