diff options
| author | Narr the Reg <juangerman-13@hotmail.com> | 2024-01-01 13:56:31 -0600 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-01-01 13:56:31 -0600 |
| commit | 7a478d7b9a64edfc35d6be09a1960cea00522055 (patch) | |
| tree | 3f7ca8e93b7bc523b8dd357ec43d302fd794b37c /src/core/memory/cheat_engine.cpp | |
| parent | 5dbd02ebb15e000aede0b893dc7db3c04a2d5bca (diff) | |
| parent | 0865db645efe76633973670d2d622c7aea776187 (diff) | |
Merge pull request #12454 from liamwhite/ct-stuff
core_timing: minor refactors
Diffstat (limited to 'src/core/memory/cheat_engine.cpp')
| -rw-r--r-- | src/core/memory/cheat_engine.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/core/memory/cheat_engine.cpp b/src/core/memory/cheat_engine.cpp index 3fc4024dc7..7bc5b5ae50 100644 --- a/src/core/memory/cheat_engine.cpp +++ b/src/core/memory/cheat_engine.cpp @@ -190,15 +190,15 @@ CheatEngine::CheatEngine(System& system_, std::vector<CheatEntry> cheats_, } CheatEngine::~CheatEngine() { - core_timing.UnscheduleEvent(event, 0); + core_timing.UnscheduleEvent(event); } void CheatEngine::Initialize() { event = Core::Timing::CreateEvent( "CheatEngine::FrameCallback::" + Common::HexToString(metadata.main_nso_build_id), - [this](std::uintptr_t user_data, s64 time, + [this](s64 time, std::chrono::nanoseconds ns_late) -> std::optional<std::chrono::nanoseconds> { - FrameCallback(user_data, ns_late); + FrameCallback(ns_late); return std::nullopt; }); core_timing.ScheduleLoopingEvent(CHEAT_ENGINE_NS, CHEAT_ENGINE_NS, event); @@ -239,7 +239,7 @@ void CheatEngine::Reload(std::vector<CheatEntry> reload_cheats) { MICROPROFILE_DEFINE(Cheat_Engine, "Add-Ons", "Cheat Engine", MP_RGB(70, 200, 70)); -void CheatEngine::FrameCallback(std::uintptr_t, std::chrono::nanoseconds ns_late) { +void CheatEngine::FrameCallback(std::chrono::nanoseconds ns_late) { if (is_pending_reload.exchange(false)) { vm.LoadProgram(cheats); } |
