Removes Windows-specific API dependencies for pattern scanning

Replaces calls to Windows API functions (GetModuleHandleA) with a void pointer parameter.

Simplifies pattern scanning for loaded modules by removing Windows-specific code and replacing it with a generic approach.
This commit is contained in:
2025-10-13 14:17:30 +03:00
parent ee54e3de34
commit 5646654317
2 changed files with 42 additions and 23 deletions

View File

@@ -19,7 +19,7 @@ namespace omath
{
public:
[[nodiscard]]
static std::optional<std::uintptr_t> scan_for_pattern_in_loaded_module(const std::string_view& module_name,
static std::optional<std::uintptr_t> scan_for_pattern_in_loaded_module(const void* module_base_address,
const std::string_view& pattern);
[[nodiscard]]