Mercurial > mm7
diff GUI/UI/UITransition.cpp @ 2544:c674d547cc7c
GUIWindow switch logic refactored into behaviour classes
author | a.parshin |
---|---|
date | Mon, 11 May 2015 09:51:04 +0200 |
parents | a902abdfc7f2 |
children | e06a3fe9ad6e |
line wrap: on
line diff
--- a/GUI/UI/UITransition.cpp Sun May 10 03:21:14 2015 +0200 +++ b/GUI/UI/UITransition.cpp Mon May 11 09:51:04 2015 +0200 @@ -62,7 +62,7 @@ if ( pMapStats->GetMapInfo(pCurrentMapName) ) { sprintfex(sHouseName.data(), pGlobalTXT_LocalizationStrings[410], pMapStats->pInfos[pMapStats->GetMapInfo(pCurrentMapName)].pName); // "Leave %s" - pDialogueWindow = GUIWindow::Create(0, 0, window->GetWidth(), window->GetHeight(), WINDOW_Transition, 0, sHouseName.data()); + pDialogueWindow = new GUIWindow_Transition(0, 0, window->GetWidth(), window->GetHeight(), 0, sHouseName.data()); //if ( pAnimatedRooms[p2DEvents[anim_id].uAnimationID].uRoomSoundId ) //PlayHouseSound(anim_id, HouseSound_Greeting); if ( uCurrentlyLoadedLevelType == LEVEL_Indoor && uActiveCharacter && pParty->uFlags & 0x30 ) @@ -72,7 +72,7 @@ return; } strcpy(sHouseName.data(), pGlobalTXT_LocalizationStrings[79]); - pDialogueWindow = GUIWindow::Create(0, 0, window->GetWidth(), window->GetHeight(), WINDOW_Transition, 0, sHouseName.data()); + pDialogueWindow = new GUIWindow_Transition(0, 0, window->GetWidth(), window->GetHeight(), 0, sHouseName.data()); //if ( pAnimatedRooms[p2DEvents[anim_id].uAnimationID].uRoomSoundId ) //PlayHouseSound(anim_id, HouseSound_Greeting); if ( uCurrentlyLoadedLevelType == LEVEL_Indoor && uActiveCharacter && pParty->uFlags & 0x30 ) @@ -87,7 +87,7 @@ if ( pMapStats->GetMapInfo(v15) ) { sprintfex(sHouseName.data(), pGlobalTXT_LocalizationStrings[411], pMapStats->pInfos[pMapStats->GetMapInfo(v15)].pName);//Войти в ^Pv[%s] - pDialogueWindow = GUIWindow::Create(0, 0, window->GetWidth(), window->GetHeight(), WINDOW_Transition, 0, sHouseName.data()); + pDialogueWindow = new GUIWindow_Transition(0, 0, window->GetWidth(), window->GetHeight(), 0, sHouseName.data()); if ( uCurrentlyLoadedLevelType == LEVEL_Indoor && uActiveCharacter && pParty->uFlags & 0x30 ) pPlayers[uActiveCharacter]->PlaySound(SPEECH_47, 0); if ( IndoorLocation::GetLocationIndex(pLocationName) ) @@ -95,7 +95,7 @@ return; } strcpy(sHouseName.data(), pGlobalTXT_LocalizationStrings[73]);//Войти - pDialogueWindow = GUIWindow::Create(0, 0, window->GetWidth(), window->GetHeight(), WINDOW_Transition, 0, sHouseName.data()); + pDialogueWindow = new GUIWindow_Transition(0, 0, window->GetWidth(), window->GetHeight(), 0, sHouseName.data()); //if ( pAnimatedRooms[p2DEvents[anim_id].uAnimationID].uRoomSoundId ) //PlayHouseSound(anim_id, HouseSound_Greeting); if ( uCurrentlyLoadedLevelType == LEVEL_Indoor && uActiveCharacter && pParty->uFlags & 0x30 ) @@ -125,7 +125,7 @@ sprintfex(sHouseName.data(), pGlobalTXT_LocalizationStrings[410], pMapStats->pInfos[pMapStats->GetMapInfo(pCurrentMapName)].pName);// "Leave %s" else strcpy(sHouseName.data(), pGlobalTXT_LocalizationStrings[79]);// "Exit" - pDialogueWindow = GUIWindow::Create(0, 0, window->GetWidth(), window->GetHeight(), WINDOW_ChangeLocation, 0, sHouseName.data()); + pDialogueWindow = new GUIWindow_Travel(0, 0, window->GetWidth(), window->GetHeight(), 0, sHouseName.data()); } //----- (00444DCA) --------------------------------------------------------