From 05edc13fafb20a00b96dfe72a44af34fa61f9b3f Mon Sep 17 00:00:00 2001 From: Jacob Weisz Date: Thu, 4 Jul 2024 12:42:05 -0500 Subject: [PATCH] Remove 2012 R2 support Sandstorm doesn't support it --- modSystem.cs | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/modSystem.cs b/modSystem.cs index 2edc56a..35e26c2 100644 --- a/modSystem.cs +++ b/modSystem.cs @@ -77,13 +77,7 @@ public static string GetWindowsVersion() try { RegistryKey currentVersion = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\MICROSOFT\Windows NT\CurrentVersion"); - string currentWindowsVersion = ""; - if (currentVersion.GetValue("CurrentBuild").ToString() == "9600") { - // Temporary support for Windows Server 2012 R2 - currentWindowsVersion = "6.3.9600." + "." + currentVersion.GetValue("UBR").ToString(); - } else { - currentWindowsVersion = currentVersion.GetValue("CurrentMajorVersionNumber").ToString() + "." + currentVersion.GetValue("CurrentMinorVersionNumber").ToString() + "." + currentVersion.GetValue("CurrentBuild").ToString() + "." + currentVersion.GetValue("UBR").ToString(); - } + string currentWindowsVersion = currentVersion.GetValue("CurrentMajorVersionNumber").ToString() + "." + currentVersion.GetValue("CurrentMinorVersionNumber").ToString() + "." + currentVersion.GetValue("CurrentBuild").ToString() + "." + currentVersion.GetValue("UBR").ToString(); string oldWindowsVersion = modDatabase.GetConfig("System_LastKnownWindowsVersion"); if (oldWindowsVersion != currentWindowsVersion)