From c4649da1d69f3794d7960b67e3f497dd9d59fac1 Mon Sep 17 00:00:00 2001 From: Alexey Date: Sat, 9 Nov 2024 21:30:37 +0300 Subject: [PATCH] [CKPE] FO4: - Skip check forms count #72 SF: - Remove set thread dpi for dialogs --- .github/workflows/msbuild.yml | 16 ++-- .../Core/EngineFO4Patches.cpp | 2 + .../Core/EngineSFPatches.cpp | 6 ++ ...reation Kit Platform Extended Core.vcxproj | 8 ++ ...Kit Platform Extended Core.vcxproj.filters | 24 +++++ .../Patches/FO4/DontMatchForms.cpp | 74 +++++++++++++++ .../Patches/FO4/DontMatchForms.h | 41 +++++++++ .../Patches/RenameCreationKitApp.cpp | 2 +- .../Patches/SF/LoadMaterialsAsync.cpp | 86 ++++++++++++++++++ .../Patches/SF/LoadMaterialsAsync.h | 43 +++++++++ .../Patches/SF/RemoveThreadDpi.cpp | 74 +++++++++++++++ .../Patches/SF/RemoveThreadDpi.h | 41 +++++++++ .../SF/RemoveUselessResizeInDialogs.cpp | 74 +++++++++++++++ .../Patches/SF/RemoveUselessResizeInDialogs.h | 41 +++++++++ .../Version/build_version.txt | Bin 12 -> 12 bytes .../Version/resource_version2.h | Bin 2004 -> 2004 bytes Creation Kit Platform Extended.sln | 42 --------- ...nKitPlatformExtended_FO4_1_10_162.database | Bin 41664 -> 41734 bytes Database/FO4/1_10_162_0/DontMatchForms.relb | 4 + ...itPlatformExtended_FO4_1_10_982_3.database | Bin 25588 -> 25658 bytes Database/FO4/1_10_982_3/DontMatchForms.relb | 4 + ...nKitPlatformExtended_SF_1_14_70_0.database | Bin 14907 -> 15186 bytes Database/SF/1_14_70_0/LoadMaterialsAsync.relb | 5 + Database/SF/1_14_70_0/RemoveThreadDpi.relb | 5 + .../RemoveUselessResizeInDialogs.relb | 4 + 25 files changed, 545 insertions(+), 51 deletions(-) create mode 100644 Creation Kit Platform Extended Core/Patches/FO4/DontMatchForms.cpp create mode 100644 Creation Kit Platform Extended Core/Patches/FO4/DontMatchForms.h create mode 100644 Creation Kit Platform Extended Core/Patches/SF/LoadMaterialsAsync.cpp create mode 100644 Creation Kit Platform Extended Core/Patches/SF/LoadMaterialsAsync.h create mode 100644 Creation Kit Platform Extended Core/Patches/SF/RemoveThreadDpi.cpp create mode 100644 Creation Kit Platform Extended Core/Patches/SF/RemoveThreadDpi.h create mode 100644 Creation Kit Platform Extended Core/Patches/SF/RemoveUselessResizeInDialogs.cpp create mode 100644 Creation Kit Platform Extended Core/Patches/SF/RemoveUselessResizeInDialogs.h create mode 100644 Database/FO4/1_10_162_0/DontMatchForms.relb create mode 100644 Database/FO4/1_10_982_3/DontMatchForms.relb create mode 100644 Database/SF/1_14_70_0/LoadMaterialsAsync.relb create mode 100644 Database/SF/1_14_70_0/RemoveThreadDpi.relb create mode 100644 Database/SF/1_14_70_0/RemoveUselessResizeInDialogs.relb diff --git a/.github/workflows/msbuild.yml b/.github/workflows/msbuild.yml index aa6c6361..547acf3a 100644 --- a/.github/workflows/msbuild.yml +++ b/.github/workflows/msbuild.yml @@ -136,30 +136,30 @@ jobs: - name: Make Bundle Directory working-directory: ${{env.GITHUB_WORKSPACE}} - run: New-Item -ItemType Directory -Path "ckpe-sf-${{env.SHORT_SHA}}" + run: New-Item -ItemType Directory -Path "ckpe-sf-master-${{env.SHORT_SHA}}" - name: Copy Voltek to SF working-directory: ${{env.GITHUB_WORKSPACE}} - run: Copy-Item -Path x64\Release\Voltek*.dll "ckpe-sf-${{env.SHORT_SHA}}" + run: Copy-Item -Path x64\Release\Voltek*.dll "ckpe-sf-master-${{env.SHORT_SHA}}" - name: Copy SF Database working-directory: ${{env.GITHUB_WORKSPACE}} - run: Get-ChildItem -Recurse -Path Database\SF -Include ${{ env.SF_DATABASES }} | ForEach-Object { Copy-Item -Path $_.FullName -Destination (Join-Path "ckpe-sf-${{env.SHORT_SHA}}" $_.Name) -Force } + run: Get-ChildItem -Recurse -Path Database\SF -Include ${{ env.SF_DATABASES }} | ForEach-Object { Copy-Item -Path $_.FullName -Destination (Join-Path "ckpe-sf-master-${{env.SHORT_SHA}}" $_.Name) -Force } - name: Copy SF Dialog working-directory: ${{env.GITHUB_WORKSPACE}} - run: Copy-Item -Path Dialogs\SF\*.pak "ckpe-sf-${{env.SHORT_SHA}}" + run: Copy-Item -Path Dialogs\SF\*.pak "ckpe-sf-master-${{env.SHORT_SHA}}" - name: Copy SF Stuff working-directory: ${{env.GITHUB_WORKSPACE}} - run: Get-ChildItem -Path .\Stuffs\SF -Recurse | ForEach-Object { Copy-Item -Path $_.FullName -Destination (Join-Path "ckpe-sf-${{env.SHORT_SHA}}" $_.Name) -Force } + run: Get-ChildItem -Path .\Stuffs\SF -Recurse | ForEach-Object { Copy-Item -Path $_.FullName -Destination (Join-Path "ckpe-sf-master-${{env.SHORT_SHA}}" $_.Name) -Force } - name: Copy SF CKPE working-directory: ${{env.GITHUB_WORKSPACE}} - run: Get-ChildItem -Recurse -Path ".\x64" -Include "ckpe_loader.exe", "winhttp.dll" | ForEach-Object { Copy-Item -Path $_.FullName -Destination (Join-Path "ckpe-sf-${{env.SHORT_SHA}}" $_.Name) -Force } + run: Get-ChildItem -Recurse -Path ".\x64" -Include "ckpe_loader.exe", "winhttp.dll" | ForEach-Object { Copy-Item -Path $_.FullName -Destination (Join-Path "ckpe-sf-master-${{env.SHORT_SHA}}" $_.Name) -Force } - name: Upload build artifacts uses: actions/upload-artifact@v4 with: - name: ckpe-sf-${{env.SHORT_SHA}} - path: "ckpe-sf-${{env.SHORT_SHA}}" \ No newline at end of file + name: ckpe-sf-master-${{env.SHORT_SHA}} + path: "ckpe-sf-master-${{env.SHORT_SHA}}" \ No newline at end of file diff --git a/Creation Kit Platform Extended Core/Core/EngineFO4Patches.cpp b/Creation Kit Platform Extended Core/Core/EngineFO4Patches.cpp index 6fa4bf76..7b6b5975 100644 --- a/Creation Kit Platform Extended Core/Core/EngineFO4Patches.cpp +++ b/Creation Kit Platform Extended Core/Core/EngineFO4Patches.cpp @@ -51,6 +51,7 @@ #include "Patches/FO4/ChooseSoundFileF4.h" #include "Patches/FO4/RunNetworkDisable.h" #include "Patches/FO4/CrashConditionItemGetCrime.h" +#include "Patches/FO4/DontMatchForms.h" #include "Patches/Windows/FO4/MainWindowF4.h" #include "Patches/Windows/FO4/ObjectWindowF4.h" @@ -115,6 +116,7 @@ namespace CreationKitPlatformExtended new Patches::CrashInventoryPatch(), new Patches::RunNetworkDisablePatch(), new Patches::CrashConditionItemGetCrimePatch(), + new Patches::DontMatchFormsPatch(), new Patches::MainWindow(), new Patches::ObjectWindow(), diff --git a/Creation Kit Platform Extended Core/Core/EngineSFPatches.cpp b/Creation Kit Platform Extended Core/Core/EngineSFPatches.cpp index c54350fd..39768d0c 100644 --- a/Creation Kit Platform Extended Core/Core/EngineSFPatches.cpp +++ b/Creation Kit Platform Extended Core/Core/EngineSFPatches.cpp @@ -14,6 +14,9 @@ #include "Patches/SF/RTDynamicCastCrash.h" #include "Patches/SF/OptimizationLoadSF.h" #include "Patches/SF/RemoveUselessMessagesSF.h" +#include "Patches/SF/RemoveUselessResizeInDialogs.h" +#include "Patches/SF/RemoveThreadDpi.h" +#include "Patches/SF/LoadMaterialsAsync.h" #include "Patches/Windows/SF/DataWindowSF.h" #include "Patches/Windows/SF/AboutWindowSF.h" @@ -42,6 +45,9 @@ namespace CreationKitPlatformExtended new Patches::RTDynamicCastCrashPatch(), new Patches::OptimizationLoadPatch(), new Patches::RemoveUselessMessagesPatch(), + //new Patches::RemoveUselessResizeInDialogsPatch(), + new Patches::RemoveThreadDpiPatch(), + //new Patches::LoadMaterialsAsyncPatch(), new Patches::DataWindow(), new Patches::AboutWindow(), diff --git a/Creation Kit Platform Extended Core/Creation Kit Platform Extended Core.vcxproj b/Creation Kit Platform Extended Core/Creation Kit Platform Extended Core.vcxproj index 3b2ede5b..f2ffb9e7 100644 --- a/Creation Kit Platform Extended Core/Creation Kit Platform Extended Core.vcxproj +++ b/Creation Kit Platform Extended Core/Creation Kit Platform Extended Core.vcxproj @@ -212,6 +212,7 @@ + @@ -253,8 +254,11 @@ + + + @@ -606,6 +610,7 @@ + @@ -647,8 +652,11 @@ + + + diff --git a/Creation Kit Platform Extended Core/Creation Kit Platform Extended Core.vcxproj.filters b/Creation Kit Platform Extended Core/Creation Kit Platform Extended Core.vcxproj.filters index c6c91460..b81fcd21 100644 --- a/Creation Kit Platform Extended Core/Creation Kit Platform Extended Core.vcxproj.filters +++ b/Creation Kit Platform Extended Core/Creation Kit Platform Extended Core.vcxproj.filters @@ -868,6 +868,18 @@ Patches\FO4 + + Patches\SF + + + Patches\SF + + + Patches\SF + + + Patches\FO4 + @@ -2128,6 +2140,18 @@ Patches\FO4 + + Patches\SF + + + Patches\SF + + + Patches\SF + + + Patches\FO4 + diff --git a/Creation Kit Platform Extended Core/Patches/FO4/DontMatchForms.cpp b/Creation Kit Platform Extended Core/Patches/FO4/DontMatchForms.cpp new file mode 100644 index 00000000..4b70e9fc --- /dev/null +++ b/Creation Kit Platform Extended Core/Patches/FO4/DontMatchForms.cpp @@ -0,0 +1,74 @@ +// Copyright © 2023-2024 aka perchik71. All rights reserved. +// Contacts: +// License: https://www.gnu.org/licenses/gpl-3.0.html + +#include "Core/Engine.h" +#include "DontMatchForms.h" + +namespace CreationKitPlatformExtended +{ + namespace Patches + { + namespace Fallout4 + { + DontMatchFormsPatch::DontMatchFormsPatch() : Module(GlobalEnginePtr) + {} + + bool DontMatchFormsPatch::HasOption() const + { + return false; + } + + bool DontMatchFormsPatch::HasCanRuntimeDisabled() const + { + return false; + } + + const char* DontMatchFormsPatch::GetOptionName() const + { + return nullptr; + } + + const char* DontMatchFormsPatch::GetName() const + { + return "Dont Match Forms"; + } + + bool DontMatchFormsPatch::HasDependencies() const + { + return false; + } + + Array DontMatchFormsPatch::GetDependencies() const + { + return {}; + } + + bool DontMatchFormsPatch::QueryFromPlatform(EDITOR_EXECUTABLE_TYPE eEditorCurrentVersion, + const char* lpcstrPlatformRuntimeVersion) const + { + return (eEditorCurrentVersion <= EDITOR_EXECUTABLE_TYPE::EDITOR_FALLOUT_C4_LAST) && + (eEditorCurrentVersion != EDITOR_EXECUTABLE_TYPE::EDITOR_FALLOUT_C4_1_10_943_1); + } + + bool DontMatchFormsPatch::Activate(const Relocator* lpRelocator, + const RelocationDatabaseItem* lpRelocationDatabaseItem) + { + if (lpRelocationDatabaseItem->Version() == 1) + { + lpRelocator->Patch(_RELDATA_RAV(0), { 0xEB }); + + return true; + } + + return false; + } + + bool DontMatchFormsPatch::Shutdown(const Relocator* lpRelocator, + const RelocationDatabaseItem* lpRelocationDatabaseItem) + { + return false; + } + } + } +} \ No newline at end of file diff --git a/Creation Kit Platform Extended Core/Patches/FO4/DontMatchForms.h b/Creation Kit Platform Extended Core/Patches/FO4/DontMatchForms.h new file mode 100644 index 00000000..4d654440 --- /dev/null +++ b/Creation Kit Platform Extended Core/Patches/FO4/DontMatchForms.h @@ -0,0 +1,41 @@ +// Copyright © 2023-2024 aka perchik71. All rights reserved. +// Contacts: +// License: https://www.gnu.org/licenses/gpl-3.0.html + +#pragma once + +#include "Core/Module.h" +#include "Core/Relocator.h" +#include "Core/RelocationDatabase.h" + +namespace CreationKitPlatformExtended +{ + namespace Patches + { + namespace Fallout4 + { + using namespace CreationKitPlatformExtended::Core; + + class DontMatchFormsPatch : public Module + { + public: + DontMatchFormsPatch(); + + virtual bool HasOption() const; + virtual bool HasCanRuntimeDisabled() const; + virtual const char* GetOptionName() const; + virtual const char* GetName() const; + virtual bool HasDependencies() const; + virtual Array GetDependencies() const; + protected: + virtual bool QueryFromPlatform(EDITOR_EXECUTABLE_TYPE eEditorCurrentVersion, + const char* lpcstrPlatformRuntimeVersion) const; + virtual bool Activate(const Relocator* lpRelocator, const RelocationDatabaseItem* lpRelocationDatabaseItem); + virtual bool Shutdown(const Relocator* lpRelocator, const RelocationDatabaseItem* lpRelocationDatabaseItem); + private: + DontMatchFormsPatch(const DontMatchFormsPatch&) = default; + DontMatchFormsPatch& operator=(const DontMatchFormsPatch&) = default; + }; + } + } +} \ No newline at end of file diff --git a/Creation Kit Platform Extended Core/Patches/RenameCreationKitApp.cpp b/Creation Kit Platform Extended Core/Patches/RenameCreationKitApp.cpp index 983b7e99..e083c22d 100644 --- a/Creation Kit Platform Extended Core/Patches/RenameCreationKitApp.cpp +++ b/Creation Kit Platform Extended Core/Patches/RenameCreationKitApp.cpp @@ -74,7 +74,7 @@ namespace CreationKitPlatformExtended // In Qt, it would be necessary to give the name of the window initially, for something acceptable lpRelocator->Patch(_RELDATA_RAV(1), (uint8_t*)"Creation Kit\0", 13); // Cut a useless entry [Branch: , Version: ] - lpRelocator->PatchNop(_RELDATA_RAV(2), 0xA7); + //lpRelocator->PatchNop(_RELDATA_RAV(2), 0xA7); lpRelocator->PatchNop(_RELDATA_RAV(4), 0x6); // Cut a useless entry [Admin] lpRelocator->DetourCall(_RELDATA_RAV(3), &QString::sprintf); diff --git a/Creation Kit Platform Extended Core/Patches/SF/LoadMaterialsAsync.cpp b/Creation Kit Platform Extended Core/Patches/SF/LoadMaterialsAsync.cpp new file mode 100644 index 00000000..54b8f17c --- /dev/null +++ b/Creation Kit Platform Extended Core/Patches/SF/LoadMaterialsAsync.cpp @@ -0,0 +1,86 @@ +// Copyright © 2023-2024 aka perchik71. All rights reserved. +// Contacts: +// License: https://www.gnu.org/licenses/gpl-3.0.html + +#include "Core/Engine.h" +#include "LoadMaterialsAsync.h" + +namespace CreationKitPlatformExtended +{ + namespace Patches + { + namespace Starfield + { + uintptr_t pointer_LoadMaterialsAsyncPatch_sub0 = 0; + + LoadMaterialsAsyncPatch::LoadMaterialsAsyncPatch() : Module(GlobalEnginePtr) + {} + + bool LoadMaterialsAsyncPatch::HasOption() const + { + return false; + } + + bool LoadMaterialsAsyncPatch::HasCanRuntimeDisabled() const + { + return false; + } + + const char* LoadMaterialsAsyncPatch::GetOptionName() const + { + return nullptr; + } + + const char* LoadMaterialsAsyncPatch::GetName() const + { + return "Load Materials Async"; + } + + bool LoadMaterialsAsyncPatch::HasDependencies() const + { + return false; + } + + Array LoadMaterialsAsyncPatch::GetDependencies() const + { + return {}; + } + + bool LoadMaterialsAsyncPatch::QueryFromPlatform(EDITOR_EXECUTABLE_TYPE eEditorCurrentVersion, + const char* lpcstrPlatformRuntimeVersion) const + { + return eEditorCurrentVersion >= EDITOR_EXECUTABLE_TYPE::EDITOR_STARFIELD_1_14_70_0; + } + + bool LoadMaterialsAsyncPatch::Activate(const Relocator* lpRelocator, + const RelocationDatabaseItem* lpRelocationDatabaseItem) + { + if (lpRelocationDatabaseItem->Version() == 1) + { + pointer_LoadMaterialsAsyncPatch_sub0 = _RELDATA_ADDR(0); + lpRelocator->DetourCall(_RELDATA_RAV(1), (uintptr_t)&sub); + + return true; + } + + return false; + } + + bool LoadMaterialsAsyncPatch::Shutdown(const Relocator* lpRelocator, + const RelocationDatabaseItem* lpRelocationDatabaseItem) + { + return false; + } + + void LoadMaterialsAsyncPatch::sub(void* arg1, void* arg2) + { + auto mat_thread = std::thread([](void* arg1, void* arg2) { + fastCall(pointer_LoadMaterialsAsyncPatch_sub0, arg1, arg2); + }, arg1, arg2); + + SetThreadPriority(mat_thread.native_handle(), THREAD_PRIORITY_HIGHEST); + mat_thread.join(); + } + } + } +} \ No newline at end of file diff --git a/Creation Kit Platform Extended Core/Patches/SF/LoadMaterialsAsync.h b/Creation Kit Platform Extended Core/Patches/SF/LoadMaterialsAsync.h new file mode 100644 index 00000000..305fe70e --- /dev/null +++ b/Creation Kit Platform Extended Core/Patches/SF/LoadMaterialsAsync.h @@ -0,0 +1,43 @@ +// Copyright © 2023-2024 aka perchik71. All rights reserved. +// Contacts: +// License: https://www.gnu.org/licenses/gpl-3.0.html + +#pragma once + +#include "Core/Module.h" +#include "Core/Relocator.h" +#include "Core/RelocationDatabase.h" + +namespace CreationKitPlatformExtended +{ + namespace Patches + { + namespace Starfield + { + using namespace CreationKitPlatformExtended::Core; + + class LoadMaterialsAsyncPatch : public Module + { + public: + LoadMaterialsAsyncPatch(); + + virtual bool HasOption() const; + virtual bool HasCanRuntimeDisabled() const; + virtual const char* GetOptionName() const; + virtual const char* GetName() const; + virtual bool HasDependencies() const; + virtual Array GetDependencies() const; + + static void sub(void* arg1, void* arg2); + protected: + virtual bool QueryFromPlatform(EDITOR_EXECUTABLE_TYPE eEditorCurrentVersion, + const char* lpcstrPlatformRuntimeVersion) const; + virtual bool Activate(const Relocator* lpRelocator, const RelocationDatabaseItem* lpRelocationDatabaseItem); + virtual bool Shutdown(const Relocator* lpRelocator, const RelocationDatabaseItem* lpRelocationDatabaseItem); + private: + LoadMaterialsAsyncPatch(const LoadMaterialsAsyncPatch&) = default; + LoadMaterialsAsyncPatch& operator=(const LoadMaterialsAsyncPatch&) = default; + }; + } + } +} \ No newline at end of file diff --git a/Creation Kit Platform Extended Core/Patches/SF/RemoveThreadDpi.cpp b/Creation Kit Platform Extended Core/Patches/SF/RemoveThreadDpi.cpp new file mode 100644 index 00000000..227ec278 --- /dev/null +++ b/Creation Kit Platform Extended Core/Patches/SF/RemoveThreadDpi.cpp @@ -0,0 +1,74 @@ +// Copyright © 2023-2024 aka perchik71. All rights reserved. +// Contacts: +// License: https://www.gnu.org/licenses/gpl-3.0.html + +#include "Core/Engine.h" +#include "RemoveThreadDpi.h" + +namespace CreationKitPlatformExtended +{ + namespace Patches + { + namespace Starfield + { + RemoveThreadDpiPatch::RemoveThreadDpiPatch() : Module(GlobalEnginePtr) + {} + + bool RemoveThreadDpiPatch::HasOption() const + { + return false; + } + + bool RemoveThreadDpiPatch::HasCanRuntimeDisabled() const + { + return false; + } + + const char* RemoveThreadDpiPatch::GetOptionName() const + { + return nullptr; + } + + const char* RemoveThreadDpiPatch::GetName() const + { + return "Remove Thread Dpi"; + } + + bool RemoveThreadDpiPatch::HasDependencies() const + { + return false; + } + + Array RemoveThreadDpiPatch::GetDependencies() const + { + return {}; + } + + bool RemoveThreadDpiPatch::QueryFromPlatform(EDITOR_EXECUTABLE_TYPE eEditorCurrentVersion, + const char* lpcstrPlatformRuntimeVersion) const + { + return eEditorCurrentVersion >= EDITOR_EXECUTABLE_TYPE::EDITOR_STARFIELD_1_14_70_0; + } + + bool RemoveThreadDpiPatch::Activate(const Relocator* lpRelocator, + const RelocationDatabaseItem* lpRelocationDatabaseItem) + { + if (lpRelocationDatabaseItem->Version() == 1) + { + for (uint32_t i = 0; i < lpRelocationDatabaseItem->Count(); i++) + lpRelocator->Patch(_RELDATA_RAV(i), { 0xEB }); + + return true; + } + + return false; + } + + bool RemoveThreadDpiPatch::Shutdown(const Relocator* lpRelocator, + const RelocationDatabaseItem* lpRelocationDatabaseItem) + { + return false; + } + } + } +} \ No newline at end of file diff --git a/Creation Kit Platform Extended Core/Patches/SF/RemoveThreadDpi.h b/Creation Kit Platform Extended Core/Patches/SF/RemoveThreadDpi.h new file mode 100644 index 00000000..3347c5f9 --- /dev/null +++ b/Creation Kit Platform Extended Core/Patches/SF/RemoveThreadDpi.h @@ -0,0 +1,41 @@ +// Copyright © 2023-2024 aka perchik71. All rights reserved. +// Contacts: +// License: https://www.gnu.org/licenses/gpl-3.0.html + +#pragma once + +#include "Core/Module.h" +#include "Core/Relocator.h" +#include "Core/RelocationDatabase.h" + +namespace CreationKitPlatformExtended +{ + namespace Patches + { + namespace Starfield + { + using namespace CreationKitPlatformExtended::Core; + + class RemoveThreadDpiPatch : public Module + { + public: + RemoveThreadDpiPatch(); + + virtual bool HasOption() const; + virtual bool HasCanRuntimeDisabled() const; + virtual const char* GetOptionName() const; + virtual const char* GetName() const; + virtual bool HasDependencies() const; + virtual Array GetDependencies() const; + protected: + virtual bool QueryFromPlatform(EDITOR_EXECUTABLE_TYPE eEditorCurrentVersion, + const char* lpcstrPlatformRuntimeVersion) const; + virtual bool Activate(const Relocator* lpRelocator, const RelocationDatabaseItem* lpRelocationDatabaseItem); + virtual bool Shutdown(const Relocator* lpRelocator, const RelocationDatabaseItem* lpRelocationDatabaseItem); + private: + RemoveThreadDpiPatch(const RemoveThreadDpiPatch&) = default; + RemoveThreadDpiPatch& operator=(const RemoveThreadDpiPatch&) = default; + }; + } + } +} \ No newline at end of file diff --git a/Creation Kit Platform Extended Core/Patches/SF/RemoveUselessResizeInDialogs.cpp b/Creation Kit Platform Extended Core/Patches/SF/RemoveUselessResizeInDialogs.cpp new file mode 100644 index 00000000..b61bbb12 --- /dev/null +++ b/Creation Kit Platform Extended Core/Patches/SF/RemoveUselessResizeInDialogs.cpp @@ -0,0 +1,74 @@ +// Copyright © 2023-2024 aka perchik71. All rights reserved. +// Contacts: +// License: https://www.gnu.org/licenses/gpl-3.0.html + +#include "Core/Engine.h" +#include "RemoveUselessResizeInDialogs.h" + +namespace CreationKitPlatformExtended +{ + namespace Patches + { + namespace Starfield + { + RemoveUselessResizeInDialogsPatch::RemoveUselessResizeInDialogsPatch() : Module(GlobalEnginePtr) + {} + + bool RemoveUselessResizeInDialogsPatch::HasOption() const + { + return false; + } + + bool RemoveUselessResizeInDialogsPatch::HasCanRuntimeDisabled() const + { + return false; + } + + const char* RemoveUselessResizeInDialogsPatch::GetOptionName() const + { + return nullptr; + } + + const char* RemoveUselessResizeInDialogsPatch::GetName() const + { + return "Remove Useless Resize In Dialogs"; + } + + bool RemoveUselessResizeInDialogsPatch::HasDependencies() const + { + return false; + } + + Array RemoveUselessResizeInDialogsPatch::GetDependencies() const + { + return {}; + } + + bool RemoveUselessResizeInDialogsPatch::QueryFromPlatform(EDITOR_EXECUTABLE_TYPE eEditorCurrentVersion, + const char* lpcstrPlatformRuntimeVersion) const + { + return eEditorCurrentVersion >= EDITOR_EXECUTABLE_TYPE::EDITOR_STARFIELD_1_14_70_0; + } + + bool RemoveUselessResizeInDialogsPatch::Activate(const Relocator* lpRelocator, + const RelocationDatabaseItem* lpRelocationDatabaseItem) + { + if (lpRelocationDatabaseItem->Version() == 1) + { + for (uint32_t i = 0; i < lpRelocationDatabaseItem->Count(); i++) + lpRelocator->PatchNop(_RELDATA_RAV(i), 6); + + return true; + } + + return false; + } + + bool RemoveUselessResizeInDialogsPatch::Shutdown(const Relocator* lpRelocator, + const RelocationDatabaseItem* lpRelocationDatabaseItem) + { + return false; + } + } + } +} \ No newline at end of file diff --git a/Creation Kit Platform Extended Core/Patches/SF/RemoveUselessResizeInDialogs.h b/Creation Kit Platform Extended Core/Patches/SF/RemoveUselessResizeInDialogs.h new file mode 100644 index 00000000..bd7fb65e --- /dev/null +++ b/Creation Kit Platform Extended Core/Patches/SF/RemoveUselessResizeInDialogs.h @@ -0,0 +1,41 @@ +// Copyright © 2023-2024 aka perchik71. All rights reserved. +// Contacts: +// License: https://www.gnu.org/licenses/gpl-3.0.html + +#pragma once + +#include "Core/Module.h" +#include "Core/Relocator.h" +#include "Core/RelocationDatabase.h" + +namespace CreationKitPlatformExtended +{ + namespace Patches + { + namespace Starfield + { + using namespace CreationKitPlatformExtended::Core; + + class RemoveUselessResizeInDialogsPatch : public Module + { + public: + RemoveUselessResizeInDialogsPatch(); + + virtual bool HasOption() const; + virtual bool HasCanRuntimeDisabled() const; + virtual const char* GetOptionName() const; + virtual const char* GetName() const; + virtual bool HasDependencies() const; + virtual Array GetDependencies() const; + protected: + virtual bool QueryFromPlatform(EDITOR_EXECUTABLE_TYPE eEditorCurrentVersion, + const char* lpcstrPlatformRuntimeVersion) const; + virtual bool Activate(const Relocator* lpRelocator, const RelocationDatabaseItem* lpRelocationDatabaseItem); + virtual bool Shutdown(const Relocator* lpRelocator, const RelocationDatabaseItem* lpRelocationDatabaseItem); + private: + RemoveUselessResizeInDialogsPatch(const RemoveUselessResizeInDialogsPatch&) = default; + RemoveUselessResizeInDialogsPatch& operator=(const RemoveUselessResizeInDialogsPatch&) = default; + }; + } + } +} \ No newline at end of file diff --git a/Creation Kit Platform Extended Core/Version/build_version.txt b/Creation Kit Platform Extended Core/Version/build_version.txt index 9189a277b5c2be5c3a857a19453112dd7e3a6420..9be285c1304bd29f842f599782b3139a86d0d989 100644 GIT binary patch literal 12 TcmezW&z!-6!GwXAfr|kE98dzd literal 12 TcmezW&z!-W!H|KMfr|kE95w>9 diff --git a/Creation Kit Platform Extended Core/Version/resource_version2.h b/Creation Kit Platform Extended Core/Version/resource_version2.h index 5c28725bcda9a698f36d5228a24d21e887c0d8b1..284c920d27250e24113fb195ced06794e540ef37 100644 GIT binary patch delta 28 kcmcb@e}#X;17>y$24ez}1_K6O2Cm7B%+ix1Sfw`0uQpcZcc delta 28 kcmZoW#&qB)(*y-Z?~RI`63h=IGB&T3xXrrxoSa1q0Hc))TL1t6 diff --git a/Database/FO4/1_10_162_0/DontMatchForms.relb b/Database/FO4/1_10_162_0/DontMatchForms.relb new file mode 100644 index 00000000..3d928e7b --- /dev/null +++ b/Database/FO4/1_10_162_0/DontMatchForms.relb @@ -0,0 +1,4 @@ +Dont Match Forms +1 +extended +7DEABC 0 \ No newline at end of file diff --git a/Database/FO4/1_10_982_3/CreationKitPlatformExtended_FO4_1_10_982_3.database b/Database/FO4/1_10_982_3/CreationKitPlatformExtended_FO4_1_10_982_3.database index 20340420fe23950ee230fa037c2c636849b9e9f4..a7350d07f91da1aafefb54c7e5016561215aabd9 100644 GIT binary patch delta 67 zcmexzoN?C)#t90Hej61Zh{(AyKma3<5@2x2&nr>zO)N>yP;kpH$}OJkC?~>mc|kJ+ R8-oFF3_kS diff --git a/Database/FO4/1_10_982_3/DontMatchForms.relb b/Database/FO4/1_10_982_3/DontMatchForms.relb new file mode 100644 index 00000000..dcc8ee65 --- /dev/null +++ b/Database/FO4/1_10_982_3/DontMatchForms.relb @@ -0,0 +1,4 @@ +Dont Match Forms +1 +extended +83A0D3 0 \ No newline at end of file diff --git a/Database/SF/1_14_70_0/CreationKitPlatformExtended_SF_1_14_70_0.database b/Database/SF/1_14_70_0/CreationKitPlatformExtended_SF_1_14_70_0.database index 20ad53b147957132bb903d06e48946e761c03d3b..578337caa877b697dd2a37650474d2d0ac645b71 100644 GIT binary patch delta 277 zcmdm8a;a>B0;AeS#a=O`Fa`)<1X3alKKY3$3ciUYsYRKIImHT&#g%! +50F2BA0 0 \ No newline at end of file diff --git a/Database/SF/1_14_70_0/RemoveThreadDpi.relb b/Database/SF/1_14_70_0/RemoveThreadDpi.relb new file mode 100644 index 00000000..fc577040 --- /dev/null +++ b/Database/SF/1_14_70_0/RemoveThreadDpi.relb @@ -0,0 +1,5 @@ +Remove Thread Dpi +1 +extended +33C0F85 0 +33C0FD7 0 \ No newline at end of file diff --git a/Database/SF/1_14_70_0/RemoveUselessResizeInDialogs.relb b/Database/SF/1_14_70_0/RemoveUselessResizeInDialogs.relb new file mode 100644 index 00000000..613ee802 --- /dev/null +++ b/Database/SF/1_14_70_0/RemoveUselessResizeInDialogs.relb @@ -0,0 +1,4 @@ +Remove Useless Resize In Dialogs +1 +extended +1D69F55 0 BA4402000041B82C010000488BCE+E \ No newline at end of file