From 2ee9ba8d50092520f6e86bc6377d7c1633a0fb48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Berkay=20Yi=C4=9Fit?= Date: Tue, 6 Mar 2018 17:04:49 +0300 Subject: [PATCH] Back to public view, this is going to be the last update for a while. --- .gitignore | 5 +- RockportEd/Debug.hpp | 66 ------------------- .../Extensions/DInput8/DI8Extension.cpp | 11 ++-- .../Extensions/InGame Menu/InGameMenu.cpp | 13 ++-- .../InGame Menu/Items/CameraEditor.hpp | 42 ++++++------ .../InGame Menu/Items/CarConfigurator.hpp | 18 ++--- .../InGame Menu/Items/GameplayOptions.hpp | 4 +- .../InGame Menu/Items/LightingEditor.hpp | 2 - .../Items/_LoadInGameMenuItems.hpp | 2 +- .../Extensions/WndProc/FixAnnoyances.hpp | 15 ++--- .../WndProc/WindowedModeImprovements.hpp | 42 ++++++------ .../Extensions/WndProc/WndProcExtensions.hpp | 8 ++- .../Helpers/Game Internals/Data/Variables.h | 4 +- .../Helpers/Game Internals/Gameplay/Camera.h | 18 ++--- .../Helpers/Game Internals/Gameplay/Object.h | 12 ++-- .../Helpers/Game Internals/Gameplay/Player.h | 40 +++++------ .../Helpers/Game Internals/Gameplay/World.h | 2 +- .../Settings/Object/CameraInfoPresetType.hpp | 64 +++++++++--------- .../GameModificationsPreferencesType.hpp | 34 ++++++++++ RockportEd/Helpers/Settings/Settings.cpp | 6 +- .../Helpers/Settings/Type/SettingsType.hpp | 8 ++- RockportEd/Helpers/WndProc/WndProcHook.cpp | 4 +- RockportEd/Helpers/WndProc/WndProcHook.h | 4 +- RockportEd/RockportEd.vcxproj | 3 +- RockportEd/RockportEd.vcxproj.filters | 7 +- RockportEd/dllmain.cpp | 4 +- 26 files changed, 205 insertions(+), 233 deletions(-) delete mode 100644 RockportEd/Debug.hpp create mode 100644 RockportEd/Helpers/Settings/Object/GameModificationsPreferencesType.hpp diff --git a/.gitignore b/.gitignore index 3fc13b3..1ad0494 100644 --- a/.gitignore +++ b/.gitignore @@ -350,4 +350,7 @@ ASALocalRun/ # Executables *.exe *.out -*.app \ No newline at end of file +*.app + +# RockportEd InGameMenu Debug file +RockportEd/Extensions/InGame Menu/Items/Debug.hpp \ No newline at end of file diff --git a/RockportEd/Debug.hpp b/RockportEd/Debug.hpp deleted file mode 100644 index cb0c5d8..0000000 --- a/RockportEd/Debug.hpp +++ /dev/null @@ -1,66 +0,0 @@ -#pragma once -#include "stdafx.h" -#include "Extensions\Extensions.h" - -namespace Extensions { - namespace InGameMenu { - static std::string carNames[6]; - static DWORD carHashes[6]; - static int opponentThing = 0; - static DWORD returnAddress = 0; - static void __declspec(naked) someHook() { - __asm { - push edx - mov edx, eax - pop eax - - push ebx - mov ebx, [opponentThing] - inc[opponentThing] - - mov eax, [carHashes + ebx * 4] - test eax, eax - pop ebx - jne __callFunction - mov eax, edx - - __callFunction : - mov edx, 0x5E8E60 - - push eax - call edx - pop edx - jmp[returnAddress] - } - } - - struct Debug : _BaseInGameMenuItem { - const virtual void loadData() override { - returnAddress = 0x61E1FD + 0x5; - Memory::writeJMP(0x61E1FD, (DWORD)&someHook, true); - for (int i = 0; i < 6; i++) { - carNames[i] = "carHashes id-"; - carNames[i] += std::to_string(i); - } - hasLoadedData = true; - } - const virtual void displayMenu() override { - ImGui::Checkbox("Debug", &isEnabled); - if (isEnabled) { - if (ImGui::Begin("Debug__", &isEnabled, ImGuiWindowFlags_AlwaysAutoResize)) { - ImGui::TextWrapped("MWOnline CarSync-- Race CarModelLoad Hook"); - ImGui::Indent(5.0f); - { - ImGui::InputInt("Last Opponent Id", &opponentThing); - for (int i = 0; i < 6; i++) { - ImGui::InputInt(carNames[i].c_str(), (int*)&carHashes[i], 1, 100, ImGuiInputTextFlags_CharsHexadecimal); - } - } - ImGui::Unindent(5.0f); - } - ImGui::End(); - } - } - }; - } -} \ No newline at end of file diff --git a/RockportEd/Extensions/DInput8/DI8Extension.cpp b/RockportEd/Extensions/DInput8/DI8Extension.cpp index 9e2b196..8c3021a 100644 --- a/RockportEd/Extensions/DInput8/DI8Extension.cpp +++ b/RockportEd/Extensions/DInput8/DI8Extension.cpp @@ -1,25 +1,28 @@ #include "stdafx.h" #include "Extensions\Extensions.h" #include "DI8Extension.h" +#include "Helpers\WndProc\WndProcHook.h" namespace Extensions { namespace DI8 { void WINAPI getDeviceState_Keyboard(HINSTANCE hInstance, DWORD cbData, LPVOID lpvData) { if (cbData == 256) { - if (GameInternals::Data::Variables::isGameWindowInactive() || imguiIO->WantTextInput/* || imguiIO->WantCaptureKeyboard*/) { + if (GameInternals::Data::Variables::isGameWindowInactive() || imguiIO->WantTextInput + /*|| imguiIO->WantCaptureKeyboard*/ || GetForegroundWindow() != Helpers::WndProcHook::windowHandle) { ZeroMemory(lpvData, 256); + return; } } } void WINAPI getDeviceState_Mouse(HINSTANCE hInstance, DWORD cbData, LPVOID lpvData) { DIMOUSESTATE* mouseState = (DIMOUSESTATE*)lpvData; - if (GameInternals::Data::Variables::isGameWindowInactive() || imguiIO->WantCaptureMouse) { - ZeroMemory(mouseState->rgbButtons, 4); + if (GameInternals::Data::Variables::isGameWindowInactive() || imguiIO->WantCaptureMouse + || GetForegroundWindow() != Helpers::WndProcHook::windowHandle) { + ZeroMemory(mouseState->rgbButtons, sizeof(mouseState->rgbButtons)); } } void Init() { - *GameInternals::Data::Variables::gameWindowInactive = true; MirrorHook::DI8::AddExtension( MirrorHook::DI8::DI8Device::Keyboard, MirrorHook::DI8::DI8Extension::GetDeviceState, diff --git a/RockportEd/Extensions/InGame Menu/InGameMenu.cpp b/RockportEd/Extensions/InGame Menu/InGameMenu.cpp index 66bb8d8..d7f83d5 100644 --- a/RockportEd/Extensions/InGame Menu/InGameMenu.cpp +++ b/RockportEd/Extensions/InGame Menu/InGameMenu.cpp @@ -49,7 +49,7 @@ namespace Extensions { void WINAPI beginScene(LPDIRECT3DDEVICE9 pDevice) { if (!isImguiInitialized) { - ImGui_ImplDX9_Init(Hooks::WndProc::windowHandle, pDevice); + ImGui_ImplDX9_Init(Helpers::WndProcHook::windowHandle, pDevice); imguiIO->Fonts->AddFontFromMemoryCompressedTTF(RobotoMedium::RobotoMedium_compressed_data, RobotoMedium::RobotoMedium_compressed_size, 14.0f); imguiIO->FontDefault = NULL; imguiIO->IniFilename = NULL; @@ -68,15 +68,13 @@ namespace Extensions { ImGui::Begin("##Huh", nullptr, ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoInputs); ImGui::TextColored(ImVec4(1.0f, 0.0f, 0.0f, 1.0f), "RockportEd debug build"); ImGui::Bullet(); ImGui::TextWrapped("Menu input <-> game input RETURN(Enter) KeyUp is broken."); - //ImGui::Bullet(); ImGui::TextWrapped("Lighting Editor only works on some save games and is unstable. TODO: Update pointer to a vtable*."); - ImGui::Bullet(); ImGui::TextWrapped("For KuruHS, not meant for any other use."); ImGui::End(); if (isMainWindowVisible) { imguiIO->MouseDrawCursor = imguiIO->WantCaptureMouse; showUserGuide(); - ImGui::SetNextWindowPos(ImVec2(10.0f, 5.0f), ImGuiCond_Once); + ImGui::SetNextWindowPos(ImVec2(5.0f, 5.0f), ImGuiCond_Once); if (ImGui::Begin("RockportEd", nullptr, ImGuiWindowFlags_AlwaysAutoResize)) { for (auto item : items) { if (item->hasLoadedData) { @@ -109,6 +107,11 @@ namespace Extensions { LRESULT CALLBACK wndProcExtension(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam) { if (isImguiInitialized) { + if (uMsg == WM_QUIT) { + ImGui_ImplDX9_Shutdown(); + return FALSE; + } + if (isMainWindowVisible) ImGui_ImplWin32_WndProcHandler(hWnd, uMsg, wParam, lParam); @@ -139,7 +142,7 @@ namespace Extensions { MirrorHook::D3D9::AddExtension(MirrorHook::D3D9::D3D9Extension::BeforeReset, &beforeReset); MirrorHook::D3D9::AddExtension(MirrorHook::D3D9::D3D9Extension::AfterReset, &afterReset); - Hooks::WndProc::addExtension(&wndProcExtension); + Helpers::WndProcHook::addExtension(&wndProcExtension); } } } \ No newline at end of file diff --git a/RockportEd/Extensions/InGame Menu/Items/CameraEditor.hpp b/RockportEd/Extensions/InGame Menu/Items/CameraEditor.hpp index b5a0b28..9cea3f3 100644 --- a/RockportEd/Extensions/InGame Menu/Items/CameraEditor.hpp +++ b/RockportEd/Extensions/InGame Menu/Items/CameraEditor.hpp @@ -27,7 +27,7 @@ namespace Extensions { if (oldCameraIndex != *pActiveCameraIndex || ((oldCameraIndex == *pActiveCameraIndex) && (!pActiveCameraInfo))) { if (GameInternals::Gameplay::Camera::getActiveCameraInfo(pActiveCameraInfo)) { - std::string activeCameraName = pActiveCameraInfo->collectionName; + std::string activeCameraName = pActiveCameraInfo->CollectionName; auto iter = Settings::settingsType.camPresets.find(activeCameraName); if (iter != Settings::settingsType.camPresets.end()) { if (!hasAlreadyLoadedSettings[activeCameraName]) { @@ -44,8 +44,6 @@ namespace Extensions { ImGui::Checkbox("Camera Editor", &isEnabled); if (isEnabled) { - ImGui::SetNextWindowSize(ImVec2(240.0f, 400.0f), ImGuiCond_Once); - ImGui::SetNextWindowPos(ImVec2(10.0f * 2 + 200.0f, 5.0f), ImGuiCond_Once); if (ImGui::Begin("Camera Editor", &isEnabled)) { ImGui::PushItemWidth(-1.0f); if (pActiveCameraIndex) { @@ -53,69 +51,69 @@ namespace Extensions { ImGui::TextWrapped("Camera Index"); ImGui::SameLine(); ImGui::SliderInt("##CameraIndex", pActiveCameraIndex, 0, 6); if (pActiveCameraInfo) { - ImGui::TextWrapped("Camera Name: %s", pActiveCameraInfo->collectionName); + ImGui::TextWrapped("Camera Name: %s", pActiveCameraInfo->CollectionName); ImGui::Checkbox("Advanced options", &showAdvancedOptions); ImGui::SameLine(); ImGui::VerticalSeparator(); ImGui::SameLine(); if (ImGui::Button("Save Preset")) { - Settings::settingsType.camPresets[std::string(pActiveCameraInfo->collectionName)] = pActiveCameraInfo; + Settings::settingsType.camPresets[std::string(pActiveCameraInfo->CollectionName)] = pActiveCameraInfo; Settings::saveSettings(); } ImGui::TextWrapped("Stiffness"); - ImGui::SliderFloat("##CameraStiffness", &pActiveCameraInfo->stiffness[0], 0.0f, 1.0f); + ImGui::SliderFloat("##CameraStiffness", &pActiveCameraInfo->Stiffness[0], 0.0f, 1.0f); if (showAdvancedOptions) { ImGui::Text("STIFFNESS[1]"); ImGui::SameLine(); - ImGui::SliderFloat("##CameraStiffness_1", &pActiveCameraInfo->stiffness[1], 0.0f, 1.0f); + ImGui::SliderFloat("##CameraStiffness_1", &pActiveCameraInfo->Stiffness[1], 0.0f, 1.0f); } ImGui::TextWrapped("Horizontal angle"); - ImGui::SliderFloat("##CameraHorizontalAngle", &pActiveCameraInfo->angle[0], -45.0f, 45.0f, "%.3f deg"); + ImGui::SliderFloat("##CameraHorizontalAngle", &pActiveCameraInfo->Angle[0], -45.0f, 45.0f, "%.3f deg"); if (showAdvancedOptions) { ImGui::Text("ANGLE[1]"); ImGui::SameLine(); - ImGui::SliderFloat("##CameraHorizontalAngle_1", &pActiveCameraInfo->angle[1], -45.0f, 45.0f, "%.3f deg"); + ImGui::SliderFloat("##CameraHorizontalAngle_1", &pActiveCameraInfo->Angle[1], -45.0f, 45.0f, "%.3f deg"); } ImGui::TextWrapped("Distance"); - ImGui::SliderFloat("##CameraDistance", &pActiveCameraInfo->lag[0], -100.0f, 100.0f); + ImGui::SliderFloat("##CameraDistance", &pActiveCameraInfo->Lag[0], -100.0f, 100.0f); if (showAdvancedOptions) { ImGui::Text("LAG[1]"); ImGui::SameLine(); - ImGui::SliderFloat("##CameraDistance_1", &pActiveCameraInfo->lag[1], -100.0f, 100.0f); + ImGui::SliderFloat("##CameraDistance_1", &pActiveCameraInfo->Lag[1], -100.0f, 100.0f); } ImGui::TextWrapped("FOV"); - ImGui::SliderFloat("##CameraFOV", &pActiveCameraInfo->fov[0], 25.0f, 135.0f); + ImGui::SliderFloat("##CameraFOV", &pActiveCameraInfo->FOV[0], 25.0f, 135.0f); if (showAdvancedOptions) { ImGui::Text("FOV[1]"); ImGui::SameLine(); - ImGui::SliderFloat("##CameraFOV_1", &pActiveCameraInfo->fov[1], 25.0f, 135.0f); + ImGui::SliderFloat("##CameraFOV_1", &pActiveCameraInfo->FOV[1], 25.0f, 135.0f); } ImGui::TextWrapped("Height"); - ImGui::SliderFloat("##CameraHeight", &pActiveCameraInfo->height[0], 0.0f, 100.0f); + ImGui::SliderFloat("##CameraHeight", &pActiveCameraInfo->Height[0], 0.0f, 100.0f); if (showAdvancedOptions) { ImGui::Text("HEIGHT[1]"); ImGui::SameLine(); - ImGui::SliderFloat("##CameraHeight_1", &pActiveCameraInfo->height[1], 0.0f, 100.0f); + ImGui::SliderFloat("##CameraHeight_1", &pActiveCameraInfo->Height[1], 0.0f, 100.0f); } ImGui::TextWrapped("Vertical angle"); - ImGui::SliderFloat("##CameraLateOffset", &pActiveCameraInfo->lateOffset[0], -89.0f, 89.0f, "%.3f deg"); + ImGui::SliderFloat("##CameraLateOffset", &pActiveCameraInfo->LateOffset[0], -89.0f, 89.0f, "%.3f deg"); if (showAdvancedOptions) { ImGui::Text("LATEOFFSET[1]"); ImGui::SameLine(); - ImGui::SliderFloat("##CameraLateOffset_1", &pActiveCameraInfo->lateOffset[1], -89.0f, 89.0f); + ImGui::SliderFloat("##CameraLateOffset_1", &pActiveCameraInfo->LateOffset[1], -89.0f, 89.0f); } - ImGui::Checkbox("Tilting", &pActiveCameraInfo->tilting[0]); + ImGui::Checkbox("Tilting", &pActiveCameraInfo->Tilting[0]); if (showAdvancedOptions) { - ImGui::Checkbox("TILTING[1]", &pActiveCameraInfo->tilting[1]); + ImGui::Checkbox("TILTING[1]", &pActiveCameraInfo->Tilting[1]); } - ImGui::Checkbox("Selectable", &pActiveCameraInfo->selectable[0]); + ImGui::Checkbox("Selectable", &pActiveCameraInfo->Selectable[0]); if (showAdvancedOptions) { - ImGui::Checkbox("SELECTABLE[1]", &pActiveCameraInfo->selectable[1]); + ImGui::Checkbox("SELECTABLE[1]", &pActiveCameraInfo->Selectable[1]); } } else { ImGui::PushStyleColor(ImGuiCol_Text, ImVec4(1.0f, 0.0f, 0.0f, 1.0f)); - ImGui::TextWrapped("CameraInfo not yet initialized by the game."); + ImGui::TextWrapped("No active CameraInfo was found."); ImGui::PopStyleColor(); } } else { diff --git a/RockportEd/Extensions/InGame Menu/Items/CarConfigurator.hpp b/RockportEd/Extensions/InGame Menu/Items/CarConfigurator.hpp index cfebc16..fc10dca 100644 --- a/RockportEd/Extensions/InGame Menu/Items/CarConfigurator.hpp +++ b/RockportEd/Extensions/InGame Menu/Items/CarConfigurator.hpp @@ -26,21 +26,21 @@ namespace Extensions { ImGui::TextWrapped("Object Data"); ImGui::Indent(5.0f); { - ImGui::SliderFloat("Gravity", &carObjectData->gravity, 0.1f, 3500.0f); - ImGui::SliderFloat("Grip", &carObjectData->grip, 0.0001f, 0.003f, "%.6f"); + ImGui::SliderFloat("Gravity", &carObjectData->Gravity, 0.1f, 3500.0f); + ImGui::SliderFloat("Grip", &carObjectData->Grip, 0.0001f, 0.003f, "%.6f"); } ImGui::Unindent(5.0f); ImGui::TextWrapped("Physics Tuning"); ImGui::Indent(5.0f); { - ImGui::SliderFloat("Steering", &carPhysicsTuning.steering, -10.0f, 10.0f); - ImGui::SliderFloat("Handling", &carPhysicsTuning.handling, -10.0f, 10.0f); - ImGui::SliderFloat("Brakes", &carPhysicsTuning.brakes, -10.0f, 10.0f); - ImGui::SliderFloat("Ride Height", &carPhysicsTuning.rideHeight, -10.0f, 10.0f); - ImGui::SliderFloat("Aerodynamics", &carPhysicsTuning.aerodynamics, -10.0f, 10.0f); - ImGui::SliderFloat("NOS", &carPhysicsTuning.nos, -10.0f, 10.0f); - ImGui::SliderFloat("Turbo", &carPhysicsTuning.turbo, -10.0f, 10.0f); + ImGui::SliderFloat("Steering", &carPhysicsTuning.Steering, -10.0f, 10.0f); + ImGui::SliderFloat("Handling", &carPhysicsTuning.Handling, -10.0f, 10.0f); + ImGui::SliderFloat("Brakes", &carPhysicsTuning.Brakes, -10.0f, 10.0f); + ImGui::SliderFloat("Ride Height", &carPhysicsTuning.RideHeight, -10.0f, 10.0f); + ImGui::SliderFloat("Aerodynamics", &carPhysicsTuning.Aerodynamics, -10.0f, 10.0f); + ImGui::SliderFloat("NOS", &carPhysicsTuning.NOS, -10.0f, 10.0f); + ImGui::SliderFloat("Turbo", &carPhysicsTuning.Turbo, -10.0f, 10.0f); if (ImGui::Button("Apply") || autoUpdate) { GameInternals::Gameplay::Player::Car::setCarPhysicsTuning(&carPhysicsTuning); if (!autoUpdate) diff --git a/RockportEd/Extensions/InGame Menu/Items/GameplayOptions.hpp b/RockportEd/Extensions/InGame Menu/Items/GameplayOptions.hpp index 435fbbc..44dda1e 100644 --- a/RockportEd/Extensions/InGame Menu/Items/GameplayOptions.hpp +++ b/RockportEd/Extensions/InGame Menu/Items/GameplayOptions.hpp @@ -15,7 +15,6 @@ namespace Extensions { const virtual void displayMenu() override { ImGui::Checkbox("Gameplay Options", &isEnabled); if (isEnabled) { - ImGui::SetNextWindowPos(ImVec2(10.0f, 5.0f * 2 + 100.0f), ImGuiCond_Once); if (ImGui::Begin("Gameplay Options", &isEnabled)) { ImGui::PushItemWidth(-1.0f); @@ -25,8 +24,7 @@ namespace Extensions { trafficRefreshInterval = GameInternals::Gameplay::Variables::getTrafficRefreshIntervalAsPointer(); if (trafficRefreshInterval) { ImGui::SliderFloat("##TrafficRefreshInterval", trafficRefreshInterval, 1.0f, 640.0f); - } - else { + } else { ImGui::PushStyleColor(ImGuiCol_Text, ImVec4(1.0f, 0.0f, 0.0f, 1.0f)); ImGui::TextWrapped("Traffic AI not yet initialized by the game."); ImGui::PopStyleColor(); diff --git a/RockportEd/Extensions/InGame Menu/Items/LightingEditor.hpp b/RockportEd/Extensions/InGame Menu/Items/LightingEditor.hpp index 00c1e6c..afb9f32 100644 --- a/RockportEd/Extensions/InGame Menu/Items/LightingEditor.hpp +++ b/RockportEd/Extensions/InGame Menu/Items/LightingEditor.hpp @@ -96,8 +96,6 @@ namespace Extensions { curLighting_pt1 = Memory::readPointer(0x5B392C, 1, 0xC4); curLighting_pt2 = Memory::readPointer(0x5B392C, 1, 0xC8); if (curLighting_pt1 && curLighting_pt2) { - ImGui::SetNextWindowSize(ImVec2(280.0f, 395.0f), ImGuiCond_Once); - ImGui::SetNextWindowPos(ImVec2(10.0f * 3 + 200.0f + 240.0f, 5.0f), ImGuiCond_Once); if (ImGui::Begin("Time of Day Lighting Editor", &isEnabled)) { if (!todInstance) todInstance = *(TimeOfDayLighting**)(*curLighting_pt1 + 0x18); diff --git a/RockportEd/Extensions/InGame Menu/Items/_LoadInGameMenuItems.hpp b/RockportEd/Extensions/InGame Menu/Items/_LoadInGameMenuItems.hpp index 61e1e9e..34d9e18 100644 --- a/RockportEd/Extensions/InGame Menu/Items/_LoadInGameMenuItems.hpp +++ b/RockportEd/Extensions/InGame Menu/Items/_LoadInGameMenuItems.hpp @@ -1,7 +1,7 @@ #pragma once #include "stdafx.h" #include "Extensions\InGame Menu\InGameMenu.h" -#include "Debug.hpp" +//#include "Debug.hpp" #include "CarConfigurator.hpp" #include "CameraEditor.hpp" #include "GameplayOptions.hpp" diff --git a/RockportEd/Extensions/WndProc/FixAnnoyances.hpp b/RockportEd/Extensions/WndProc/FixAnnoyances.hpp index 490bc02..ac9aa9b 100644 --- a/RockportEd/Extensions/WndProc/FixAnnoyances.hpp +++ b/RockportEd/Extensions/WndProc/FixAnnoyances.hpp @@ -1,29 +1,26 @@ #pragma once #include "stdafx.h" +#include "Extensions\Extensions.h" +// Helpers #include "Helpers\WndProc\WndProcHook.h" namespace Extensions { namespace WndProc { namespace FixAnnoyances { - // TODO: Expose on SettingsType - static bool disableAltMenu = true; - static bool disableStopOnFocusLoss = false; - static bool disableWindowsMouse = true; - static LRESULT CALLBACK wndProcExtension(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam) { switch (uMsg) { case WM_SYSCOMMAND: - if ((wParam & 0xFFF0) == SC_KEYMENU && disableAltMenu) { + if ((wParam & 0xFFF0) == SC_KEYMENU && Settings::settingsType.preferences.WindowedModePreferences.DisableAltMenu) { return TRUE; } break; case WM_ACTIVATEAPP: - if (wParam == FALSE && disableStopOnFocusLoss) { + if (wParam == FALSE && !Settings::settingsType.preferences.PauseGameplayOnOnFocusLoss) { return TRUE; } break; case WM_SETCURSOR: - if (LOWORD(lParam) == HTCLIENT && disableWindowsMouse) { + if (LOWORD(lParam) == HTCLIENT && Settings::settingsType.preferences.WindowedModePreferences.DisableWindowsMouse) { SetCursor(NULL); return TRUE; } @@ -33,7 +30,7 @@ namespace Extensions { } static void Init() { - Hooks::WndProc::addExtension(&wndProcExtension); + Helpers::WndProcHook::addExtension(&wndProcExtension); } } } diff --git a/RockportEd/Extensions/WndProc/WindowedModeImprovements.hpp b/RockportEd/Extensions/WndProc/WindowedModeImprovements.hpp index dacdae1..b22c4ed 100644 --- a/RockportEd/Extensions/WndProc/WindowedModeImprovements.hpp +++ b/RockportEd/Extensions/WndProc/WindowedModeImprovements.hpp @@ -47,7 +47,7 @@ namespace Extensions { static float flt3 = 0.00f; static const WORD dx = 16400; - static void hkFovFix() { + static void hkFOVFix() { static DWORD dummyVar; __asm { mov eax, [edi + 0x60] @@ -57,16 +57,14 @@ namespace Extensions { flt1 = hor3DScale; flt2 = f06; flt3 = f1234; - } - else { + } else { if (dummyVar > 10) { flt1 = f1; flt2 = 0.5f; flt3 = 1.0f; _asm fld ds : f1 return; - } - else { + } else { flt1 = 1.0f; flt2 = 0.5f; flt3 = 1.0f; @@ -79,7 +77,7 @@ namespace Extensions { _asm fld ds : ver3DScale } static void Init() { - Memory::writeCall(0x2CF4EA, (DWORD)hkFovFix, false); + Memory::writeCall(0x2CF4EA, (DWORD)hkFOVFix, false); Memory::writeRaw(0x2CF4EF, false, 4, 0x90, 0x83, 0xF9, 0x01); Memory::writeNop(0x2CF4F3, 3, false); @@ -192,14 +190,14 @@ namespace Extensions { static LRESULT CALLBACK wndProcExtension(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam) { switch (uMsg) { case WM_SIZE: - { - updateValues((float)LOWORD(lParam), (float)HIWORD(lParam)); + { + updateValues((float)LOWORD(lParam), (float)HIWORD(lParam)); - isResizing = true; - GameInternals::Data::Variables::setDrawHUD(false); - GameInternals::Data::Variables::setResetGameWindow(true); - } - return TRUE; + isResizing = true; + GameInternals::Data::Variables::setDrawHUD(false); + GameInternals::Data::Variables::setResetGameWindow(true); + } + return TRUE; } return FALSE; } @@ -214,17 +212,17 @@ namespace Extensions { static void Init() { if (*(bool*)Memory::makeAbsolute(0x53E84C)) { RECT o_cRect, n_cRect, n_wRect; - GetClientRect(Hooks::WndProc::windowHandle, &o_cRect); + GetClientRect(Helpers::WndProcHook::windowHandle, &o_cRect); // Change style - DWORD wStyle = GetWindowLongPtr(Hooks::WndProc::windowHandle, GWL_STYLE) | WS_OVERLAPPEDWINDOW; - SetWindowLongPtr(Hooks::WndProc::windowHandle, GWL_STYLE, wStyle); + DWORD wStyle = GetWindowLongPtr(Helpers::WndProcHook::windowHandle, GWL_STYLE) | WS_OVERLAPPEDWINDOW; + SetWindowLongPtr(Helpers::WndProcHook::windowHandle, GWL_STYLE, wStyle); // Refresh window - SetWindowPos(Hooks::WndProc::windowHandle, NULL, 0, 0, 0, 0, SWP_NOZORDER | SWP_NOMOVE | SWP_NOSIZE | SWP_DRAWFRAME); + SetWindowPos(Helpers::WndProcHook::windowHandle, NULL, 0, 0, 0, 0, SWP_NOZORDER | SWP_NOMOVE | SWP_NOSIZE | SWP_DRAWFRAME); // Correct window<->client size diff - GetWindowRect(Hooks::WndProc::windowHandle, &n_wRect); - GetClientRect(Hooks::WndProc::windowHandle, &n_cRect); + GetWindowRect(Helpers::WndProcHook::windowHandle, &n_wRect); + GetClientRect(Helpers::WndProcHook::windowHandle, &n_cRect); int n_wWidth = n_wRect.right - n_wRect.left; int n_wHeight = n_wRect.bottom - n_wRect.top; int dif_cWidth = o_cRect.right - n_cRect.right; @@ -232,16 +230,16 @@ namespace Extensions { int newWidth = n_wWidth + dif_cWidth; int newHeight = n_wHeight + dif_cHeight; // Resize window - SetWindowPos(Hooks::WndProc::windowHandle, HWND_TOP, 0, 0, newWidth, newHeight, SWP_NOMOVE | SWP_DRAWFRAME); + SetWindowPos(Helpers::WndProcHook::windowHandle, HWND_TOP, 0, 0, newWidth, newHeight, SWP_NOMOVE | SWP_DRAWFRAME); // TODO: Handle race condition with WSFix // Cannot trust `HANDLE asiFile = FindFirstFile("*.asi", fd);` from ThirteenAG's ASI loader because the user might not be using it RECT clientRect = { 0 }; - GetClientRect(Hooks::WndProc::windowHandle, &clientRect); + GetClientRect(Helpers::WndProcHook::windowHandle, &clientRect); updateValues((float)clientRect.right, (float)clientRect.bottom); WSFixCode::Init(); - Hooks::WndProc::addExtension(&wndProcExtension); + Helpers::WndProcHook::addExtension(&wndProcExtension); MirrorHook::D3D9::AddExtension(MirrorHook::D3D9::D3D9Extension::AfterReset, &reset); } } diff --git a/RockportEd/Extensions/WndProc/WndProcExtensions.hpp b/RockportEd/Extensions/WndProc/WndProcExtensions.hpp index ab2ad23..10e9940 100644 --- a/RockportEd/Extensions/WndProc/WndProcExtensions.hpp +++ b/RockportEd/Extensions/WndProc/WndProcExtensions.hpp @@ -1,6 +1,7 @@ #pragma once #include "stdafx.h" -// Extension base +#include "Extensions\Extensions.h" +// Helpers #include "Helpers\WndProc\WndProcHook.h" // Extensions #include "FixAnnoyances.hpp" @@ -9,11 +10,12 @@ namespace Extensions { namespace WndProc { static void InitAll() { - while (!Hooks::WndProc::windowHandle) { + while (!Helpers::WndProcHook::windowHandle) { Sleep(100); } FixAnnoyances::Init(); - WindowedModeImprovements::Init(); + if (Settings::settingsType.preferences.WindowedModePreferences.EnableWindowedModeImprovements) + WindowedModeImprovements::Init(); } } } \ No newline at end of file diff --git a/RockportEd/Helpers/Game Internals/Data/Variables.h b/RockportEd/Helpers/Game Internals/Data/Variables.h index 1382e13..a8dbec2 100644 --- a/RockportEd/Helpers/Game Internals/Data/Variables.h +++ b/RockportEd/Helpers/Game Internals/Data/Variables.h @@ -7,8 +7,8 @@ namespace GameInternals { static bool* fadeScreenOn = (bool*)(0x51CAE4 + 0x400000); // FadeScreen::IsFadeScreenOn static bool* resetGameWindow = (bool*)(0x582C39 + 0x400000); static bool* gameWindowInactive = (bool*)(0x582C50 + 0x400000); - //broken, doesn't work if player doesn't use the first save file slot... static bool* gameplayActive = (bool*)(0x4F40C4 + 0x400000); - //broken, doesn't work if player doesn't use the first save file slot... static bool* gameplayAccessed = (bool*)(0x51CD38 + 0x400000); + //broken, doesn't work if the player doesn't use the first save file slot... static bool* gameplayActive = (bool*)(0x4F40C4 + 0x400000); + //broken, doesn't work if the player doesn't use the first save file slot... static bool* gameplayAccessed = (bool*)(0x51CD38 + 0x400000); static bool* drawHUD = (bool*)(0x17CAA8 + 0x400000); // really ghetto way, this is actually an assigment in a function static bool isFadeScreenOn() { diff --git a/RockportEd/Helpers/Game Internals/Gameplay/Camera.h b/RockportEd/Helpers/Game Internals/Gameplay/Camera.h index f8e6c1b..8b418a9 100644 --- a/RockportEd/Helpers/Game Internals/Gameplay/Camera.h +++ b/RockportEd/Helpers/Game Internals/Gameplay/Camera.h @@ -7,22 +7,22 @@ namespace GameInternals { struct CameraInfo { _CAMERA_INFO_ARRAY_DESCRIPTOR(STIFFNESS); - float stiffness[2]; + float Stiffness[2]; _CAMERA_INFO_ARRAY_DESCRIPTOR(ANGLE); - float angle[2]; + float Angle[2]; _CAMERA_INFO_ARRAY_DESCRIPTOR(LAG); - float lag[2]; + float Lag[2]; _CAMERA_INFO_ARRAY_DESCRIPTOR(FOV); - float fov[2]; + float FOV[2]; _CAMERA_INFO_ARRAY_DESCRIPTOR(HEIGHT); - float height[2]; + float Height[2]; _CAMERA_INFO_ARRAY_DESCRIPTOR(LATEOFFSET); - float lateOffset[2]; - char* collectionName; + float LateOffset[2]; + char* CollectionName; _CAMERA_INFO_ARRAY_DESCRIPTOR(TILTING); - bool tilting[2]; + bool Tilting[2]; _CAMERA_INFO_ARRAY_DESCRIPTOR(SELECTABLE); - bool selectable[2]; + bool Selectable[2]; }; namespace Gameplay { diff --git a/RockportEd/Helpers/Game Internals/Gameplay/Object.h b/RockportEd/Helpers/Game Internals/Gameplay/Object.h index 112a89a..94bd8d9 100644 --- a/RockportEd/Helpers/Game Internals/Gameplay/Object.h +++ b/RockportEd/Helpers/Game Internals/Gameplay/Object.h @@ -12,22 +12,22 @@ namespace GameInternals { float z_Position; float x_Position; - BYTE unk1; - BYTE unk2; - BYTE unk3; - BYTE unk4; + BYTE __unk1; + BYTE __unk2; + BYTE __unk3; + BYTE __unk4; float y_Velocity; float z_Velocity; float x_Velocity; - float gravity; + float Gravity; float y_LiftForce; float angular_Velocity; float x_LiftForce; - float grip; + float Grip; }; namespace Gameplay { diff --git a/RockportEd/Helpers/Game Internals/Gameplay/Player.h b/RockportEd/Helpers/Game Internals/Gameplay/Player.h index e0841bb..aced3e0 100644 --- a/RockportEd/Helpers/Game Internals/Gameplay/Player.h +++ b/RockportEd/Helpers/Game Internals/Gameplay/Player.h @@ -4,25 +4,25 @@ namespace GameInternals { struct CarPhysicsTuning { - float steering = 0.0f; - float handling = 0.0f; - float brakes = 0.0f; - float rideHeight = 0.0f; - float aerodynamics = 0.0f; - float nos = 0.0f; - float turbo = 0.0f; + float Steering = 0.0f; + float Handling = 0.0f; + float Brakes = 0.0f; + float RideHeight = 0.0f; + float Aerodynamics = 0.0f; + float NOS = 0.0f; + float Turbo = 0.0f; }; struct CarPowerData { - /* struct align */ BYTE unk[11 * 0x4]; - float alignedCurrentRPM; // 0x2C - /* struct align */ BYTE unk2[1 * 0x4]; - float minimumRPM; // 0x34 - float maximumPossibleRPM; // 0x38 - float maximumRPM; // 0x3C - float currentPedalInputPercentage; // 0x40 - /* struct align */ BYTE unk3[19 * 0x4]; - int currentGear; // 0x8C - int lastGear; // 0x90 + /* struct align */ BYTE __unk[11 * 0x4]; + float AlignedCurrentRPM; // 0x2C + /* struct align */ BYTE __unk2[1 * 0x4]; + float MinimumRPM; // 0x34 + float MaximumPossibleRPM; // 0x38 + float MaximumRPM; // 0x3C + float CurrentPedalInputPercentage; // 0x40 + /* struct align */ BYTE __unk3[19 * 0x4]; + int CurrentGear; // 0x8C + int LastGear; // 0x90 }; enum class SpeedUnit : BYTE { @@ -63,8 +63,8 @@ namespace GameInternals { return -1.0f; return max( - (cpd->alignedCurrentRPM / 10000.0f) * cpd->maximumRPM, - cpd->minimumRPM + (cpd->AlignedCurrentRPM / 10000.0f) * cpd->MaximumRPM, + cpd->MinimumRPM ); } @@ -92,7 +92,7 @@ namespace GameInternals { return p ? *p : -1.0f; } - static void setCarPhysicsTuning(const CarPhysicsTuning* newCarPhysicsTuning) { + static void setCarPhysicsTuning(const CarPhysicsTuning* newCarPhysicsTuning) { __asm { push eax push ebx diff --git a/RockportEd/Helpers/Game Internals/Gameplay/World.h b/RockportEd/Helpers/Game Internals/Gameplay/World.h index 72fb23b..c64d391 100644 --- a/RockportEd/Helpers/Game Internals/Gameplay/World.h +++ b/RockportEd/Helpers/Game Internals/Gameplay/World.h @@ -13,7 +13,7 @@ namespace GameInternals { float FogSkyColourScale; float EnvSkyBrightness; float CarSpecScale; - BYTE unk[0x4 * 3]; + BYTE __unk[0x4 * 3]; float FogSkyColour[4]; }; diff --git a/RockportEd/Helpers/Settings/Object/CameraInfoPresetType.hpp b/RockportEd/Helpers/Settings/Object/CameraInfoPresetType.hpp index 6659c07..ab954d3 100644 --- a/RockportEd/Helpers/Settings/Object/CameraInfoPresetType.hpp +++ b/RockportEd/Helpers/Settings/Object/CameraInfoPresetType.hpp @@ -7,48 +7,48 @@ #include struct CameraInfoPreset { - float stiffness[2]; - float angle[2]; - float lag[2]; - float fov[2]; - float height[2]; - float lateOffset[2]; - bool tilting[2]; - bool selectable[2]; + float Stiffness[2]; + float Angle[2]; + float Lag[2]; + float FOV[2]; + float Height[2]; + float LateOffset[2]; + bool Tilting[2]; + bool Selectable[2]; void loadToCameraInfo(GameInternals::CameraInfo* cameraInfoInstance) { - memcpy_s(cameraInfoInstance->stiffness, sizeof(float) * 2, stiffness, sizeof(float) * 2); - memcpy_s(cameraInfoInstance->angle, sizeof(float) * 2, angle, sizeof(float) * 2); - memcpy_s(cameraInfoInstance->lag, sizeof(float) * 2, lag, sizeof(float) * 2); - memcpy_s(cameraInfoInstance->fov, sizeof(float) * 2, fov, sizeof(float) * 2); - memcpy_s(cameraInfoInstance->height, sizeof(float) * 2, height, sizeof(float) * 2); - memcpy_s(cameraInfoInstance->lateOffset, sizeof(float) * 2, lateOffset, sizeof(float) * 2); - memcpy_s(cameraInfoInstance->tilting, sizeof(bool) * 2, tilting, sizeof(bool) * 2); - memcpy_s(cameraInfoInstance->selectable, sizeof(bool) * 2, selectable, sizeof(bool) * 2); + memcpy_s(cameraInfoInstance->Stiffness, sizeof(float) * 2, Stiffness, sizeof(float) * 2); + memcpy_s(cameraInfoInstance->Angle, sizeof(float) * 2, Angle, sizeof(float) * 2); + memcpy_s(cameraInfoInstance->Lag, sizeof(float) * 2, Lag, sizeof(float) * 2); + memcpy_s(cameraInfoInstance->FOV, sizeof(float) * 2, FOV, sizeof(float) * 2); + memcpy_s(cameraInfoInstance->Height, sizeof(float) * 2, Height, sizeof(float) * 2); + memcpy_s(cameraInfoInstance->LateOffset, sizeof(float) * 2, LateOffset, sizeof(float) * 2); + memcpy_s(cameraInfoInstance->Tilting, sizeof(bool) * 2, Tilting, sizeof(bool) * 2); + memcpy_s(cameraInfoInstance->Selectable, sizeof(bool) * 2, Selectable, sizeof(bool) * 2); } CameraInfoPreset& operator=(GameInternals::CameraInfo* cameraInfoInstance) { - memcpy_s(stiffness, sizeof(float) * 2, cameraInfoInstance->stiffness, sizeof(float) * 2); - memcpy_s(angle, sizeof(float) * 2, cameraInfoInstance->angle, sizeof(float) * 2); - memcpy_s(lag, sizeof(float) * 2, cameraInfoInstance->lag, sizeof(float) * 2); - memcpy_s(fov, sizeof(float) * 2, cameraInfoInstance->fov, sizeof(float) * 2); - memcpy_s(height, sizeof(float) * 2, cameraInfoInstance->height, sizeof(float) * 2); - memcpy_s(lateOffset, sizeof(float) * 2, cameraInfoInstance->lateOffset, sizeof(float) * 2); - memcpy_s(tilting, sizeof(bool) * 2, cameraInfoInstance->tilting, sizeof(bool) * 2); - memcpy_s(selectable, sizeof(bool) * 2, cameraInfoInstance->selectable, sizeof(bool) * 2); + memcpy_s(Stiffness, sizeof(float) * 2, cameraInfoInstance->Stiffness, sizeof(float) * 2); + memcpy_s(Angle, sizeof(float) * 2, cameraInfoInstance->Angle, sizeof(float) * 2); + memcpy_s(Lag, sizeof(float) * 2, cameraInfoInstance->Lag, sizeof(float) * 2); + memcpy_s(FOV, sizeof(float) * 2, cameraInfoInstance->FOV, sizeof(float) * 2); + memcpy_s(Height, sizeof(float) * 2, cameraInfoInstance->Height, sizeof(float) * 2); + memcpy_s(LateOffset, sizeof(float) * 2, cameraInfoInstance->LateOffset, sizeof(float) * 2); + memcpy_s(Tilting, sizeof(bool) * 2, cameraInfoInstance->Tilting, sizeof(bool) * 2); + memcpy_s(Selectable, sizeof(bool) * 2, cameraInfoInstance->Selectable, sizeof(bool) * 2); return *this; } template void serialize(Archive& archive) { archive( - CEREAL_NVP(stiffness), - CEREAL_NVP(angle), - CEREAL_NVP(lag), - CEREAL_NVP(fov), - CEREAL_NVP(height), - CEREAL_NVP(lateOffset), - CEREAL_NVP(tilting), - CEREAL_NVP(selectable) + CEREAL_NVP(Stiffness), + CEREAL_NVP(Angle), + CEREAL_NVP(Lag), + CEREAL_NVP(FOV), + CEREAL_NVP(Height), + CEREAL_NVP(LateOffset), + CEREAL_NVP(Tilting), + CEREAL_NVP(Selectable) ); } }; diff --git a/RockportEd/Helpers/Settings/Object/GameModificationsPreferencesType.hpp b/RockportEd/Helpers/Settings/Object/GameModificationsPreferencesType.hpp new file mode 100644 index 0000000..337c91d --- /dev/null +++ b/RockportEd/Helpers/Settings/Object/GameModificationsPreferencesType.hpp @@ -0,0 +1,34 @@ +#pragma once +// (De)Serialization +#include +#include +#include +#include + +struct WindowedModeModifications { + bool EnableWindowedModeImprovements = true; + bool DisableAltMenu = true; + bool DisableWindowsMouse = true; + + template + void serialize(Archive& archive) { + archive( + CEREAL_NVP(EnableWindowedModeImprovements), + CEREAL_NVP(DisableAltMenu), + CEREAL_NVP(DisableWindowsMouse) + ); + } +}; + +struct GameModificationsPreferences { + bool PauseGameplayOnOnFocusLoss = true; + WindowedModeModifications WindowedModePreferences = {}; + + template + void serialize(Archive& archive) { + archive( + CEREAL_NVP(PauseGameplayOnOnFocusLoss), + CEREAL_NVP(WindowedModePreferences) + ); + } +}; \ No newline at end of file diff --git a/RockportEd/Helpers/Settings/Settings.cpp b/RockportEd/Helpers/Settings/Settings.cpp index 15bdef2..a1d7855 100644 --- a/RockportEd/Helpers/Settings/Settings.cpp +++ b/RockportEd/Helpers/Settings/Settings.cpp @@ -21,8 +21,7 @@ namespace Settings { std::ifstream ifs(settingsFile); cereal::XMLInputArchive iarchive(ifs); iarchive(cereal::make_nvp("Settings", settingsType)); - } - catch (std::runtime_error e) { + } catch (std::runtime_error e) { MessageBox(NULL, e.what(), "Error during loading settings.", MB_ICONERROR | MB_OK); return false; } @@ -34,8 +33,7 @@ namespace Settings { std::ofstream ofs(settingsFile); cereal::XMLOutputArchive oarchive(ofs); oarchive(cereal::make_nvp("Settings", settingsType)); - } - catch (std::runtime_error e) { + } catch (std::runtime_error e) { MessageBox(NULL, e.what(), "Error during saving settings.", MB_ICONERROR | MB_OK); return false; } diff --git a/RockportEd/Helpers/Settings/Type/SettingsType.hpp b/RockportEd/Helpers/Settings/Type/SettingsType.hpp index 9acffb7..b986192 100644 --- a/RockportEd/Helpers/Settings/Type/SettingsType.hpp +++ b/RockportEd/Helpers/Settings/Type/SettingsType.hpp @@ -1,6 +1,7 @@ #pragma once #include "stdafx.h" // Subtypes +#include "..\Object\GameModificationsPreferencesType.hpp" #include "..\Object\CameraInfoPresetType.hpp" #include "..\Object\TimeOfDayLightingPresetType.hpp" // (De)Serialization @@ -12,15 +13,16 @@ class SettingsType { SettingsType() = default; bool isFirstTimeUser = true; - - std::map camPresets = {}; - std::map todPresets = {}; + GameModificationsPreferences preferences = {}; + std::map camPresets = {}; + std::map todPresets = {}; private: friend class cereal::access; template void serialize(Archive& archive) { archive( CEREAL_NVP(isFirstTimeUser), + cereal::make_nvp("GameModificationPreferences", preferences), cereal::make_nvp("CameraPresets", camPresets), cereal::make_nvp("TimeOfDayLightingPresets", todPresets) ); diff --git a/RockportEd/Helpers/WndProc/WndProcHook.cpp b/RockportEd/Helpers/WndProc/WndProcHook.cpp index cba8329..7d057bb 100644 --- a/RockportEd/Helpers/WndProc/WndProcHook.cpp +++ b/RockportEd/Helpers/WndProc/WndProcHook.cpp @@ -2,8 +2,8 @@ #include "WndProcHook.h" #include MIRRORHOOK_DEFINITIONS_PATH -namespace Hooks { - namespace WndProc { +namespace Helpers { + namespace WndProcHook { HWND windowHandle = nullptr; WNDPROC origWndProc = nullptr; std::vector extensions = std::vector(); diff --git a/RockportEd/Helpers/WndProc/WndProcHook.h b/RockportEd/Helpers/WndProc/WndProcHook.h index 3b08fad..5cc21c2 100644 --- a/RockportEd/Helpers/WndProc/WndProcHook.h +++ b/RockportEd/Helpers/WndProc/WndProcHook.h @@ -1,8 +1,8 @@ #pragma once #include -namespace Hooks { - namespace WndProc { +namespace Helpers { + namespace WndProcHook { extern HWND windowHandle; void addExtension(LPVOID extenderAddress); diff --git a/RockportEd/RockportEd.vcxproj b/RockportEd/RockportEd.vcxproj index 74eddd0..dded5b5 100644 --- a/RockportEd/RockportEd.vcxproj +++ b/RockportEd/RockportEd.vcxproj @@ -256,12 +256,12 @@ - + @@ -292,6 +292,7 @@ + diff --git a/RockportEd/RockportEd.vcxproj.filters b/RockportEd/RockportEd.vcxproj.filters index afa6c21..830728d 100644 --- a/RockportEd/RockportEd.vcxproj.filters +++ b/RockportEd/RockportEd.vcxproj.filters @@ -118,12 +118,15 @@ Helpers\Game Internals\Gameplay - + Extensions\InGame Menu\Items - + Extensions\InGame Menu\Items + + Helpers\Settings\Object + diff --git a/RockportEd/dllmain.cpp b/RockportEd/dllmain.cpp index 3029eda..2dddf2a 100644 --- a/RockportEd/dllmain.cpp +++ b/RockportEd/dllmain.cpp @@ -21,7 +21,7 @@ DWORD WINAPI Init(LPVOID) { // Helpers Memory::Init(); Settings::loadSettings(); - Hooks::WndProc::Init(); + Helpers::WndProcHook::Init(); // Extensions Extensions::WndProc::InitAll(); @@ -31,7 +31,7 @@ DWORD WINAPI Init(LPVOID) { // InGameMenu Items Extensions::InGameMenu::loadItemsToInGameMenu(); - static std::string copyright = "Copyright (c) 2017 Berkay Yiğit - berkay(2578). Greetz to GamerZ, still learning from him somehow. Bads.tm and SpeedyHeart are honestly the most annoying, egomaniac people I've ever had contact with, may god help them."; + static std::string copyright = "Copyright (c) 2018 Berkay Yiğit - berkay(2578). Greetz to GamerZ, still learning from him somehow. SpeedyHeart is honestly the most annoying, egomaniac person I've ever had contact with, may god help them."; return TRUE; }