DepotDownloader: don't use dedicatedserverfolder for Steam3 downloads.

pull/8/head
Nicholas Hastings 13 years ago
parent c03aa33b77
commit 140f7705cf

@ -71,7 +71,7 @@ namespace DepotDownloader
} }
} }
static bool CreateDirectories( int depotId, uint depotVersion, out string installDir ) static bool CreateDirectories( int depotId, uint depotVersion, DownloadSource source, out string installDir )
{ {
installDir = null; installDir = null;
try try
@ -90,15 +90,16 @@ namespace DepotDownloader
{ {
Directory.CreateDirectory(ContentDownloader.Config.InstallDirectory); Directory.CreateDirectory(ContentDownloader.Config.InstallDirectory);
string serverFolder = CDRManager.GetDedicatedServerFolder( depotId ); installDir = ContentDownloader.Config.InstallDirectory;
if ( serverFolder != null && serverFolder != "" )
if (source == DownloadSource.Steam2)
{
string serverFolder = CDRManager.GetDedicatedServerFolder(depotId);
if (serverFolder != null && serverFolder != "")
{ {
installDir = Path.Combine(ContentDownloader.Config.InstallDirectory, serverFolder); installDir = Path.Combine(ContentDownloader.Config.InstallDirectory, serverFolder);
Directory.CreateDirectory(installDir); Directory.CreateDirectory(installDir);
} }
else
{
installDir = ContentDownloader.Config.InstallDirectory;
} }
} }
} }
@ -650,7 +651,7 @@ namespace DepotDownloader
} }
string installDir; string installDir;
if (!CreateDirectories(depotId, uVersion, out installDir)) if (!CreateDirectories(depotId, uVersion, source, out installDir))
{ {
Console.WriteLine("Error: Unable to create install directories!"); Console.WriteLine("Error: Unable to create install directories!");
return null; return null;

Loading…
Cancel
Save