mirror of
https://github.com/Mr-X-GTA/YimMenu.git
synced 2025-07-15 15:07:51 +08:00
Add more spoofing options and added clang-format (#1020)
* feat(Spoofing): add spoofing * feat(Spoofing): prepare code for player attach * remove(PlayerAttach): isn't going to work due to netsync architecture * fix(GUI): fix scaling * feat(Project): add clang-format file * feat(Classes): update classes * fix(BlackHole): remove unnecessary cleanup * fix(Formatting): fix formatting for initializer lists * feat(clang-format): Set tab width and 1 space before comment Co-authored-by: Yimura <24669514+Yimura@users.noreply.github.com>
This commit is contained in:
@ -9,8 +9,11 @@ namespace big
|
||||
{
|
||||
if (ImGui::BeginTabItem("DEBUG_TAB_GLOBALS"_T.data()))
|
||||
{
|
||||
if (ImGui::Checkbox("DEBUG_GLOBALS_ENABLE_FREEZING"_T.data(), &g_globals_service->m_running) && g_globals_service->m_running)
|
||||
g_thread_pool->push([&]() { g_globals_service->loop(); });
|
||||
if (ImGui::Checkbox("DEBUG_GLOBALS_ENABLE_FREEZING"_T.data(), &g_globals_service->m_running)
|
||||
&& g_globals_service->m_running)
|
||||
g_thread_pool->push([&]() {
|
||||
g_globals_service->loop();
|
||||
});
|
||||
|
||||
if (components::button("LOAD"_T))
|
||||
g_globals_service->load();
|
||||
@ -27,11 +30,11 @@ namespace big
|
||||
|
||||
if (ImGui::BeginPopupModal("DEBUG_GLOBALS_NEW"_T.data()))
|
||||
{
|
||||
static int base_address = 0;
|
||||
static bool freeze = false;
|
||||
static char name[32] = "";
|
||||
static int(*offsets)[2] = nullptr;
|
||||
static int offset_count = 0;
|
||||
static int base_address = 0;
|
||||
static bool freeze = false;
|
||||
static char name[32] = "";
|
||||
static int(*offsets)[2] = nullptr;
|
||||
static int offset_count = 0;
|
||||
static int previous_offset_count = 0;
|
||||
|
||||
ImGui::Text("DEBUG_GLOBALS_NAME"_T.data());
|
||||
@ -43,12 +46,14 @@ namespace big
|
||||
ImGui::Text("DEBUG_GLOBAL_OFFSET_COUNT"_T.data());
|
||||
ImGui::InputInt("##modal_offset_count", &offset_count);
|
||||
|
||||
if (offset_count < 0) offset_count = 0;
|
||||
else if (offset_count > 10) offset_count = 10;
|
||||
if (offset_count < 0)
|
||||
offset_count = 0;
|
||||
else if (offset_count > 10)
|
||||
offset_count = 10;
|
||||
|
||||
if (offset_count != previous_offset_count)
|
||||
{
|
||||
int(*new_offsets)[2] = new int[offset_count][2]{ 0 };
|
||||
int(*new_offsets)[2] = new int[offset_count][2]{0};
|
||||
memcpy(new_offsets, offsets, sizeof(int) * std::min(offset_count, previous_offset_count) * 2);
|
||||
|
||||
delete[] offsets;
|
||||
@ -80,8 +85,8 @@ namespace big
|
||||
strcpy(name, "");
|
||||
freeze = false;
|
||||
delete[] offsets;
|
||||
offsets = nullptr;
|
||||
offset_count = 0;
|
||||
offsets = nullptr;
|
||||
offset_count = 0;
|
||||
previous_offset_count = 0;
|
||||
|
||||
ImGui::CloseCurrentPopup();
|
||||
@ -97,8 +102,8 @@ namespace big
|
||||
strcpy(name, "");
|
||||
freeze = false;
|
||||
delete[] offsets;
|
||||
offsets = nullptr;
|
||||
offset_count = 0;
|
||||
offsets = nullptr;
|
||||
offset_count = 0;
|
||||
previous_offset_count = 0;
|
||||
|
||||
ImGui::CloseCurrentPopup();
|
||||
|
Reference in New Issue
Block a user