mirror of
https://github.com/Mr-X-GTA/YimMenu.git
synced 2024-12-22 12:07:46 +08:00
Fix early injection (#45)
This commit is contained in:
parent
b7f5729a78
commit
6edc483502
@ -86,6 +86,9 @@ namespace big
|
||||
weapons::m_no_sway_patch = memory::byte_patch::make(g_pointers->m_gta.m_scope_sway_function, std::vector{0xEB}).get();
|
||||
|
||||
memory::byte_patch::make(g_pointers->m_gta.m_report_myself_sender, std::vector{0xC3})->apply();
|
||||
|
||||
// Patch BattlEye network bail
|
||||
memory::byte_patch::make(g_pointers->m_gta.m_be_network_bail_patch, std::to_array({0xC3}))->apply();
|
||||
}
|
||||
|
||||
byte_patch_manager::byte_patch_manager()
|
||||
|
@ -419,6 +419,8 @@ namespace big
|
||||
functions::get_last_keyboard_state m_get_last_keyboard_state;
|
||||
|
||||
PVOID m_network_can_access_multiplayer;
|
||||
|
||||
PVOID m_be_network_bail_patch;
|
||||
};
|
||||
#pragma pack(pop)
|
||||
static_assert(sizeof(gta_pointers) % 8 == 0, "Pointers are not properly aligned");
|
||||
|
@ -1988,6 +1988,15 @@ namespace big
|
||||
{
|
||||
g_pointers->m_gta.m_network_can_access_multiplayer = ptr.add(10).rip().as<PVOID>();
|
||||
}
|
||||
},
|
||||
// BattlEye Network Bail Patch
|
||||
{
|
||||
"BENBP",
|
||||
"83 25 ? ? ? ? 00 89 0D ? ? ? ? 85 C9",
|
||||
[](memory::handle ptr)
|
||||
{
|
||||
g_pointers->m_gta.m_be_network_bail_patch = ptr.add(17).rip().add(1).rip().as<PVOID>();
|
||||
}
|
||||
}
|
||||
>(); // don't leave a trailing comma at the end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user