Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ArmageddonLP committed May 19, 2023
0 parents commit 07cf728
Show file tree
Hide file tree
Showing 5 changed files with 142 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# ignore the log file
*.txt
40 changes: 40 additions & 0 deletions GW2_ARCDPS_UPDATER.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
$folder = [string](Get-Location)+"\"
$urlArcDps = "https://www.deltaconnected.com/arcdps/x64/d3d11.dll"
$pathArcDps = $folder + "d3d11.dll"
$urlKillProof = "https://github.com/knoxfighter/arcdps-killproof.me-plugin/releases/latest/download/d3d9_arcdps_killproof_me.dll"
$pathKillProof = $folder + "bin64\d3d9_arcdps_killproof_me.dll"
$urlMechanic = "https://github.com/knoxfighter/GW2-ArcDPS-Mechanics-Log/releases/latest/download/d3d9_arcdps_mechanics.dll"
$pathMechanic = $folder + "bin64\d3d9_arcdps_mechanics.dll"
$urlBoonTable = "https://github.com/knoxfighter/GW2-ArcDPS-Boon-Table/releases/latest/download/d3d9_arcdps_table.dll"
$pathBoonTable = $folder + "bin64\d3d9_arcdps_table.dll"
$urlHealing = "https://github.com/Krappa322/arcdps_healing_stats/releases/latest/download/arcdps_healing_stats.dll"
$pathHealing = $folder + "bin64\arcdps_healing_stats.dll"
$urlClears = "https://github.com/gw2scratch/arcdps-clears/releases/latest/download/arcdps_clears.dll"
$pathClears = $folder + "bin64\arcdps_clears.dll"
$urlExtras = "https://github.com/Krappa322/arcdps_unofficial_extras_releases/releases/latest/download/arcdps_unofficial_extras.dll"
$pathExtras = $folder + "bin64\arcdps_unofficial_extras.dll"

$mode = Read-Host -Prompt "(u)pdate or (d)eactivate? "
if ($mode -eq "D" -or $mode -eq "d") {
Write-Host -ForegroundColor blue "started deactivation`n"
Remove-Item -Path $pathArcDps
Write-Host -ForegroundColor green "started deactivation`n"
}
else {
Write-Host -ForegroundColor blue "started update`n"
#define addons to be installed
$dlls = @($urlArcDps, $pathArcDps),
@($urlKillProof, $pathKillProof),
@($urlMechanic, $pathMechanic),
@($urlBoonTable, $pathBoonTable),
@($urlHealing, $pathHealing),
@($urlClears, $pathClears),
@($urlExtras, $pathExtras)
#loop through all selected addons and download/install them
foreach ($dll in $dlls) {
$infoText = $dll[0] + "`n" + $dll[1] + "`n`n"
Write-Host $infoText
Invoke-WebRequest -URI $dll[0] -OutFile $dll[1]
}
Write-Host -ForegroundColor green "finished update`n"
}
Binary file added GW2_ARCDPS_UPDATER.ps1 - Shortcut.lnk
Binary file not shown.
43 changes: 43 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# gw2_arcdps_updater

## windows

### setup

Copy "GW2_ARCDPS_UPDATER.ps1" next to your GW2-Executable

Copy "GW2_ARCDPS_UPDATER.ps1 - Shortcut.lnk" to wherever you want to have an easy way to run the script

### configure

Change both "Target" and "Start in" of "GW2_ARCDPS_UPDATER.ps1 - Shortcut.lnk" so they use the actual location of your GW2 installation

### usage

Double Click "GW2_ARCDPS_UPDATER.ps1 - Shortcut.lnk"

OR

Run "GW2_ARCDPS_UPDATER.ps1" directly using Powerhsell (You'll likely need to configure the ExecutionBypassPolicy)

You can either run the script for (d)eactivation or for (u)pdate

If you just press ENTER it will run in update mode

## linux

### setup

Copy "gw2_arcdps_updater.sh" next to your GW2-Executable

### configure

None needed

### usage

Run "bash gw2_arcdps_updater.sh" in the folder you have installed gw2 in

You can either run the script for (d)eactivation or for (u)pdate

If you just press ENTER it will run in update mode
57 changes: 57 additions & 0 deletions gw2_arcdps_updater.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
#!bin/bash
#bash gw2_arcdps_updater.sh

BLACK='\033[0;30m'
RED='\033[0;31m'
GREEN='\033[0;32m'
BLUE='\033[0;34m'
folder=$(pwd)'/'
urlArcDps='https://www.deltaconnected.com/arcdps/x64/d3d11.dll'
pathArcDps=$folder'd3d11.dll'
urlKillProof='https://github.com/knoxfighter/arcdps-killproof.me-plugin/releases/latest/download/d3d9_arcdps_killproof_me.dll'
pathKillProof=$folder'bin64/d3d9_arcdps_killproof_me.dll'
urlMechanic='https://github.com/knoxfighter/GW2-ArcDPS-Mechanics-Log/releases/latest/download/d3d9_arcdps_mechanics.dll'
pathMechanic=$folder'bin64/d3d9_arcdps_mechanics.dll'
urlBoonTable='https://github.com/knoxfighter/GW2-ArcDPS-Boon-Table/releases/latest/download/d3d9_arcdps_table.dll'
pathBoonTable=$folder'bin64/d3d9_arcdps_table.dll'
urlHealing='https://github.com/Krappa322/arcdps_healing_stats/releases/latest/download/arcdps_healing_stats.dll'
pathHealing=$folder'bin64/arcdps_healing_stats.dll'
urlClears='https://github.com/gw2scratch/arcdps-clears/releases/latest/download/arcdps_clears.dll'
pathClears=$folder'bin64/arcdps_clears.dll'
urlExtras='https://github.com/Krappa322/arcdps_unofficial_extras_releases/releases/latest/download/arcdps_unofficial_extras.dll'
pathExtras=$folder'bin64/arcdps_unofficial_extras.dll'

read -p '(u)pdate or (d)eactivate? ' mode
if [ $mode == 'D' ] || [ $mode == 'd' ] ;
then
printf $BLUE'started deactivation\n'$BLACK
rm "$pathArcDps"
printf $GREEN'finished deactivation\n'$BLACK
else
printf $BLUE'started update\n'$BLACK
if which curl >/dev/null ;
then
#define addons to be installed
addons=(
$urlArcDps';'$pathArcDps
$urlKillProof';'$pathKillProof
$urlMechanic';'$pathMechanic
$urlBoonTable';'$pathBoonTable
$urlHealing';'$pathHealing
$urlClears';'$pathClears
$urlExtras';'$pathExtras
)
#create bin64 folder if missing
mkdir -p bin64
#loop through all selected addons and download/install them
for addon in ${addons[@]};
do
IFS=';' read -r -a a <<< $addon
printf ${a[0]}'\n'${a[1]}'\n\n'
curl -o ${a[1]} ${a[0]}
done
printf $GREEN'finished update\n'$BLACK
else
printf $RED'failed update: missing curl: apt update -y;apt upgrade -y;apt install curl -y\n'$BLACK
fi
fi

0 comments on commit 07cf728

Please sign in to comment.