1
Fork 0
mirror of https://github.com/redstrate/Astra.git synced 2025-05-11 04:37:44 +00:00

Update libphysis to get a more accurate patch download size

This commit is contained in:
Joshua Goins 2025-05-06 15:17:09 -04:00
parent adc2791822
commit c6cb9afa2e
3 changed files with 4 additions and 4 deletions

2
external/libphysis vendored

@ -1 +1 @@
Subproject commit 41bd594d2ab2d0f9a9325ab5eedec9810e225de3
Subproject commit 0acd736b2d9eb78c37a5283169ee53775624cd19

View file

@ -56,7 +56,7 @@ QCoro::Task<bool> Patcher::patch(const physis_PatchList &patchList)
}
// First, let's check if we have enough space to even download the patches
const qint64 neededSpace = patchList.patch_length - m_patchesDirStorageInfo.bytesAvailable();
const qint64 neededSpace = patchList.total_size_downloaded - m_patchesDirStorageInfo.bytesAvailable();
if (neededSpace > 0) {
KFormat format;
QString neededSpaceStr = format.formatByteSize(neededSpace);

View file

@ -198,7 +198,7 @@ QCoro::Task<bool> SquareEnixLogin::checkBootUpdates()
co_return false;
}
const qint64 neededSpace = parsedPatchList.patch_length;
const qint64 neededSpace = parsedPatchList.total_size_downloaded;
KFormat format;
QString neededSpaceStr = format.formatByteSize(neededSpace);
Q_EMIT m_launcher.requiresUpdate(
@ -411,7 +411,7 @@ QCoro::Task<bool> SquareEnixLogin::registerSession()
std::string bodyStd = body.toStdString();
const auto parsedPatchList = physis_parse_patchlist(PatchListType::Game, bodyStd.c_str());
const qint64 neededSpace = parsedPatchList.patch_length;
const qint64 neededSpace = parsedPatchList.total_size_downloaded;
KFormat format;
QString neededSpaceStr = format.formatByteSize(neededSpace);
Q_EMIT m_launcher.requiresUpdate(