Addressed an issue where UI would not show for certain resolutions
This commit is contained in:
@@ -367,18 +367,18 @@ static void HUDUpdate(bool writeLog) {
|
||||
if (writeLog) logger->info("HUD & UI scaling fix {}", g_fix_enabled && g_HUD_fix_enabled ? "enabled" : "disabled");
|
||||
float UIoffset = (g_fix_enabled && g_HUD_fix_enabled) ? g_UIOffsets : 0.f;
|
||||
float HUDoffset = (g_fix_enabled && g_HUD_fix_enabled) ? g_HUDOffsets : 0.f;
|
||||
float compensation = (g_fix_enabled && g_HUD_fix_enabled) ? 90.f : 0.f;
|
||||
float targetAspect = 16.f / 9.f;
|
||||
|
||||
CenterWidget(g_UIMainMenuWidget, UIoffset, screenWidth, screenHeight, g_AspectRatio, targetAspect, compensation);
|
||||
CenterWidget(g_UISettingsWidget, UIoffset, screenWidth, screenHeight, g_AspectRatio, targetAspect, compensation);
|
||||
CenterWidget(g_ProfileWidget, UIoffset, screenWidth, screenHeight, g_AspectRatio, targetAspect, compensation);
|
||||
CenterWidget(g_DifficultyWidget, UIoffset, screenWidth, screenHeight, g_AspectRatio, targetAspect, compensation);
|
||||
CenterWidget(g_InGameMenuWidget, UIoffset, screenWidth, screenHeight, g_AspectRatio, targetAspect, compensation);
|
||||
CenterWidget(g_PauseWidget, UIoffset, screenWidth, screenHeight, g_AspectRatio, targetAspect, compensation);
|
||||
CenterWidget(g_SavesWidget, UIoffset, screenWidth, screenHeight, g_AspectRatio, targetAspect, compensation);
|
||||
CenterWidget(g_MapWidget, UIoffset, screenWidth, screenHeight, g_AspectRatio, targetAspect, compensation);
|
||||
CenterWidget(g_GameOverWidget, UIoffset, screenWidth, screenHeight, g_AspectRatio, targetAspect, compensation);
|
||||
float compensation = (g_fix_enabled && g_HUD_fix_enabled) ? -90.f : 0.f;
|
||||
float targetWidth = 1920.f;
|
||||
float targetHeight = 1080.f;
|
||||
CenterWidget(g_UIMainMenuWidget, UIoffset, screenWidth, screenHeight, targetWidth, targetHeight, compensation);
|
||||
CenterWidget(g_UISettingsWidget, UIoffset, screenWidth, screenHeight, targetWidth, targetHeight, compensation);
|
||||
CenterWidget(g_ProfileWidget, UIoffset, screenWidth, screenHeight, targetWidth, targetHeight, compensation);
|
||||
CenterWidget(g_DifficultyWidget, UIoffset, screenWidth, screenHeight, targetWidth, targetHeight, compensation);
|
||||
CenterWidget(g_InGameMenuWidget, UIoffset, screenWidth, screenHeight, targetWidth, targetHeight, compensation);
|
||||
CenterWidget(g_PauseWidget, UIoffset, screenWidth, screenHeight, targetWidth, targetHeight, compensation);
|
||||
CenterWidget(g_SavesWidget, UIoffset, screenWidth, screenHeight, targetWidth, targetHeight, compensation);
|
||||
CenterWidget(g_MapWidget, UIoffset, screenWidth, screenHeight, targetWidth, targetHeight, compensation);
|
||||
CenterWidget(g_GameOverWidget, UIoffset, screenWidth, screenHeight, targetWidth, targetHeight, compensation);
|
||||
ApplyOffsetsSmart(g_StatusWidget, HUDoffset, 0.f, 1);
|
||||
ApplyOffsetsSmart(g_GaugesWidget, 0, HUDoffset + 690.f, 1); // Use original left and right offset + for Anchors of type 1, 1, 1, 1
|
||||
ApplyOffsetsSmart(g_AbilityWheelWidget, 0, HUDoffset + 78.f, 1); // Use original left and right offset + for Anchors of type 1, 1, 1, 1
|
||||
|
||||
Reference in New Issue
Block a user