From ea8acfe6b4fbd07e5d2160e829d45b07fc6f1468 Mon Sep 17 00:00:00 2001 From: xezon <4720891+xezon@users.noreply.github.com> Date: Sun, 11 Feb 2024 14:06:30 +0100 Subject: [PATCH] Fix error in GameLODManager::Find_Static_LOD_Level --- src/game/common/gamelod.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/game/common/gamelod.cpp b/src/game/common/gamelod.cpp index cec13691a..ea30ee2bb 100644 --- a/src/game/common/gamelod.cpp +++ b/src/game/common/gamelod.cpp @@ -240,11 +240,11 @@ StaticGameLODLevel GameLODManager::Find_Static_LOD_Level() } for (int i = STATLOD_HIGH; i >= STATLOD_LOW; --i) { - for (int j = 0; j < m_staticLODPresetCount[j]; ++j) { - if (m_cpuType == m_LODPresets[i][j].cpu_type) { - if ((double)m_cpuMHz / (double)m_LODPresets[i][j].mhz >= 0.94 - && m_gpuType >= m_LODPresets[i][j].video_type - && (double)(m_physicalMem / 0x100000) / (double)m_LODPresets[i][j].video_mem >= 0.94) { + for (int k = 0; k < m_staticLODPresetCount[i]; ++k) { + if (m_cpuType == m_LODPresets[i][k].cpu_type) { + if ((double)m_cpuMHz / (double)m_LODPresets[i][k].mhz >= 0.94 + && m_gpuType >= m_LODPresets[i][k].video_type + && (double)(m_physicalMem / 0x100000) / (double)m_LODPresets[i][k].video_mem >= 0.94) { m_idealStaticGameDetail = (StaticGameLODLevel)i; break; }