Skip to content

Commit

Permalink
2.4.7 - Don't use depotfromapp to request depot key or manifest reque…
Browse files Browse the repository at this point in the history
…st code
  • Loading branch information
azuisleet committed Aug 20, 2022
1 parent 4ee9db7 commit 3143362
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 22 deletions.
23 changes: 2 additions & 21 deletions DepotDownloader/ContentDownloader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -211,20 +211,6 @@ static uint GetSteam3AppBuildNumber(uint appId, string branch)
return uint.Parse(buildid.Value);
}

static uint GetSteam3DepotProxyAppId(uint depotId, uint appId)
{
var depots = GetSteam3AppSection(appId, EAppInfoSection.Depots);
var depotChild = depots[depotId.ToString()];

if (depotChild == KeyValue.Invalid)
return INVALID_APP_ID;

if (depotChild["depotfromapp"] == KeyValue.Invalid)
return INVALID_APP_ID;

return depotChild["depotfromapp"].AsUnsignedInteger();
}

static ulong GetSteam3DepotManifest(uint depotId, uint appId, string branch)
{
var depots = GetSteam3AppSection(appId, EAppInfoSection.Depots);
Expand Down Expand Up @@ -649,12 +635,7 @@ static DepotDownloadInfo GetDepotInfo(uint depotId, uint appId, ulong manifestId
}
}

// For depots that are proxied through depotfromapp, we still need to resolve the proxy app id
var containingAppId = appId;
var proxyAppId = GetSteam3DepotProxyAppId(depotId, appId);
if (proxyAppId != INVALID_APP_ID) containingAppId = proxyAppId;

steam3.RequestDepotKey(depotId, containingAppId);
steam3.RequestDepotKey(depotId, appId);
if (!steam3.DepotKeys.ContainsKey(depotId))
{
Console.WriteLine("No valid depot key for {0}, unable to download.", depotId);
Expand All @@ -672,7 +653,7 @@ static DepotDownloadInfo GetDepotInfo(uint depotId, uint appId, ulong manifestId

var depotKey = steam3.DepotKeys[depotId];

return new DepotDownloadInfo(depotId, containingAppId, manifestId, branch, installDir, contentName, depotKey);
return new DepotDownloadInfo(depotId, appId, manifestId, branch, installDir, contentName, depotKey);
}

private class ChunkMatch
Expand Down
2 changes: 1 addition & 1 deletion DepotDownloader/DepotDownloader.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<TargetFramework>net6.0</TargetFramework>
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
<RollForward>LatestMajor</RollForward>
<Version>2.4.6</Version>
<Version>2.4.7</Version>
<Description>Steam Downloading Utility</Description>
<Authors>SteamRE Team</Authors>
<Copyright>Copyright © SteamRE Team 2021</Copyright>
Expand Down

1 comment on commit 3143362

@NicknineTheEagle
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, so that's why it was failing to download depots for app 90 under anon account.

Please sign in to comment.