update lcemp networking

This commit is contained in:
2026-08-14 07:02:50 +03:00
parent 125819419f
commit 6853eab85f
51 changed files with 629 additions and 183 deletions
@@ -959,11 +959,19 @@ void UIScene_CreateWorldMenu::checkStateAndStartGame()
else
{
//ProfileManager.RequestSignInUI(false, false, false, true, false,&CScene_MultiGameCreate::StartGame_SignInReturned, this,ProfileManager.GetPrimaryPad());
#if defined(_WINDOWS64) || defined(DISABLE_PSN) || defined(_DISABLE_XBLIVE)
SignInInfo info;
info.Func = &UIScene_CreateWorldMenu::StartGame_SignInReturned;
info.lpParam = this;
info.requireOnline = m_MoreOptionsParams.bOnlineGame;
UIScene_CreateWorldMenu::StartGame_SignInReturned(this, true, ProfileManager.GetPrimaryPad());
#else
SignInInfo info;
info.Func = &UIScene_CreateWorldMenu::StartGame_SignInReturned;
info.lpParam = this;
info.requireOnline = m_MoreOptionsParams.bOnlineGame;
ui.NavigateToScene(ProfileManager.GetPrimaryPad(),eUIScene_QuadrantSignin,&info);
#endif
}
}
else
@@ -1342,12 +1350,16 @@ int UIScene_CreateWorldMenu::ConfirmCreateReturned(void *pParam,int iPad,C4JStor
if(isClientSide && app.IsLocalMultiplayerAvailable())
{
#if defined(_WINDOWS64) || defined(DISABLE_PSN) || defined(_DISABLE_XBLIVE)
UIScene_CreateWorldMenu::StartGame_SignInReturned(pClass, true, ProfileManager.GetPrimaryPad());
#else
//ProfileManager.RequestSignInUI(false, false, false, true, false,&UIScene_CreateWorldMenu::StartGame_SignInReturned, pClass,ProfileManager.GetPrimaryPad());
SignInInfo info;
info.Func = &UIScene_CreateWorldMenu::StartGame_SignInReturned;
info.lpParam = pClass;
info.requireOnline = pClass->m_MoreOptionsParams.bOnlineGame;
ui.NavigateToScene(ProfileManager.GetPrimaryPad(),eUIScene_QuadrantSignin,&info);
#endif
}
else
{
@@ -7,7 +7,7 @@
#include "..\..\MinecraftServer.h"
#include "..\..\..\Minecraft.World\net.minecraft.world.level.h"
#include "..\..\..\Minecraft.World\net.minecraft.world.h"
#include "..\..\Common\Network\NetworkSocketLayer.h"
#include "..\..\Common\Network\NetworkSocketLayer.h"
#define UPDATE_PLAYERS_TIMER_ID 0
#define UPDATE_PLAYERS_TIMER_TIME 30000
@@ -368,7 +368,7 @@ void UIScene_JoinMenu::checkPrivilegeCallback(LPVOID lpParam, bool hasPrivilege,
void UIScene_JoinMenu::StartSharedLaunchFlow()
{
const bool bManualJoin = (g_MultiplayerJoin == true);
const bool bManualJoin = (g_MultiplayerJoin == true);
if (bManualJoin)
{
JoinGame(this);
@@ -431,7 +431,7 @@ void UIScene_JoinMenu::JoinGame(UIScene_JoinMenu* pClass)
{
return;
}
const bool bManualJoin = (g_MultiplayerJoin == true);
const bool bManualJoin = (g_MultiplayerJoin == true);
DWORD dwSignedInUsers = 0;
bool noPrivileges = false;
@@ -1446,7 +1446,12 @@ int UIScene_LoadMenu::LoadDataComplete(void *pParam)
#endif
else
{
#if defined(_WINDOWS64) || defined(DISABLE_PSN) || defined(_DISABLE_XBLIVE)
DWORD dwLocalUsersMask = CGameNetworkManager::GetLocalPlayerMask(ProfileManager.GetPrimaryPad());
StartGameFromSave(pClass, dwLocalUsersMask);
#else
pClass->m_bRequestQuadrantSignin = true;
#endif
}
}
}
@@ -8,7 +8,7 @@
#include "UIScene_MainMenu.h"
#ifdef __ORBIS__
#include <error_dialog.h>
#include "..\..\Common\Network\NetworkSocketLayer.h"
#include "..\..\Common\Network\NetworkSocketLayer.h"
#endif
Random *UIScene_MainMenu::random = new Random();
@@ -319,7 +319,7 @@ void UIScene_MainMenu::handlePress(F64 controlId, F64 childId)
//CD - Added for audio
ui.PlayUISFX(eSFX_Press);
if(g_MultiplayerJoin)
if(g_MultiplayerJoin)
{
// request only completes after the platform network timeout.
// this needs to be done before hand or else the PS4 crashes ill need to look more into this
@@ -386,6 +386,10 @@ void UIScene_MainMenu::handlePress(F64 controlId, F64 childId)
ui.NavigateToScene(primaryPad,eUIScene_TrialExitUpsell);
}
break;
#elif defined _WINDOWS64
case eControl_Exit:
app.ExitGame();
break;
#endif
#ifdef _DURANGO
@@ -1108,7 +1112,7 @@ void UIScene_MainMenu::RefreshChatAndContentRestrictionsReturned_PlayGame(void *
int primaryPad = ProfileManager.GetPrimaryPad();
UIScene_MainMenu* pClass = (UIScene_MainMenu*)pParam;
const bool bManualJoin = (g_MultiplayerJoin == true);
const bool bManualJoin = (g_MultiplayerJoin == true);
if (bManualJoin)
{
CreateLoad_SignInReturned(pClass, true, primaryPad);