Skip to content

Commit

Permalink
Fix JavaHook on badlion
Browse files Browse the repository at this point in the history
Fix JavaHook on badlion
  • Loading branch information
Lefraudeur authored Mar 31, 2024
2 parents d3d2c6f + b38b13e commit f67b33d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Ripterms/Hook/JavaHook.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ bool Ripterms::JavaHook::hook(jmethodID methodID, i2i_detour_t detour)
if (!target)
{
std::cerr << "Failed to find correct i2i hook location\n";
std::cout << "Debug: i2ientry: " << i2i << '\n';
return false;
}
std::cout << "placed i2i hook at: " << (void*)target << '\n';
Expand Down Expand Up @@ -116,7 +117,7 @@ void* find_correct_hook_place(void* _i2i_entry)
};

uint8_t* curr = (uint8_t*)_i2i_entry;
while (curr < (uint8_t*)_i2i_entry + 0x350)
while (curr < (uint8_t*)_i2i_entry + 0x400)
{
int matches = 0;
for (int i = 0; i < sizeof(pattern); ++i)
Expand Down

0 comments on commit f67b33d

Please sign in to comment.