diff options
| author | daoge <3523206925@qq.com> | 2026-03-03 03:04:10 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-03-03 03:04:10 +0800 |
| commit | b3feddfef372618c8a9d7a0abcaf18cfad866c18 (patch) | |
| tree | 267761c3bb39241ba5c347bfbe2254d06686e287 /Minecraft.Client/PSVita/Network/SonyRemoteStorage_Vita.cpp | |
| parent | 84c31a2331f7a0ec85b9d438992e244f60e5020f (diff) | |
feat: TU19 (Dec 2014) Features & Content (#155)
* try to resolve merge conflict
* feat: TU19 (Dec 2014) Features & Content (#32)
* December 2014 files
* Working release build
* Fix compilation issues
* Add sound to Windows64Media
* Add DLC content and force Tutorial DLC
* Revert "Add DLC content and force Tutorial DLC"
This reverts commit 97a43994725008e35fceb984d5549df9c8cea470.
* Disable broken light packing
* Disable breakpoint during DLC texture map load
Allows DLC loading but the DLC textures are still broken
* Fix post build not working
* ...
* fix vs2022 build
* fix cmake build
---------
Co-authored-by: Loki <lokirautio@gmail.com>
Diffstat (limited to 'Minecraft.Client/PSVita/Network/SonyRemoteStorage_Vita.cpp')
| -rw-r--r-- | Minecraft.Client/PSVita/Network/SonyRemoteStorage_Vita.cpp | 44 |
1 files changed, 10 insertions, 34 deletions
diff --git a/Minecraft.Client/PSVita/Network/SonyRemoteStorage_Vita.cpp b/Minecraft.Client/PSVita/Network/SonyRemoteStorage_Vita.cpp index 3d9483d2..c103b32f 100644 --- a/Minecraft.Client/PSVita/Network/SonyRemoteStorage_Vita.cpp +++ b/Minecraft.Client/PSVita/Network/SonyRemoteStorage_Vita.cpp @@ -116,7 +116,7 @@ void SonyRemoteStorage_Vita::internalCallback(const SceRemoteStorageEvent event, app.DebugPrintf("Set data progress: %i%%\n", retCode); m_status = e_setDataInProgress; m_dataProgress = retCode; - + m_startTime = System::currentTimeMillis(); break; case USER_ACCOUNT_LINKED: @@ -146,8 +146,12 @@ bool SonyRemoteStorage_Vita::init(CallbackFunc cb, LPVOID lpParam) m_callbackFunc = cb; m_callbackParam = lpParam; + m_bTransferStarted = false; + m_bAborting = false; + m_lastErrorCode = SCE_OK; + if(m_bInitialised) { internalCallback(USER_ACCOUNT_LINKED, 0); @@ -293,6 +297,10 @@ bool SonyRemoteStorage_Vita::setDataInternal() // CompressSaveData(); // check if we need to re-save the file compressed first snprintf(m_saveFilename, sizeof(m_saveFilename), "%s:%s/GAMEDATA.bin", "savedata0", m_setDataSaveInfo->UTF8SaveFilename); + + SceFiosSize outSize = sceFiosFileGetSizeSync(NULL, m_saveFilename); + m_uploadSaveSize = (int)outSize; + strcpy(m_saveFileDesc, m_setDataSaveInfo->UTF8SaveTitle); m_status = e_setDataInProgress; @@ -302,39 +310,7 @@ bool SonyRemoteStorage_Vita::setDataInternal() strcpy(params.pathLocation, m_saveFilename); sprintf(params.fileName, getRemoteSaveFilename()); - DescriptionData descData; - ZeroMemory(&descData, sizeof(DescriptionData)); - descData.m_platform[0] = SAVE_FILE_PLATFORM_LOCAL & 0xff; - descData.m_platform[1] = (SAVE_FILE_PLATFORM_LOCAL >> 8) & 0xff; - descData.m_platform[2] = (SAVE_FILE_PLATFORM_LOCAL >> 16) & 0xff; - descData.m_platform[3] = (SAVE_FILE_PLATFORM_LOCAL >> 24)& 0xff; - - if(m_thumbnailData) - { - unsigned int uiHostOptions; - bool bHostOptionsRead; - DWORD uiTexturePack; - char seed[22]; - app.GetImageTextData(m_thumbnailData, m_thumbnailDataSize,(unsigned char *)seed, uiHostOptions, bHostOptionsRead, uiTexturePack); - - __int64 iSeed = strtoll(seed,NULL,10); - char seedHex[17]; - sprintf(seedHex,"%016llx",iSeed); - memcpy(descData.m_seed,seedHex,16); // Don't copy null - - // Save the host options that this world was last played with - char hostOptions[9]; - sprintf(hostOptions,"%08x",uiHostOptions); - memcpy(descData.m_hostOptions,hostOptions,8); // Don't copy null - - // Save the texture pack id - char texturePack[9]; - sprintf(texturePack,"%08x",uiTexturePack); - memcpy(descData.m_texturePack,texturePack,8); // Don't copy null - } - - memcpy(descData.m_saveNameUTF8, m_saveFileDesc, strlen(m_saveFileDesc)+1); // plus null - memcpy(params.fileDescription, &descData, sizeof(descData)); + GetDescriptionData(params.fileDescription); if(m_bAborting) |
