diff --git a/Binaries/ME3ExplorerInteropME2.asi b/Binaries/ME3ExplorerInteropME2.asi deleted file mode 100644 index 06048ba..0000000 Binary files a/Binaries/ME3ExplorerInteropME2.asi and /dev/null differ diff --git a/ME3ExpInterop/ME3ExpInterop.cpp b/ME3ExpInterop/ME3ExpInterop.cpp index 1ae99c7..2d8ec2c 100644 --- a/ME3ExpInterop/ME3ExpInterop.cpp +++ b/ME3ExpInterop/ME3ExpInterop.cpp @@ -114,7 +114,11 @@ void SendMessageToMe3Explorer(USequenceOp* op) } msgBuffer[writePos] = 0; writePos++; - const auto handle = FindWindow(nullptr, L"ME3Explorer"); + auto handle = FindWindow(nullptr, L"Legendary Explorer"); + if (!handle) + { + handle = FindWindow(nullptr, L"ME3Explorer"); + } if (handle) { constexpr unsigned long SENT_FROM_ME2 = 0x02AC00C3; @@ -294,7 +298,7 @@ void __fastcall HookedPE(UObject* pObject, void* edx, UFunction* pFunction, void GetCamPOV(op); } } - else if (IsA(pObject) && isPartOf(pFunction->GetFullName(), "Function SFXGame.BioPlayerController.PlayerTick")) + else if (IsA(pObject) && strcmp(pFunction->GetName(), "PlayerTick") == 0) { const auto playerController = static_cast(pObject); cachedPOV = playerController->PlayerCamera->CameraCache.POV; @@ -305,8 +309,8 @@ void __fastcall HookedPE(UObject* pObject, void* edx, UFunction* pFunction, void void onAttach() { MH_Initialize(); - MH_CreateHook(reinterpret_cast(ProcessEvent_Orig), HookedPE, reinterpret_cast(ProcessEvent)); - MH_EnableHook(reinterpret_cast(ProcessEvent)); + MH_CreateHook(reinterpret_cast(&ProcessEvent_Orig), HookedPE, ProcessEvent); + MH_EnableHook(ProcessEvent); } BOOL WINAPI DllMain(HMODULE hModule, DWORD dwReason, LPVOID lpReserved) diff --git a/ME3ExpInterop/ME3ExpInterop.vcxproj b/ME3ExpInterop/ME3ExpInterop.vcxproj index 7682749..e8425b7 100644 --- a/ME3ExpInterop/ME3ExpInterop.vcxproj +++ b/ME3ExpInterop/ME3ExpInterop.vcxproj @@ -92,16 +92,15 @@ true WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions) true - MultiThreaded + MultiThreadedDebug false - false + true %(AdditionalIncludeDirectories) Console true $(ProjectDir)..\detours;%(AdditionalLibraryDirectories) - /bigobj %(AdditionalOptions) diff --git a/minhook/minhook.vcxproj b/minhook/minhook.vcxproj index 76e4192..5b82ab7 100644 --- a/minhook/minhook.vcxproj +++ b/minhook/minhook.vcxproj @@ -91,6 +91,7 @@ Use pch.h MultiThreadedDebug + true