From 3a5f1b617931d00145504d97ef4fbef4f3138b5b Mon Sep 17 00:00:00 2001 From: Matthew Toro <48634881+mattsumi@users.noreply.github.com> Date: Sun, 8 Mar 2026 04:10:15 -0400 Subject: Add "Add Server" functionally to "Join Game" Menu + relocate servers.txt to servers.db. (#911) * Add "Add Server" functionally to "Join Game" Menu + relocate servers.txt to servers.db * enchancement: add edit and delete server functionality, solves FriendSessionInfo corruption issues --- Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.h') diff --git a/Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.h b/Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.h index 3599aa37..9f5fe17f 100644 --- a/Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.h +++ b/Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.h @@ -175,6 +175,18 @@ public: private: void CheckAndJoinGame(int gameIndex); + +#ifdef _WINDOWS64 + static const int ADD_SERVER_BUTTON_INDEX = 0; + enum eAddServerPhase { eAddServer_Idle, eAddServer_IP, eAddServer_Port, eAddServer_Name }; + eAddServerPhase m_addServerPhase; + wstring m_addServerIP; + wstring m_addServerPort; + void BeginAddServer(); + void AppendServerToFile(const wstring& ip, const wstring& port, const wstring& name); + static int AddServerKeyboardCallback(LPVOID lpParam, bool bRes); +#endif + #if defined(__PS3__) || defined(__PSVITA__) || defined(__ORBIS__) static int MustSignInReturnedPSN(void *pParam,int iPad,C4JStorage::EMessageResult result); static int PSN_SignInReturned(void *pParam,bool bContinue, int iPad); -- cgit v1.2.3