diff options
Diffstat (limited to 'runtime/src/main.cpp')
| -rw-r--r-- | runtime/src/main.cpp | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/runtime/src/main.cpp b/runtime/src/main.cpp index 76b180475..4d483ed59 100644 --- a/runtime/src/main.cpp +++ b/runtime/src/main.cpp | |||
| @@ -156,6 +156,7 @@ void start_title_peek(std::uint8_t* base) { | |||
| 156 | #include "mods.h" | 156 | #include "mods.h" |
| 157 | #include "pe_loader.h" | 157 | #include "pe_loader.h" |
| 158 | #include "thread_stacks.h" | 158 | #include "thread_stacks.h" |
| 159 | #include "dev_overlay.h" | ||
| 159 | #include "thread_sampler.h" | 160 | #include "thread_sampler.h" |
| 160 | #include "title_page_watch.h" | 161 | #include "title_page_watch.h" |
| 161 | #include "title_geometry_watch.h" | 162 | #include "title_geometry_watch.h" |
| @@ -612,7 +613,9 @@ int wmain(int argc, wchar_t** argv) { | |||
| 612 | std::fprintf(stderr, "error: %s has no entry point\n", main_module.name.c_str()); | 613 | std::fprintf(stderr, "error: %s has no entry point\n", main_module.name.c_str()); |
| 613 | return 1; | 614 | return 1; |
| 614 | } | 615 | } |
| 615 | const std::wstring paths = L"console paths: GAME: -> " + game_dir.native() + L", writes -> " + overlay_dir.native(); | 616 | const std::filesystem::path scratch_dir = rt::fs::scratch_dir(); |
| 617 | const std::wstring paths = L"console paths: GAME: -> " + game_dir.native() + L", writes -> " + | ||
| 618 | overlay_dir.native() + L", T: -> " + scratch_dir.native(); | ||
| 616 | const HANDLE out = GetStdHandle(STD_OUTPUT_HANDLE); | 619 | const HANDLE out = GetStdHandle(STD_OUTPUT_HANDLE); |
| 617 | DWORD mode; | 620 | DWORD mode; |
| 618 | bool printed = false; | 621 | bool printed = false; |
| @@ -625,13 +628,16 @@ int wmain(int argc, wchar_t** argv) { | |||
| 625 | if (!printed) { | 628 | if (!printed) { |
| 626 | const auto game = game_dir.u8string(); | 629 | const auto game = game_dir.u8string(); |
| 627 | const auto overlay = overlay_dir.u8string(); | 630 | const auto overlay = overlay_dir.u8string(); |
| 628 | std::printf("console paths: GAME: -> %s, writes -> %s\n", | 631 | const auto scratch = scratch_dir.u8string(); |
| 629 | reinterpret_cast<const char*>(game.c_str()), reinterpret_cast<const char*>(overlay.c_str())); | 632 | std::printf("console paths: GAME: -> %s, writes -> %s, T: -> %s\n", |
| 633 | reinterpret_cast<const char*>(game.c_str()), reinterpret_cast<const char*>(overlay.c_str()), | ||
| 634 | reinterpret_cast<const char*>(scratch.c_str())); | ||
| 630 | } | 635 | } |
| 631 | std::printf("running %s\n", main_module.name.c_str()); | 636 | std::printf("running %s\n", main_module.name.c_str()); |
| 632 | std::fflush(stdout); | 637 | std::fflush(stdout); |
| 633 | keep_title_watchdog_kicked(main_module.base); | 638 | keep_title_watchdog_kicked(main_module.base); |
| 634 | start_title_peek(main_module.base); | 639 | start_title_peek(main_module.base); |
| 640 | leonida::dev_overlay::start(); // LEONIDA_DEV_OVERLAY=1 | ||
| 635 | leonida::thread_sampler::start(main_module.base, main_module.size); // LEONIDA_SAMPLE_MS (diagnostic) | 641 | leonida::thread_sampler::start(main_module.base, main_module.size); // LEONIDA_SAMPLE_MS (diagnostic) |
| 636 | #ifdef LEONIDA_VULKAN_DEVICE | 642 | #ifdef LEONIDA_VULKAN_DEVICE |
| 637 | SetConsoleCtrlHandler(&stop_compiles_on_console_exit, TRUE); | 643 | SetConsoleCtrlHandler(&stop_compiles_on_console_exit, TRUE); |