MCPcopy Create free account
hub / github.com/NoMercy-ac/NoMercy / GetPythonHandle

Method GetPythonHandle

Source/Client/NM_Engine/DynamicWinapi.cpp:434–460  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

432}
433
434HMODULE CDynamicWinapi::GetPythonHandle()
435{
436 auto hPython = g_nmApp->DataInstance()->GetPythonHandle();
437 if (hPython)
438 return hPython;
439
440 auto hTmp27 = MyGetModuleHandleA(xorstr("python27.dll").crypt_get());
441 if (hTmp27)
442 {
443 g_nmApp->DataInstance()->SetPythonName(xorstr("python27.dll").crypt_get());
444 g_nmApp->DataInstance()->SetPythonHandle(hTmp27);
445
446 return hTmp27;
447 }
448
449 auto hTmp22 = MyGetModuleHandleA(xorstr("python22.dll").crypt_get());
450 if (hTmp22)
451 {
452 g_nmApp->DataInstance()->SetPythonName(xorstr("python22.dll").crypt_get());
453 g_nmApp->DataInstance()->SetPythonHandle(hTmp22);
454
455 return hTmp22;
456 }
457
458 DEBUG_LOG(LL_CRI, "Unknown python module!");
459 return nullptr;
460}
461
462
463bool CDynamicWinapi::BindBaseAPIs()

Callers

nothing calls this directly

Calls 4

MyGetModuleHandleAFunction · 0.85
DataInstanceMethod · 0.80
SetPythonNameMethod · 0.80
SetPythonHandleMethod · 0.80

Tested by

no test coverage detected