Revert "Project modernization (#630)"

This code was not tested and breaks in Release builds, reverting to restore
functionality of the nightly. All in-game menus do not work and generating
a world crashes.

This reverts commit a9be52c41a.
This commit is contained in:
Loki Rautio
2026-03-07 21:12:22 -06:00
parent a9be52c41a
commit 087b7e7abf
1373 changed files with 19449 additions and 19903 deletions

View File

@@ -65,11 +65,11 @@ unsigned int CScene_HowToPlayMenu::m_uiHTPSceneA[]=
//----------------------------------------------------------------------------------
HRESULT CScene_HowToPlayMenu::OnInit( XUIMessageInit* pInitData, BOOL& bHandled )
{
m_iPad = *static_cast<int *>(pInitData->pvInitData);
m_iPad = *(int *)pInitData->pvInitData;
// if we're not in the game, we need to use basescene 0
bool bNotInGame=(Minecraft::GetInstance()->level==nullptr);
bool bNotInGame=(Minecraft::GetInstance()->level==NULL);
bool bSplitscreen= app.GetLocalPlayerCount()>1;
m_ButtonList=nullptr;
m_ButtonList=NULL;
//MapChildControls();
@@ -131,7 +131,7 @@ HRESULT CScene_HowToPlayMenu::OnGetSourceDataText(XUIMessageGetSourceText *pGetS
{
if( pGetSourceTextData->bItemData )
{
if( pGetSourceTextData->iItem < static_cast<int>(eHTPButton_Max) )
if( pGetSourceTextData->iItem < (int)eHTPButton_Max )
{
pGetSourceTextData->szText = app.GetString(m_uiHTPButtonNameA[pGetSourceTextData->iItem]);//m_Buttons[pGetSourceTextData->iItem].GetText();
pGetSourceTextData->bDisplay = TRUE;
@@ -173,7 +173,7 @@ HRESULT CScene_HowToPlayMenu::OnNotifyPressEx(HXUIOBJ hObjPressed, XUINotifyPres
// 4J-PB - now using a list for all resolutions
//if((!RenderManager.IsHiDef() && !RenderManager.IsWidescreen()) || app.GetLocalPlayerCount()>1)
{
if(hObjPressed==m_ButtonList && m_ButtonList.TreeHasFocus() && (m_ButtonList.GetItemCount() > 0) && (m_ButtonList.GetCurSel() < static_cast<int>(eHTPButton_Max)) )
if(hObjPressed==m_ButtonList && m_ButtonList.TreeHasFocus() && (m_ButtonList.GetItemCount() > 0) && (m_ButtonList.GetCurSel() < (int)eHTPButton_Max) )
{
uiButtonCounter=m_ButtonList.GetCurSel();
}
@@ -186,7 +186,7 @@ HRESULT CScene_HowToPlayMenu::OnNotifyPressEx(HXUIOBJ hObjPressed, XUINotifyPres
// Determine which button was pressed,
// and call the appropriate function.
uiInitData = ( ( 1 << 31 ) | ( m_uiHTPSceneA[uiButtonCounter] << 16 ) | static_cast<short>(m_iPad) );
uiInitData = ( ( 1 << 31 ) | ( m_uiHTPSceneA[uiButtonCounter] << 16 ) | ( short )( m_iPad ) );
if(app.GetLocalPlayerCount()>1)
{
app.NavigateToScene(pNotifyPressData->UserIndex,eUIScene_HowToPlay, ( void* )( uiInitData ) );