Added check for profiles location.
This commit is contained in:
@@ -253,8 +253,6 @@ if ($becLocation) {
|
||||
$becProcess = [Object[]]::new($servers.Count)
|
||||
}
|
||||
|
||||
EXIT
|
||||
|
||||
foreach ($srv in $servers) {
|
||||
$instance = ${srv}
|
||||
$serverPort = $ini.${srv}.serverPort
|
||||
@@ -283,7 +281,16 @@ foreach ($srv in $servers) {
|
||||
}
|
||||
}
|
||||
|
||||
$serverProfile = "$($serverLocation)\profiles\$($instance)"
|
||||
# Checks for profile location
|
||||
if ([System.IO.Path]::IsPathRooted($profilesLocation)) {
|
||||
$serverProfile = "$($profilesLocation)\$($instance)"
|
||||
}
|
||||
else {
|
||||
$serverProfile = "$($serverLocation)\$($profilesLocation)\$($instance)"
|
||||
}
|
||||
$serverProfile = [System.IO.Path]::GetFullPath($serverProfile)
|
||||
Write-Host "serverProfile: $($serverProfile)"
|
||||
|
||||
$startupMods = @("`"-mod=$($startupClientMods)`"", "`"-serverMod=$($startupServerMods)`"")
|
||||
$startupParams = @("`"-profiles=$($serverProfile)`"", "`"-config=$($serverProfile)\$($serverConfig)`"", "-port=$($serverPort)", "-cpuCount=$($serverCPU)")
|
||||
$dayzArguments = $startupParams + $startupMods + $additionalParams
|
||||
@@ -431,6 +438,14 @@ foreach ($srv in $servers) {
|
||||
Write-Host
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region ### wDayzManager ###
|
||||
|
||||
#endregion
|
||||
|
||||
#region ### Dayz stats logs ###
|
||||
|
||||
#endregion
|
||||
}
|
||||
|
||||
# Write-Host " instance: $($instance)"
|
||||
|
||||
Reference in New Issue
Block a user