From 9c20534f5ccc3db002aa05d893908f6992dc4a16 Mon Sep 17 00:00:00 2001 From: Chris <50419942+flaeri@users.noreply.github.com> Date: Sat, 15 Jan 2022 10:06:47 +0100 Subject: [PATCH] Adding msStore verion, improve logging (#3) --- AddJavawPath.ps1 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/AddJavawPath.ps1 b/AddJavawPath.ps1 index 8173ee9..00aa8a3 100644 --- a/AddJavawPath.ps1 +++ b/AddJavawPath.ps1 @@ -28,18 +28,18 @@ $mcSearchPaths = ` #Stock and Forge "C:\Program Files (x86)\Minecraft Launcher\runtime", ` #Badlion -"C:\ProgramData\BadlionClient" +"C:\ProgramData\BadlionClient", ` +#MsStore +"$env:LOCALAPPDATA\Packages\Microsoft.4297127D64EC6_8wekyb3d8bbwe\LocalCache\Local\runtime" foreach ($item in $mcSearchPaths) { + write-host "-------------------------" Write-Host "Testing $item" -ForegroundColor Yellow - write-host "`n" if (test-path $item) { write-host "Found: $item" -ForegroundColor Green - write-host "`n" $javaWPath = (Get-ChildItem -Path $item -Filter javaw.exe -Recurse).fullname foreach ($path in $javaWPath) { write-host "Adding: $path" -ForegroundColor Green - write-host "`n" Set-ItemProperty -path HKCU:\SOFTWARE\Microsoft\DirectX\UserGpuPreferences -Name $path -Value "GpuPreference=2;" } }