Skip to content

Commit

Permalink
Fix targetting camera snap (#382)
Browse files Browse the repository at this point in the history
  • Loading branch information
garrettjoecox authored May 23, 2024
1 parent acc2fcb commit 7f88f17
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 5 additions & 0 deletions mm/2s2h/BenGui/BenMenuBar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,11 @@ void DrawEnhancementsMenu() {
if (UIWidgets::BeginMenu("Enhancements")) {

if (UIWidgets::BeginMenu("Camera")) {
ImGui::SeparatorText("Fixes");
UIWidgets::CVarCheckbox(
"Fix Targetting Camera Snap", "gEnhancements.Camera.FixTargettingCameraSnap",
{ .tooltip =
"Fixes the camera snap that occurs when you are moving and press the targetting button." });
ImGui::SeparatorText("Right Stick Camera");
UIWidgets::CVarCheckbox("Invert Camera X Axis", "gEnhancements.Camera.RightStick.InvertXAxis",
{ .tooltip = "Inverts the Camera X Axis in Free Look." });
Expand Down
3 changes: 2 additions & 1 deletion mm/src/overlays/actors/ovl_player_actor/z_player.c
Original file line number Diff line number Diff line change
Expand Up @@ -4808,7 +4808,8 @@ void func_80832888(Player* this, PlayState* play) {
} else {
this->unk_738--;
}
} else if (this->stateFlags1 & PLAYER_STATE1_20000) {
} else if (this->stateFlags1 & PLAYER_STATE1_20000 &&
!CVarGetInteger("gEnhancements.Camera.FixTargettingCameraSnap", 0)) {
this->unk_738 = 0;
} else if (this->unk_738 != 0) {
this->unk_738--;
Expand Down

0 comments on commit 7f88f17

Please sign in to comment.