diff options
| author | void_17 <heroerror3@gmail.com> | 2026-03-02 17:37:16 +0700 |
|---|---|---|
| committer | void_17 <heroerror3@gmail.com> | 2026-03-02 17:37:16 +0700 |
| commit | 119bff351450ea16ffda550b6e0f67379b29f708 (patch) | |
| tree | d9f28714afd516bc2450f33b0a77c5e05ff4de90 /Minecraft.Client/Common/XUI/XUI_InGameInfo.cpp | |
| parent | 8a2a62ea1d47364f802cf9aae97668bc4a7007b5 (diff) | |
Revert "shared_ptr -> std::shared_ptr"
This reverts commit 7074f35e4ba831e358117842b99ee35b87f85ae5.
Diffstat (limited to 'Minecraft.Client/Common/XUI/XUI_InGameInfo.cpp')
| -rw-r--r-- | Minecraft.Client/Common/XUI/XUI_InGameInfo.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/Minecraft.Client/Common/XUI/XUI_InGameInfo.cpp b/Minecraft.Client/Common/XUI/XUI_InGameInfo.cpp index c9b9f76f..4839013c 100644 --- a/Minecraft.Client/Common/XUI/XUI_InGameInfo.cpp +++ b/Minecraft.Client/Common/XUI/XUI_InGameInfo.cpp @@ -58,7 +58,7 @@ HRESULT CScene_InGameInfo::OnInit( XUIMessageInit* pInitData, BOOL& bHandled ) if(thisPlayer != NULL) m_isHostPlayer = thisPlayer->IsHost() == TRUE; Minecraft *pMinecraft = Minecraft::GetInstance(); - std::shared_ptr<MultiplayerLocalPlayer> localPlayer = pMinecraft->localplayers[m_iPad]; + shared_ptr<MultiplayerLocalPlayer> localPlayer = pMinecraft->localplayers[m_iPad]; if(!m_isHostPlayer && !localPlayer->isModerator() ) { m_gameOptionsButton.SetEnable(FALSE); @@ -77,7 +77,7 @@ HRESULT CScene_InGameInfo::OnInit( XUIMessageInit* pInitData, BOOL& bHandled ) int keyA = -1; ui.SetTooltips( m_iPad, keyA,IDS_TOOLTIPS_BACK,keyX,-1); - + CXuiSceneBase::ShowDarkOverlay( m_iPad, TRUE ); SetTimer( TOOLTIP_TIMERID , INGAME_INFO_TOOLTIP_TIMER ); @@ -179,11 +179,11 @@ HRESULT CScene_InGameInfo::OnNotifyPressEx(HXUIOBJ hObjPressed, XUINotifyPress* ui.AnimateKeyPress(pNotifyPressData->UserIndex, VK_PAD_A); if( hObjPressed == playersList ) - { + { INetworkPlayer *selectedPlayer = g_NetworkManager.GetPlayerBySmallId( m_players[ playersList.GetCurSel() ] ); - + Minecraft *pMinecraft = Minecraft::GetInstance(); - std::shared_ptr<MultiplayerLocalPlayer> localPlayer = pMinecraft->localplayers[m_iPad]; + shared_ptr<MultiplayerLocalPlayer> localPlayer = pMinecraft->localplayers[m_iPad]; bool isOp = m_isHostPlayer || localPlayer->isModerator(); bool cheats = app.GetGameHostOption(eGameHostOption_CheatsEnabled) != 0; @@ -220,7 +220,7 @@ HRESULT CScene_InGameInfo::OnNotifyPressEx(HXUIOBJ hObjPressed, XUINotifyPress* } } else if( hObjPressed == m_gameOptionsButton ) - { + { app.NavigateToScene(pNotifyPressData->UserIndex,eUIScene_InGameHostOptionsMenu); } return S_OK; @@ -330,7 +330,7 @@ HRESULT CScene_InGameInfo::OnGetSourceDataText(XUIMessageGetSourceText *pGetSour } HRESULT hr; - HXUIOBJ hButton, hVisual, hPlayerIcon, hVoiceIcon; + HXUIOBJ hButton, hVisual, hPlayerIcon, hVoiceIcon; hButton = playersList.GetItemControl(pGetSourceTextData->iItem); hr=XuiControlGetVisual(hButton,&hVisual); @@ -415,7 +415,7 @@ HRESULT CScene_InGameInfo::OnGetSourceDataText(XUIMessageGetSourceText *pGetSour XuiElementFindNamedFrame(hVoiceIcon, L"NotSpeaking", &playFrame); } } - + if(playFrame < 0) { XuiElementFindNamedFrame(hVoiceIcon, L"Normal", &playFrame); @@ -465,8 +465,8 @@ void CScene_InGameInfo::updateTooltips() int keyA = -1; Minecraft *pMinecraft = Minecraft::GetInstance(); - std::shared_ptr<MultiplayerLocalPlayer> localPlayer = pMinecraft->localplayers[m_iPad]; - + shared_ptr<MultiplayerLocalPlayer> localPlayer = pMinecraft->localplayers[m_iPad]; + bool isOp = m_isHostPlayer || localPlayer->isModerator(); bool cheats = app.GetGameHostOption(eGameHostOption_CheatsEnabled) != 0; bool trust = app.GetGameHostOption(eGameHostOption_TrustPlayers) != 0; @@ -524,12 +524,12 @@ int CScene_InGameInfo::KickPlayerReturned(void *pParam,int iPad,C4JStorage::EMes delete pParam; if(result==C4JStorage::EMessage_ResultAccept) - { + { Minecraft *pMinecraft = Minecraft::GetInstance(); - std::shared_ptr<MultiplayerLocalPlayer> localPlayer = pMinecraft->localplayers[iPad]; + shared_ptr<MultiplayerLocalPlayer> localPlayer = pMinecraft->localplayers[iPad]; if(localPlayer != NULL && localPlayer->connection) { - localPlayer->connection->send( std::shared_ptr<KickPlayerPacket>( new KickPlayerPacket(smallId) ) ); + localPlayer->connection->send( shared_ptr<KickPlayerPacket>( new KickPlayerPacket(smallId) ) ); } } |
