From 85ecef310a3bdcf51498aa14a2a33adf7df173e8 Mon Sep 17 00:00:00 2001 From: pizzaboxer Date: Thu, 4 May 2023 10:15:55 +0100 Subject: [PATCH] Remove 32-bit support MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 💀💀💀 32 bit is GONE 💀💀💀 --- .github/workflows/ci.yml | 9 +-------- Bloxstrap/App.xaml.cs | 23 ----------------------- Bloxstrap/Bootstrapper.cs | 13 ++++--------- 3 files changed, 5 insertions(+), 40 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5a36299..447939d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,7 +13,7 @@ jobs: strategy: matrix: configuration: [Debug, Release] - platform: [x64, x86] + platform: [x64] runs-on: windows-latest steps: @@ -47,20 +47,13 @@ jobs: with: name: Bloxstrap (Release, x64) path: x64 - - name: Download x86 release artifact - uses: actions/download-artifact@v3 - with: - name: Bloxstrap (Release, x86) - path: x86 - name: Rename binaries run: | mv x64/Bloxstrap.exe Bloxstrap-${{ github.ref_name }}-x64.exe - mv x86/Bloxstrap.exe Bloxstrap-${{ github.ref_name }}-x86.exe - name: Release uses: softprops/action-gh-release@v1 with: draft: true files: | Bloxstrap-${{ github.ref_name }}-x64.exe - Bloxstrap-${{ github.ref_name }}-x86.exe name: Bloxstrap ${{ github.ref_name }} diff --git a/Bloxstrap/App.xaml.cs b/Bloxstrap/App.xaml.cs index 86d5c1a..98a37e2 100644 --- a/Bloxstrap/App.xaml.cs +++ b/Bloxstrap/App.xaml.cs @@ -169,29 +169,6 @@ namespace Bloxstrap Visible = !IsMenuLaunch }; - // todo: remove this once 32-bit support is fully gone - if (!App.IsQuiet && !Environment.Is64BitOperatingSystem) - { - string message = "In the near future, Roblox will no longer support 32-bit Windows devices. To keep playing Roblox, please use a device that is 64-bit compatible."; - - // check if the processor actually supports 64-bit with wmic - // chances are the user just has a 32-bit version of windows installed on 64-bit hardware - Process p = new(); - p.StartInfo.CreateNoWindow = true; - p.StartInfo.UseShellExecute = false; - p.StartInfo.RedirectStandardOutput = true; - p.StartInfo.FileName = "wmic.exe"; - p.StartInfo.Arguments = "cpu get Architecture"; - p.Start(); - - // https://learn.microsoft.com/en-us/windows/win32/cimwin32prov/win32-processor - // architecture type 9 is x64 - if (p.StandardOutput.ReadToEnd().Contains('9')) - message += "\n\nYour computer is running a 32-bit version of Windows but is actually 64-bit compatible. Search online for how to upgrade to a 64-bit version of Windows."; - - ShowMessageBox(message, MessageBoxImage.Warning); - } - // check if installed using (RegistryKey? registryKey = Registry.CurrentUser.OpenSubKey($@"Software\{ProjectName}")) { diff --git a/Bloxstrap/Bootstrapper.cs b/Bloxstrap/Bootstrapper.cs index d710987..d58c18b 100644 --- a/Bloxstrap/Bootstrapper.cs +++ b/Bloxstrap/Bootstrapper.cs @@ -99,15 +99,10 @@ namespace Bloxstrap // check if the webview2 runtime needs to be installed // webview2 can either be installed be per-user or globally, so we need to check in both hklm and hkcu - // https://learn.microsoft.com/en-us/microsoft-edge/webview2/concepts/distribution#online-only-deployment + // https://learn.microsoft.com/en-us/microsoft-edge/webview2/concepts/distribution#detect-if-a-suitable-webview2-runtime-is-already-installed - string hklmLocation = "SOFTWARE\\WOW6432Node\\Microsoft\\EdgeUpdate\\Clients\\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}"; - string hkcuLocation = "Software\\Microsoft\\EdgeUpdate\\Clients\\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}"; - - if (!Environment.Is64BitOperatingSystem) - hklmLocation = "SOFTWARE\\Microsoft\\EdgeUpdate\\Clients\\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}"; - - ShouldInstallWebView2 = Registry.LocalMachine.OpenSubKey(hklmLocation) is null && Registry.CurrentUser.OpenSubKey(hkcuLocation) is null; + string registryLocation = "SOFTWARE\\Microsoft\\EdgeUpdate\\Clients\\{F3017226-FE2A-4295-8BDF-00C3A9A7E4C5}"; + ShouldInstallWebView2 = Registry.LocalMachine.OpenSubKey(registryLocation) is null && Registry.CurrentUser.OpenSubKey(registryLocation) is null; } private void SetStatus(string message) @@ -581,7 +576,7 @@ namespace Bloxstrap SetStatus($"Getting the latest {App.ProjectName}..."); // 64-bit is always the first option - GithubReleaseAsset asset = releaseInfo.Assets[Environment.Is64BitOperatingSystem ? 0 : 1]; + GithubReleaseAsset asset = releaseInfo.Assets[0]; string downloadLocation = Path.Combine(Directories.LocalAppData, "Temp", asset.Name); App.Logger.WriteLine($"[Bootstrapper::CheckForUpdates] Downloading {releaseInfo.Name}...");