diff options
author | german77 <juangerman-13@hotmail.com> | 2024-02-05 21:19:26 +0100 |
---|---|---|
committer | german77 <juangerman-13@hotmail.com> | 2024-02-05 21:38:26 +0100 |
commit | c52d7cc694047eea48714e8046bb150592d67e56 (patch) | |
tree | c0ba889dba8bf0b3ba73098d1c4a31c6857a8902 /src/core/memory/cheat_engine.cpp | |
parent | Merge pull request #12905 from liamwhite/hwc-release (diff) | |
download | yuzu-c52d7cc694047eea48714e8046bb150592d67e56.tar yuzu-c52d7cc694047eea48714e8046bb150592d67e56.tar.gz yuzu-c52d7cc694047eea48714e8046bb150592d67e56.tar.bz2 yuzu-c52d7cc694047eea48714e8046bb150592d67e56.tar.lz yuzu-c52d7cc694047eea48714e8046bb150592d67e56.tar.xz yuzu-c52d7cc694047eea48714e8046bb150592d67e56.tar.zst yuzu-c52d7cc694047eea48714e8046bb150592d67e56.zip |
Diffstat (limited to 'src/core/memory/cheat_engine.cpp')
-rw-r--r-- | src/core/memory/cheat_engine.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/core/memory/cheat_engine.cpp b/src/core/memory/cheat_engine.cpp index 14d1a3840..f3b8243d5 100644 --- a/src/core/memory/cheat_engine.cpp +++ b/src/core/memory/cheat_engine.cpp @@ -10,6 +10,7 @@ #include "core/hle/kernel/k_page_table.h" #include "core/hle/kernel/k_process.h" #include "core/hle/kernel/k_process_page_table.h" +#include "core/hle/kernel/svc_types.h" #include "core/hle/service/hid/hid_server.h" #include "core/hle/service/sm/sm.h" #include "core/memory.h" @@ -84,6 +85,20 @@ u64 StandardVmCallbacks::HidKeysDown() { return static_cast<u64>(press_state & HID::NpadButton::All); } +void StandardVmCallbacks::PauseProcess() { + if (system.ApplicationProcess()->IsSuspended()) { + return; + } + system.ApplicationProcess()->SetActivity(Kernel::Svc::ProcessActivity::Paused); +} + +void StandardVmCallbacks::ResumeProcess() { + if (!system.ApplicationProcess()->IsSuspended()) { + return; + } + system.ApplicationProcess()->SetActivity(Kernel::Svc::ProcessActivity::Runnable); +} + void StandardVmCallbacks::DebugLog(u8 id, u64 value) { LOG_INFO(CheatEngine, "Cheat triggered DebugLog: ID '{:01X}' Value '{:016X}'", id, value); } |