Guildwars 2 on DX11 with ArcDPS
With the dx11 beta within Guildwars2 all the fancy addons are also being updated. ArcDPS gets his updater slightly adjusted..
save as arc-updater.ps1
and place it into C:\Program Files\Guild Wars 2\
and create a shortcut to the desktop or whatever.
note that this script is updated with reshade.me in mind, e.g reshade is the dxgi.dll
while arc is at d3d11.dll
#Modify as required. Points to the default install location
$GW2Path = "C:\Program Files\Guild Wars 2\"
#Don't change these paths unless arc does
$md5sum = 'https://www.deltaconnected.com/arcdps/x64/d3d9.dll.md5sum'
$d3d11 = 'https://www.deltaconnected.com/arcdps/x64/d3d9.dll'
#And this one unless ANet does
$gw = 'Gw2-64'
function Get-ArcDps
{
write-host 'Downloading ArcDps'
$d3d11Temp = New-TemporaryFile
Invoke-WebRequest -Uri $d3d11 -OutFile $d3d11Temp.FullName
Copy-Item $d3d11Temp.FullName "$($GW2Path)\d3d11.dll" -Force
Remove-Item $d3d11Temp.FullName -Force
write-host 'Completed ArcDps install'
}
function Invoke-ArcDpsCheck
{
$date = (Get-Date -format "dd-MM-yyyy")
if((Get-Process $gw -EA 0).Count -gt 0)
{
Exit
}
$ignoreCase = [System.StringComparison]::InvariantCultureIgnoreCase
$md5Temp = New-TemporaryFile
Invoke-WebRequest -Uri $md5sum -OutFile $md5Temp.FullName
$md5Hash = Get-Content $md5Temp
$md5Hash = $md5Hash.Substring(0,$md5Hash.IndexOf(' '))
$fileExists = Test-Path "$($GW2Path)\d3d11.dll"
if($fileExists)
{
$md5D3d9m = Get-FileHash "$($GW2Path)\d3d11.dll" -Algorithm MD5
if(!$md5D3d9m.Hash.Equals($md5Hash,$ignoreCase))
{
Write-Host 'ArcDps is out of date'
try
{
Rename-Item "$($GW2Path)\d3d11.dll" -NewName "$($GW2Path)\d3d11.$date" -Force
}
catch {}
Get-ArcDps
}
else
{
write-host 'ArcDps is up to date'
}
}
else
{
Get-ArcDps
}
}
Invoke-ArcDpsCheck
pause