From aadb5115040cfe0199e79a3e32dada6aa4b99fda Mon Sep 17 00:00:00 2001 From: dtentiion Date: Thu, 5 Mar 2026 20:57:37 +0000 Subject: Fix save list, delete save, exit without saving, and blank username on Windows64 (#539) * Fix world save rename not applying new name KeyboardCompleteWorldNameCallback had no _WINDOWS64 branch, so the typed name was validated then silently discarded on every rename attempt. Write the new name to a worldname.txt sidecar file next to the save (Windows64\GameHDD\{folder}\worldname.txt) and update the in-memory display name immediately. ReadLevelNameFromSaveFile now checks for this sidecar first so renamed saves persist correctly across restarts. * Fixed gamertag being blank upon renaming and re-joining a save * Save deletion fix, exiting without saving fix * Add native in-game keyboard UI for world naming and renaming --- Minecraft.Client/Common/UI/UIScene_LoadMenu.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'Minecraft.Client/Common/UI/UIScene_LoadMenu.cpp') diff --git a/Minecraft.Client/Common/UI/UIScene_LoadMenu.cpp b/Minecraft.Client/Common/UI/UIScene_LoadMenu.cpp index 92f2a403..ed3c8137 100644 --- a/Minecraft.Client/Common/UI/UIScene_LoadMenu.cpp +++ b/Minecraft.Client/Common/UI/UIScene_LoadMenu.cpp @@ -2,6 +2,7 @@ #include "UI.h" #include "UIScene_LoadMenu.h" #include "..\..\Minecraft.h" +#include "..\..\User.h" #include "..\..\TexturePackRepository.h" #include "..\..\Options.h" #include "..\..\MinecraftServer.h" @@ -273,7 +274,7 @@ UIScene_LoadMenu::UIScene_LoadMenu(int iPad, void *initData, UILayer *parentLaye m_bIgnoreInput = false; Minecraft *pMinecraft = Minecraft::GetInstance(); - int texturePacksCount = pMinecraft->skins->getTexturePackCount(); + unsigned int texturePacksCount = (unsigned int)pMinecraft->skins->getTexturePackCount(); for(unsigned int i = 0; i < texturePacksCount; ++i) { TexturePack *tp = pMinecraft->skins->getTexturePackByIndex(i); @@ -1629,6 +1630,12 @@ void UIScene_LoadMenu::StartGameFromSave(UIScene_LoadMenu* pClass, DWORD dwLocal param->settings = app.GetGameHostOption( eGameHostOption_All ); +#ifdef _WINDOWS64 + { + extern wchar_t g_Win64UsernameW[17]; + Minecraft::GetInstance()->user->name = g_Win64UsernameW; + } +#endif #ifndef _XBOX g_NetworkManager.FakeLocalPlayerJoined(); #endif -- cgit v1.2.3