From 645d58b9e4b43693683bc70e610ffdc005c6ca9d Mon Sep 17 00:00:00 2001 From: Eddoursul Date: Thu, 15 Feb 2024 21:38:08 +0100 Subject: [PATCH] Disabled stretching the hero menu in VR --- Enderal - Forgotten Stories.ini | 6 +++--- source/Enderal DLL/src/Patches/HeroMenuPatch.cpp | 10 ++++++++-- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/Enderal - Forgotten Stories.ini b/Enderal - Forgotten Stories.ini index 7be8f5dc..6704012a 100644 --- a/Enderal - Forgotten Stories.ini +++ b/Enderal - Forgotten Stories.ini @@ -8,7 +8,7 @@ bInvalidateOlderFiles=1 sArchiveToLoadInMemoryList=Skyrim - Animations.bsa, Skyrim - Interface.bsa, Skyrim - Sounds.bsa, E - Misc.bsa sEsmToLoadInMemoryList=Skyrim.esm, Update.esm, Dawnguard.esm, HearthFires.esm, Dragonborn.esm, Enderal - Forgotten Stories.esm sResourceArchiveList=Skyrim - Misc.bsa, Skyrim - Shaders.bsa, Skyrim - Interface.bsa, Skyrim - Animations.bsa, Skyrim - Meshes0.bsa, Skyrim - Meshes1.bsa, Skyrim - Sounds.bsa, Skyrim - Textures0.bsa, Skyrim - Textures1.bsa, Skyrim - Textures2.bsa, Skyrim - Textures3.bsa, Skyrim - Textures4.bsa, Skyrim - Textures5.bsa, Skyrim - Textures6.bsa, Skyrim - Textures7.bsa -sResourceArchiveList2=Skyrim - Textures8.bsa, Skyrim - Patch.bsa, E - Meshes.bsa, E - Textures1.bsa, E - Textures2.bsa, E - Sounds.bsa, L - Voices.bsa, E - Misc.bsa, E - Update.bsa, L - Textures.bsa +sResourceArchiveList2=Skyrim - Textures8.bsa, Skyrim - Patch.bsa, Skyrim_VR - Main.bsa, E - Meshes.bsa, E - Textures1.bsa, E - Textures2.bsa, E - Sounds.bsa, L - Voices.bsa, E - Misc.bsa, E - Update.bsa, L - Textures.bsa [SaveGame] iAutoSaveCount=5 @@ -38,8 +38,8 @@ fVisibleNavmeshMoveDist=12288.0000 fGlobalBloomThresholdBoost=10 ; Disables Screen Space Reflections - fixes engine bug with green water. Use ENB for better implementation (you may need to remove this, then). fWaterSSRIntensity=0.0001 -; Fix a transparent rectangle on the screen -iShadowMaskQuarter=4 +; Fix a transparent rectangle on the screen - this is a SkyrimPrefs.ini setting, which cannot be changed from this file, must be added manually +; iShadowMaskQuarter=4 [Interface] ; Closer book and note zooming diff --git a/source/Enderal DLL/src/Patches/HeroMenuPatch.cpp b/source/Enderal DLL/src/Patches/HeroMenuPatch.cpp index 873a46b7..554d4419 100644 --- a/source/Enderal DLL/src/Patches/HeroMenuPatch.cpp +++ b/source/Enderal DLL/src/Patches/HeroMenuPatch.cpp @@ -27,6 +27,10 @@ void HeroMenuPatch::Install() REL::Relocation vTable(RE::VTABLE_MenuControls[0]); _ProcessEvent = vTable.write_vfunc(0x1, &HeroMenuPatch::ProcessEvent_Hook); + if (REL::Module::IsVR()) { + return; + } + // Patch the Quick Stats hotkey to open the menu // Checked: 1.5.97, 1.6.640, 1.6.659, 1.6.1130 REL::Relocation target{ REL::RelocationID(51400, 52249), REL::Relocate(0x41E, 0x421) }; @@ -76,8 +80,10 @@ void HeroMenuPatch::FillMenuValues() return; } - // Fit the movie into the screen (widescreen support) - uiMovie->SetViewScaleMode(RE::BSScaleformManager::ScaleModeType::kShowAll); + if (!REL::Module::IsVR()) { + // Fit the movie into the screen (widescreen support) + uiMovie->SetViewScaleMode(RE::BSScaleformManager::ScaleModeType::kShowAll); + } const auto dataHandler = RE::TESDataHandler::GetSingleton(); RE::TESGlobal* playerLevel = dataHandler->LookupForm(0x12595, "Skyrim.esm");