fix: allow unusual loading methods and thread safety improvements

This commit is contained in:
maybegreat48 committed 2025-05-29 21:24:36 -04:00
1 parent 2baa84ba15
commit f8fdf512e3
11 files changed
+70 -25

No files matched your search

+5 -2
View File
@@ -17,6 +17,8 @@
#include "submenus/Debug.hpp"
#include "submenus/World.hpp"
#include "core/filemgr/FileMgr.hpp"
#include "core/memory/ModuleMgr.hpp"
namespace YimMenu
{
void Menu::Init()
@@ -42,7 +44,8 @@ namespace YimMenu
ImGui::SetNextWindowSize(ImVec2((*Pointers.ScreenResX / 2.5), (*Pointers.ScreenResY / 2.5)), ImGuiCond_Once);
if (ImGui::Begin("YimMenuV2", nullptr, ImGuiWindowFlags_NoDecoration))
{
//ImGui::BeginDisabled(*Pointers.IsSessionStarted);
// TODO: should we just remove unload?
ImGui::BeginDisabled(*Pointers.IsSessionStarted || ModuleMgr.IsManualMapped());
if (ImGui::Button("Unload", ImVec2(120, 0)))
{
if (true)
@@ -57,7 +60,7 @@ namespace YimMenu
g_Running = false;
}
}
//ImGui::EndDisabled();
ImGui::EndDisabled();
UIManager::Draw();
}