From b9a2951901dac21b08589c9d8b4a7eae78757726 Mon Sep 17 00:00:00 2001 From: void_17 Date: Mon, 2 Mar 2026 17:39:35 +0700 Subject: Revert "Get rid of MSVC's __int64" This reverts commit d63f79325f85e014361eb8cf1e41eaebedb1ae71. --- Minecraft.Client/Common/UI/UIController.cpp | 60 ++++++++++++++--------------- 1 file changed, 30 insertions(+), 30 deletions(-) (limited to 'Minecraft.Client/Common/UI/UIController.cpp') diff --git a/Minecraft.Client/Common/UI/UIController.cpp b/Minecraft.Client/Common/UI/UIController.cpp index 34afbc71..eb33b6b3 100644 --- a/Minecraft.Client/Common/UI/UIController.cpp +++ b/Minecraft.Client/Common/UI/UIController.cpp @@ -124,7 +124,7 @@ extern "C" void *__real_malloc(size_t t); extern "C" void __real_free(void *t); #endif -int64_t UIController::iggyAllocCount = 0; +__int64 UIController::iggyAllocCount = 0; static unordered_map allocations; static void * RADLINK AllocateFunction ( void * alloc_callback_user_data , size_t size_requested , size_t * size_returned ) { @@ -272,7 +272,7 @@ void UIController::postInit() IggySetTextureSubstitutionCallbacks ( &UIController::TextureSubstitutionCreateCallback , &UIController::TextureSubstitutionDestroyCallback, this ); SetupFont(); - // + // loadSkins(); for(unsigned int i = 0; i < eUIGroup_COUNT; ++i) @@ -402,7 +402,7 @@ void UIController::tick() EnderDragonRenderer::bossInstance = nullptr; // Clear out the cached movie file data - int64_t currentTime = System::currentTimeMillis(); + __int64 currentTime = System::currentTimeMillis(); for(AUTO_VAR(it, m_cachedMovieData.begin()); it != m_cachedMovieData.end();) { if(it->second.m_expiry < currentTime) @@ -522,7 +522,7 @@ IggyLibrary UIController::loadSkin(const wstring &skinPath, const wstring &skinN IggyMemoryUseInfo memoryInfo; rrbool res; int iteration = 0; - int64_t totalStatic = 0; + __int64 totalStatic = 0; while(res = IggyDebugGetMemoryUseInfo ( NULL , lib , "" , @@ -632,7 +632,7 @@ void UIController::CleanUpSkinReload() { if(!Minecraft::GetInstance()->skins->getSelected()->hasAudio()) { -#ifdef _DURANGO +#ifdef _DURANGO DWORD result = StorageManager.UnmountInstalledDLC(L"TPACK"); #else DWORD result = StorageManager.UnmountInstalledDLC("TPACK"); @@ -653,7 +653,7 @@ void UIController::CleanUpSkinReload() byteArray UIController::getMovieData(const wstring &filename) { // Cache everything we load in the current tick - int64_t targetTime = System::currentTimeMillis() + (1000LL * 60); + __int64 targetTime = System::currentTimeMillis() + (1000LL * 60); AUTO_VAR(it,m_cachedMovieData.find(filename)); if(it == m_cachedMovieData.end() ) { @@ -699,7 +699,7 @@ void UIController::handleInput() { #ifdef _DURANGO // 4J-JEV: Added exception for primary play who migh've uttered speech commands. - if(iPad != ProfileManager.GetPrimaryPad() + if(iPad != ProfileManager.GetPrimaryPad() && (!InputManager.IsPadConnected(iPad) || !InputManager.IsPadLocked(iPad)) ) continue; #endif for(unsigned int key = 0; key <= ACTION_MAX_MENU; ++key) @@ -775,7 +775,7 @@ void UIController::handleKeyPress(unsigned int iPad, unsigned int key) { // no active touch? clear active and highlighted touch UI elements m_ActiveUIElement = NULL; - m_HighlightedUIElement = NULL; + m_HighlightedUIElement = NULL; // fullscreen first UIScene *pScene=m_groups[(int)eUIGroup_Fullscreen]->getCurrentScene(); @@ -825,7 +825,7 @@ void UIController::handleKeyPress(unsigned int iPad, unsigned int key) } } } - } + } else if(m_bTouchscreenPressed && pTouchData->reportNum==1) { // fullscreen first @@ -1006,8 +1006,8 @@ void UIController::handleKeyPress(unsigned int iPad, unsigned int key) //!(app.GetGameSettingsDebugMask(ProfileManager.GetPrimaryPad())&(1L<closeAllScenes(); m_groups[(int)group]->getTooltips()->SetTooltips(-1); - + // This should cause the popup to dissappear TutorialPopupInfo popupInfo; if(m_groups[(int)group]->getTutorialPopup()) m_groups[(int)group]->getTutorialPopup()->SetTutorialDescription(&popupInfo); @@ -1865,7 +1865,7 @@ void UIController::SetMenuDisplayed(int iPad,bool bVal) #ifdef _DURANGO // 4J-JEV: When in-game, allow player to toggle the 'Pause' and 'IngameInfo' menus via Kinnect. - if (Minecraft::GetInstance()->running) + if (Minecraft::GetInstance()->running) InputManager.SetEnabledGtcButtons(_360_GTC_MENU | _360_GTC_PAUSE | _360_GTC_VIEW); #endif } @@ -2280,7 +2280,7 @@ void UIController::SetTrialTimerLimitSecs(unsigned int uiSeconds) void UIController::UpdateTrialTimer(unsigned int iPad) { - WCHAR wcTime[20]; + WCHAR wcTime[20]; DWORD dwTimeTicks=(DWORD)app.getTrialTimer(); @@ -2342,7 +2342,7 @@ void UIController::ShowAutosaveCountdownTimer(bool show) void UIController::UpdateAutosaveCountdownTimer(unsigned int uiSeconds) { #if !(defined(_XBOX_ONE) || defined(__ORBIS__)) - WCHAR wcAutosaveCountdown[100]; + WCHAR wcAutosaveCountdown[100]; swprintf( wcAutosaveCountdown, 100, app.GetString(IDS_AUTOSAVE_COUNTDOWN),uiSeconds); if(m_groups[(int)eUIGroup_Fullscreen]->getPressStartToPlay()) m_groups[(int)eUIGroup_Fullscreen]->getPressStartToPlay()->setTrialTimer(wcAutosaveCountdown); #endif @@ -2507,7 +2507,7 @@ C4JStorage::EMessageResult UIController::RequestUGCMessageBox(UINT title/* = -1 #ifdef __ORBIS__ // Show the vague UGC system message in addition to our message ProfileManager.DisplaySystemMessage( SCE_MSG_DIALOG_SYSMSG_TYPE_TRC_PSN_UGC_RESTRICTION, iPad ); - return C4JStorage::EMessage_ResultAccept; + return C4JStorage::EMessage_ResultAccept; #elif defined(__PSVITA__) ProfileManager.ShowSystemMessage( SCE_MSG_DIALOG_SYSMSG_TYPE_TRC_PSN_CHAT_RESTRICTION, iPad ); UINT uiIDA[1]; @@ -2544,7 +2544,7 @@ C4JStorage::EMessageResult UIController::RequestContentRestrictedMessageBox(UINT #ifdef __ORBIS__ // Show the vague UGC system message in addition to our message ProfileManager.DisplaySystemMessage( SCE_MSG_DIALOG_SYSMSG_TYPE_TRC_PSN_UGC_RESTRICTION, iPad ); - return C4JStorage::EMessage_ResultAccept; + return C4JStorage::EMessage_ResultAccept; #elif defined(__PSVITA__) ProfileManager.ShowSystemMessage( SCE_MSG_DIALOG_SYSMSG_TYPE_TRC_PSN_AGE_RESTRICTION, iPad ); return C4JStorage::EMessage_ResultAccept; @@ -2584,7 +2584,7 @@ void UIController::setFontCachingCalculationBuffer(int length) } } -// Returns the first scene of given type if it exists, NULL otherwise +// Returns the first scene of given type if it exists, NULL otherwise UIScene *UIController::FindScene(EUIScene sceneType) { UIScene *pScene = NULL; @@ -2723,7 +2723,7 @@ void UIController::TouchBoxesClear(UIScene *pUIScene) for (AUTO_VAR(it, m_TouchBoxes[eUIGroup][eUILayer][eUIscene].begin()); it != itEnd; it++) { UIELEMENT *element=(UIELEMENT *)*it; - delete element; + delete element; } m_TouchBoxes[eUIGroup][eUILayer][eUIscene].clear(); } @@ -2759,7 +2759,7 @@ bool UIController::TouchBoxHit(UIScene *pUIScene,S32 x, S32 y) return true; } } - } + } } //app.DebugPrintf("MISS at x = %i y = %i\n", (int)x, (int)y); -- cgit v1.2.3