forked from Albeoris/Memoria
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSetupProjectEnvironment.ps1
141 lines (132 loc) · 7.91 KB
/
SetupProjectEnvironment.ps1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
# check we're elivated
if (-Not ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] 'Administrator')) {
if ([int](Get-CimInstance -Class Win32_OperatingSystem | Select-Object -ExpandProperty BuildNumber) -ge 6000) {
$CommandLine = "-File `"" + $MyInvocation.MyCommand.Path + "`" " + $MyInvocation.UnboundArguments
Start-Process -FilePath PowerShell.exe -Verb Runas -ArgumentList $CommandLine
Exit
}
}
Set-Location $PSScriptRoot;
# make sure windows feature is installed
$net3State = Get-WindowsCapability -Online -Name NetFx3
if($net3State.State -ne "Installed"){
Add-WindowsCapability -Online -Name NetFx3
}
$skdInstallPath = "C:\Program Files (x86)\Windows Kits\8.1\bin\x64"
$pathState = Test-Path -Path $skdInstallPath
if(!$pathState){
Invoke-WebRequest https://go.microsoft.com/fwlink/p/?LinkId=323507 -OutFile sdksetup.exe
Start-Process sdksetup.exe -Wait
}
# find the game install location
$appId = "377840";
$gameInstalled = Test-Path -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Steam App $($appId)"
if(!$gameInstalled){
Write-Error "Final Fantasy IX is not installed via Steam we don't support piracy"
exit
}
$ff9InstallLoc = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Steam App $($appId)"
# copy files
$filesPath = "$($ff9InstallLoc.InstallLocation)\x64\FF9_Data\Managed\"
$dest = Resolve-Path "./References/"
get-childitem $filesPath -recurse | Where-Object {$_.extension -eq ".dll"} | ForEach-Object {
Write-Output "Copying $($_.Name)"
Copy-Item -Path $_.FullName -Destination $dest
}
Write-Output "Project has been setup you can now open the solution file."
read-host "Press ENTER to exit"
# SIG # Begin signature block
# MIIRYQYJKoZIhvcNAQcCoIIRUjCCEU4CAQExDzANBglghkgBZQMEAgEFADB5Bgor
# BgEEAYI3AgEEoGswaTA0BgorBgEEAYI3AgEeMCYCAwEAAAQQH8w7YFlLCE63JNLG
# KX7zUQIBAAIBAAIBAAIBAAIBADAxMA0GCWCGSAFlAwQCAQUABCAE/XfdPtNWSBJh
# 2QIm89A8mstsNNXwjPaCvmiyy6HPraCCDaQwgga5MIIEoaADAgECAhEAmaOACiZV
# O2Wr3G6EprPqOTANBgkqhkiG9w0BAQwFADCBgDELMAkGA1UEBhMCUEwxIjAgBgNV
# BAoTGVVuaXpldG8gVGVjaG5vbG9naWVzIFMuQS4xJzAlBgNVBAsTHkNlcnR1bSBD
# ZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTEkMCIGA1UEAxMbQ2VydHVtIFRydXN0ZWQg
# TmV0d29yayBDQSAyMB4XDTIxMDUxOTA1MzIxOFoXDTM2MDUxODA1MzIxOFowVjEL
# MAkGA1UEBhMCUEwxITAfBgNVBAoTGEFzc2VjbyBEYXRhIFN5c3RlbXMgUy5BLjEk
# MCIGA1UEAxMbQ2VydHVtIENvZGUgU2lnbmluZyAyMDIxIENBMIICIjANBgkqhkiG
# 9w0BAQEFAAOCAg8AMIICCgKCAgEAnSPPBDAjO8FGLOczcz5jXXp1ur5cTbq96y34
# vuTmflN4mSAfgLKTvggv24/rWiVGzGxT9YEASVMw1Aj8ewTS4IndU8s7VS5+djSo
# McbvIKck6+hI1shsylP4Jy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