mirror of
https://github.com/SteamRE/DepotDownloader.git
synced 2026-10-20 01:46:17 +00:00
Target SteamKit 2.4.0-Alpha.2
This commit is contained in:
1 parent
60b4451417
commit
27960f3d18
3 files changed
+1
-19
No files matched your search
@@ -19,9 +19,7 @@ namespace DepotDownloader
|
||||
private readonly Steam3Session steamSession;
|
||||
private readonly uint appId;
|
||||
public CDNClient CDNClient { get; }
|
||||
#if STEAMKIT_UNRELEASED
|
||||
public CDNClient.Server ProxyServer { get; private set; }
|
||||
#endif
|
||||
|
||||
private readonly ConcurrentStack<CDNClient.Server> activeConnectionPool;
|
||||
private readonly BlockingCollection<CDNClient.Server> availableServerEndpoints;
|
||||
@@ -101,19 +99,13 @@ namespace DepotDownloader
|
||||
return;
|
||||
}
|
||||
|
||||
#if STEAMKIT_UNRELEASED
|
||||
ProxyServer = servers.Where(x => x.UseAsProxy).FirstOrDefault();
|
||||
#endif
|
||||
|
||||
var weightedCdnServers = servers
|
||||
.Where(server =>
|
||||
{
|
||||
#if STEAMKIT_UNRELEASED
|
||||
var isEligibleForApp = server.AllowedAppIds == null || server.AllowedAppIds.Contains(appId);
|
||||
return isEligibleForApp && (server.Type == "SteamCache" || server.Type == "CDN");
|
||||
#else
|
||||
return server.Type == "SteamCache" || server.Type == "CDN";
|
||||
#endif
|
||||
})
|
||||
.Select(server =>
|
||||
{
|
||||
|
||||
@@ -827,13 +827,8 @@ namespace DepotDownloader
|
||||
connection = cdnPool.GetConnection(cts.Token);
|
||||
var cdnToken = await cdnPool.AuthenticateConnection(appId, depot.id, connection);
|
||||
|
||||
#if STEAMKIT_UNRELEASED
|
||||
depotManifest = await cdnPool.CDNClient.DownloadManifestAsync(depot.id, depot.manifestId,
|
||||
connection, cdnToken, depot.depotKey, proxyServer: cdnPool.ProxyServer).ConfigureAwait(false);
|
||||
#else
|
||||
depotManifest = await cdnPool.CDNClient.DownloadManifestAsync(depot.id, depot.manifestId,
|
||||
connection, cdnToken, depot.depotKey).ConfigureAwait(false);
|
||||
#endif
|
||||
|
||||
cdnPool.ReturnConnection(connection);
|
||||
}
|
||||
@@ -1200,13 +1195,8 @@ namespace DepotDownloader
|
||||
connection = cdnPool.GetConnection(cts.Token);
|
||||
var cdnToken = await cdnPool.AuthenticateConnection(appId, depot.id, connection);
|
||||
|
||||
#if STEAMKIT_UNRELEASED
|
||||
chunkData = await cdnPool.CDNClient.DownloadDepotChunkAsync(depot.id, data,
|
||||
connection, cdnToken, depot.depotKey, proxyServer: cdnPool.ProxyServer).ConfigureAwait(false);
|
||||
#else
|
||||
chunkData = await cdnPool.CDNClient.DownloadDepotChunkAsync(depot.id, data,
|
||||
connection, cdnToken, depot.depotKey).ConfigureAwait(false);
|
||||
#endif
|
||||
|
||||
cdnPool.ReturnConnection(connection);
|
||||
}
|
||||
|
||||
@@ -6,6 +6,6 @@
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="protobuf-net" Version="3.0.73" />
|
||||
<PackageReference Include="SteamKit2" Version="2.3.0" />
|
||||
<PackageReference Include="SteamKit2" Version="2.4.0-Alpha.2" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
Reference in new issue
Block a user