diff --git a/DepotDownloader/AccountSettingsStore.cs b/DepotDownloader.Core/AccountSettingsStore.cs similarity index 97% rename from DepotDownloader/AccountSettingsStore.cs rename to DepotDownloader.Core/AccountSettingsStore.cs index 2a8c9836..7355a44b 100644 --- a/DepotDownloader/AccountSettingsStore.cs +++ b/DepotDownloader.Core/AccountSettingsStore.cs @@ -8,10 +8,10 @@ using System.Linq; using SteamKit2; using SteamKit2.Discovery; -namespace DepotDownloader +namespace DepotDownloader.Core { [ProtoContract] - class AccountSettingsStore + public class AccountSettingsStore { [ProtoMember(1, IsRequired=false)] public Dictionary SentryData { get; private set; } diff --git a/DepotDownloader/CDNClientPool.cs b/DepotDownloader.Core/CDNClientPool.cs similarity index 99% rename from DepotDownloader/CDNClientPool.cs rename to DepotDownloader.Core/CDNClientPool.cs index 120bb73f..ac7e767f 100644 --- a/DepotDownloader/CDNClientPool.cs +++ b/DepotDownloader.Core/CDNClientPool.cs @@ -7,12 +7,12 @@ using System.Net; using System.Threading; using System.Threading.Tasks; -namespace DepotDownloader +namespace DepotDownloader.Core { /// /// CDNClientPool provides a pool of connections to CDN endpoints, requesting CDN tokens as needed /// - class CDNClientPool + public class CDNClientPool { private const int ServerEndpointMinimumSize = 8; diff --git a/DepotDownloader/ContentDownloader.cs b/DepotDownloader.Core/ContentDownloader.cs similarity index 97% rename from DepotDownloader/ContentDownloader.cs rename to DepotDownloader.Core/ContentDownloader.cs index fd277937..82e3d96d 100644 --- a/DepotDownloader/ContentDownloader.cs +++ b/DepotDownloader.Core/ContentDownloader.cs @@ -1,4 +1,4 @@ -using SteamKit2; +using SteamKit2; using System; using System.Collections.Concurrent; using System.Collections.Generic; @@ -10,14 +10,14 @@ using System.Text.RegularExpressions; using System.Threading; using System.Threading.Tasks; -namespace DepotDownloader +namespace DepotDownloader.Core { public class ContentDownloaderException : System.Exception { public ContentDownloaderException( String value ) : base( value ) {} } - static class ContentDownloader + public static class ContentDownloader { public const uint INVALID_APP_ID = uint.MaxValue; public const uint INVALID_DEPOT_ID = uint.MaxValue; diff --git a/DepotDownloader/DepotConfigStore.cs b/DepotDownloader.Core/DepotConfigStore.cs similarity index 98% rename from DepotDownloader/DepotConfigStore.cs rename to DepotDownloader.Core/DepotConfigStore.cs index 79a414ab..9305a020 100644 --- a/DepotDownloader/DepotConfigStore.cs +++ b/DepotDownloader.Core/DepotConfigStore.cs @@ -4,7 +4,7 @@ using ProtoBuf; using System.IO; using System.IO.Compression; -namespace DepotDownloader +namespace DepotDownloader.Core { [ProtoContract] class DepotConfigStore diff --git a/DepotDownloader.Core/DepotDownloader.Core.csproj b/DepotDownloader.Core/DepotDownloader.Core.csproj new file mode 100644 index 00000000..572001e3 --- /dev/null +++ b/DepotDownloader.Core/DepotDownloader.Core.csproj @@ -0,0 +1,27 @@ + + + + netstandard2.1 + LICENSE + SteamRE et al. + SteamRE et al + DepotDownloader + Steam depot downloader utilizing the SteamKit2 library. Core library built on .NET Standard 2.0 + https://github.com/SteamRE/DepotDownloader + git + 2.4.0 + + + + + + + + + + True + + + + + diff --git a/DepotDownloader/DownloadConfig.cs b/DepotDownloader.Core/DownloadConfig.cs similarity index 92% rename from DepotDownloader/DownloadConfig.cs rename to DepotDownloader.Core/DownloadConfig.cs index 780fd56a..8024b182 100644 --- a/DepotDownloader/DownloadConfig.cs +++ b/DepotDownloader.Core/DownloadConfig.cs @@ -1,33 +1,33 @@ -using System.Collections.Generic; -using System.Text.RegularExpressions; - -namespace DepotDownloader -{ - class DownloadConfig - { - public int CellID { get; set; } - public bool DownloadAllPlatforms { get; set; } - public bool DownloadAllLanguages { get; set; } - public bool DownloadManifestOnly { get; set; } - public string InstallDirectory { get; set; } - - public bool UsingFileList { get; set; } - public List FilesToDownload { get; set; } - public List FilesToDownloadRegex { get; set; } - - public bool UsingExclusionList { get; set; } - - public string BetaPassword { get; set; } - - public bool VerifyAll { get; set; } - - public int MaxServers { get; set; } - public int MaxDownloads { get; set; } - - public string SuppliedPassword { get; set; } - public bool RememberPassword { get; set; } - - // A Steam LoginID to allow multiple concurrent connections - public uint? LoginID {get; set; } - } -} +using System.Collections.Generic; +using System.Text.RegularExpressions; + +namespace DepotDownloader.Core +{ + public class DownloadConfig + { + public int CellID { get; set; } + public bool DownloadAllPlatforms { get; set; } + public bool DownloadAllLanguages { get; set; } + public bool DownloadManifestOnly { get; set; } + public string InstallDirectory { get; set; } + + public bool UsingFileList { get; set; } + public List FilesToDownload { get; set; } + public List FilesToDownloadRegex { get; set; } + + public bool UsingExclusionList { get; set; } + + public string BetaPassword { get; set; } + + public bool VerifyAll { get; set; } + + public int MaxServers { get; set; } + public int MaxDownloads { get; set; } + + public string SuppliedPassword { get; set; } + public bool RememberPassword { get; set; } + + // A Steam LoginID to allow multiple concurrent connections + public uint? LoginID {get; set; } + } +} diff --git a/DepotDownloader/ProtoManifest.cs b/DepotDownloader.Core/ProtoManifest.cs similarity index 98% rename from DepotDownloader/ProtoManifest.cs rename to DepotDownloader.Core/ProtoManifest.cs index f521c5cc..e412d67e 100644 --- a/DepotDownloader/ProtoManifest.cs +++ b/DepotDownloader.Core/ProtoManifest.cs @@ -6,10 +6,10 @@ using System.IO.Compression; using ProtoBuf; using SteamKit2; -namespace DepotDownloader +namespace DepotDownloader.Core { [ProtoContract()] - class ProtoManifest + public class ProtoManifest { // Proto ctor private ProtoManifest() diff --git a/DepotDownloader/Steam3Session.cs b/DepotDownloader.Core/Steam3Session.cs similarity index 96% rename from DepotDownloader/Steam3Session.cs rename to DepotDownloader.Core/Steam3Session.cs index 7f33b65e..bb50c789 100644 --- a/DepotDownloader/Steam3Session.cs +++ b/DepotDownloader.Core/Steam3Session.cs @@ -1,4 +1,4 @@ -using SteamKit2; +using SteamKit2; using SteamKit2.Internal; using System; using System.Collections.Concurrent; @@ -9,10 +9,10 @@ using System.Linq; using System.Threading; using System.Threading.Tasks; -namespace DepotDownloader +namespace DepotDownloader.Core { - class Steam3Session + public class Steam3Session { public class Credentials { @@ -657,7 +657,7 @@ namespace DepotDownloader { if ( license.AccessToken > 0 ) { - PackageTokens.TryAdd( license.PackageID, license.AccessToken ); + PackageTokens.TryAdd(license.PackageID, license.AccessToken); } } } diff --git a/DepotDownloader/Util.cs b/DepotDownloader.Core/Util.cs similarity index 95% rename from DepotDownloader/Util.cs rename to DepotDownloader.Core/Util.cs index 7d866487..c9d090bf 100644 --- a/DepotDownloader/Util.cs +++ b/DepotDownloader.Core/Util.cs @@ -1,4 +1,4 @@ -using System; +using System; using System.Collections.Generic; using System.IO; using System.Linq; @@ -7,9 +7,9 @@ using System.Security.Cryptography; using System.Text; using System.Threading.Tasks; -namespace DepotDownloader +namespace DepotDownloader.Core { - static class Util + public static class Util { public static string GetSteamOS() { diff --git a/DepotDownloader.sln b/DepotDownloader.sln index 631e75ec..81676bda 100644 --- a/DepotDownloader.sln +++ b/DepotDownloader.sln @@ -1,9 +1,11 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 15 -VisualStudioVersion = 15.0.26228.4 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.30517.126 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DepotDownloader", "DepotDownloader\DepotDownloader.csproj", "{39159C47-ACD3-449F-96CA-4F30C8ED147A}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DepotDownloader", "DepotDownloader\DepotDownloader.csproj", "{39159C47-ACD3-449F-96CA-4F30C8ED147A}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DepotDownloader.Core", "DepotDownloader.Core\DepotDownloader.Core.csproj", "{8303B6A1-CE40-4C26-9376-DB08290645F7}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -15,8 +17,15 @@ Global {39159C47-ACD3-449F-96CA-4F30C8ED147A}.Debug|Any CPU.Build.0 = Debug|Any CPU {39159C47-ACD3-449F-96CA-4F30C8ED147A}.Release|Any CPU.ActiveCfg = Release|Any CPU {39159C47-ACD3-449F-96CA-4F30C8ED147A}.Release|Any CPU.Build.0 = Release|Any CPU + {8303B6A1-CE40-4C26-9376-DB08290645F7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {8303B6A1-CE40-4C26-9376-DB08290645F7}.Debug|Any CPU.Build.0 = Debug|Any CPU + {8303B6A1-CE40-4C26-9376-DB08290645F7}.Release|Any CPU.ActiveCfg = Release|Any CPU + {8303B6A1-CE40-4C26-9376-DB08290645F7}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {B9D19618-4471-4B6A-999B-3884575BE066} + EndGlobalSection EndGlobal diff --git a/DepotDownloader/DepotDownloader.csproj b/DepotDownloader/DepotDownloader.csproj index b578a3b9..dc1affc1 100644 --- a/DepotDownloader/DepotDownloader.csproj +++ b/DepotDownloader/DepotDownloader.csproj @@ -5,7 +5,6 @@ false - - + \ No newline at end of file diff --git a/DepotDownloader/Program.cs b/DepotDownloader/Program.cs index d2a77266..7ba53d13 100644 --- a/DepotDownloader/Program.cs +++ b/DepotDownloader/Program.cs @@ -6,6 +6,8 @@ using SteamKit2; using System.ComponentModel; using System.Threading.Tasks; using System.Runtime.InteropServices; +using DepotDownloader.Core; + namespace DepotDownloader { class Program