Time Freezing Camera (#1787)

Thanks to @bkd89 for the idea!

Co-authored-by: MelonSpeedruns <melonspeedruns@stratobox.net>
This commit is contained in:
MelonSpeedruns
2026-06-05 02:17:06 -04:00
committed by GitHub
parent 8705e75b9d
commit d9d9966f8f
2 changed files with 13 additions and 2 deletions
+2 -2
View File
@@ -75,12 +75,12 @@ namespace dusk {
if (!getSettings().game.debugFlyCam) {
ImGui::BeginDisabled();
}
config::ImGuiCheckbox("Lock Events", getSettings().game.debugFlyCamLockEvents);
config::ImGuiCheckbox("Freeze Time", getSettings().game.debugFlyCamLockEvents);
if (ImGui::IsItemHovered(ImGuiHoveredFlags_AllowWhenDisabled)) {
if (!getSettings().game.debugFlyCam) {
ImGui::SetTooltip("Enable Fly Mode first.");
} else {
ImGui::SetTooltip("Freeze game events while flying.");
ImGui::SetTooltip("Freezes the game while flying.");
}
}
if (!getSettings().game.debugFlyCam) {
+11
View File
@@ -36,9 +36,20 @@ static int fopCam_Execute(camera_class* i_this) {
fapGm_HIO_c::startCpuTimer();
#endif
#if TARGET_PC
if (dusk::getSettings().game.debugFlyCam && dusk::getSettings().game.debugFlyCamLockEvents) {
dScnPly_c::setPauseTimer(1);
ret = fpcMtd_Execute((process_method_class*)i_this->submethod, i_this);
} else {
if (!dComIfGp_isPauseFlag() && !dScnPly_c::isPause()) {
ret = fpcMtd_Execute((process_method_class*)i_this->submethod, i_this);
}
}
#else
if (!dComIfGp_isPauseFlag() && !dScnPly_c::isPause()) {
ret = fpcMtd_Execute((process_method_class*)i_this->submethod, i_this);
}
#endif
#if DEBUG
fapGm_HIO_c::stopCpuTimer("カメラ(計算処理)"); // Camera (computational processing)