Mercurial > mm7
changeset 2453:2a8010d99cf8
_4BF5B2() renamed to BackToHouseMenu()
author | Ritor1 |
---|---|
date | Fri, 25 Jul 2014 15:06:52 +0600 |
parents | 5991abe37c1d |
children | 16f0278279a5 |
files | Arcomage.cpp Game.cpp MediaPlayer.cpp MediaPlayer.h NPC.cpp OSWindow.cpp UI/UIHouses.cpp UI/UIHouses.h _deleted.cpp |
diffstat | 9 files changed, 35 insertions(+), 34 deletions(-) [+] |
line wrap: on
line diff
--- a/Arcomage.cpp Fri Jul 25 14:38:08 2014 +0600 +++ b/Arcomage.cpp Fri Jul 25 15:06:52 2014 +0600 @@ -22,6 +22,7 @@ #include "texts.h" #include <windef.h> #include "mm7_data.h" +#include "UI/UIHouses.h" @@ -1114,7 +1115,7 @@ pArcomageGame->bGameInProgress = false; viewparams->bRedrawGameUI = true; if ( pMovie_Track ) - pMediaPlayer->_4BF5B2(); + BackToHouseMenu(); for( int i = 0; i < 12; ++i ) pSoundList->UnloadSound(am_sounds[i], 1); }
--- a/Game.cpp Fri Jul 25 14:38:08 2014 +0600 +++ b/Game.cpp Fri Jul 25 15:06:52 2014 +0600 @@ -1240,7 +1240,7 @@ uGameState = GAME_FINISHED; continue; case UIMSG_PlayArcomage: - pMediaPlayer->_4BF5B2(); + BackToHouseMenu(); pArcomageGame->bGameInProgress = 1; ArcomageGame::PrepareArcomage(); continue;
--- a/MediaPlayer.cpp Fri Jul 25 14:38:08 2014 +0600 +++ b/MediaPlayer.cpp Fri Jul 25 15:06:52 2014 +0600 @@ -1289,29 +1289,6 @@ } } -//----- (004BF5B2) -------------------------------------------------------- -void MPlayer::_4BF5B2() -{ - pMouse->_469E24(); - if ( window_SpeakInHouse && window_SpeakInHouse->ptr_1C == (void *)165 && !pMovie_Track)//!this->pSmackerMovie ) - { - bGameoverLoop = true; - HouseDialogPressCloseBtn(); - window_SpeakInHouse->Release(); - pParty->uFlags &= 0xFFFFFFFD; - if ( EnterHouse(HOUSE_BODY_GUILD_ERATHIA) ) - { - pAudioPlayer->PlaySound(SOUND_Invalid, 0, 0, -1, 0, 0, 0, 0); - window_SpeakInHouse = GUIWindow::Create(0, 0, window->GetWidth(), window->GetHeight(), WINDOW_HouseInterior, 165, 0); - window_SpeakInHouse->CreateButton(0x3Du, 0x1A8u, 0x1Fu, 0, 2, 94, UIMSG_SelectCharacter, 1, 0x31, "", 0); - window_SpeakInHouse->CreateButton(0xB1u, 0x1A8u, 0x1Fu, 0, 2, 94, UIMSG_SelectCharacter, 2, 0x32, "", 0); - window_SpeakInHouse->CreateButton(0x124u, 0x1A8u, 0x1Fu, 0, 2, 94, UIMSG_SelectCharacter, 3, 0x33, "", 0); - window_SpeakInHouse->CreateButton(0x197u, 0x1A8u, 0x1Fu, 0, 2, 94, UIMSG_SelectCharacter, 4, 0x34, "", 0); - } - bGameoverLoop = 0; - } -} - //----- (004BF73A) -------------------------------------------------------- void MPlayer::SelectMovieType() {
--- a/MediaPlayer.h Fri Jul 25 14:38:08 2014 +0600 +++ b/MediaPlayer.h Fri Jul 25 15:06:52 2014 +0600 @@ -98,7 +98,6 @@ void OpenGlobalMovie(const char *pFilename, unsigned int bLoop); void OpenHouseMovie(const char *pMovieName, unsigned int a3_1); - void _4BF5B2(); void LoadMovie(const char *); void SelectMovieType();
--- a/NPC.cpp Fri Jul 25 14:38:08 2014 +0600 +++ b/NPC.cpp Fri Jul 25 15:06:52 2014 +0600 @@ -1575,7 +1575,7 @@ if ( uActiveCharacter ) pPlayers[uActiveCharacter]->PlaySound((PlayerSpeech)61, 0); _return: - pMediaPlayer->_4BF5B2();//HouseVideo + BackToHouseMenu(); } //----- (004B29F2) -------------------------------------------------------- const char * ContractSelectText( int pEventCode )
--- a/OSWindow.cpp Fri Jul 25 14:38:08 2014 +0600 +++ b/OSWindow.cpp Fri Jul 25 15:06:52 2014 +0600 @@ -324,7 +324,7 @@ { pRenderer->RestoreFrontBuffer(); pRenderer->RestoreBackBuffer(); - //pVideoPlayer->_4BF5B2(); + //BackToHouseMenu(); } } if ( pAudioPlayer->hAILRedbook && !bGameoverLoop && !pMovie_Track)//!pVideoPlayer->pSmackerMovie )
--- a/UI/UIHouses.cpp Fri Jul 25 14:38:08 2014 +0600 +++ b/UI/UIHouses.cpp Fri Jul 25 15:06:52 2014 +0600 @@ -3329,13 +3329,13 @@ { case -1: _4B4224_UpdateNPCTopics((int)((char *)pDialogueNPCCount - 1)); - pMediaPlayer->_4BF5B2(); + BackToHouseMenu(); break; case HOUSE_DIALOGUE_SHOP_DISPLAY_EQUIPMENT: case HOUSE_DIALOGUE_LEARN_SKILLS: case HOUSE_DIALOGUE_TAVERN_ARCOMAGE_MAIN: - pMediaPlayer->_4BF5B2(); + BackToHouseMenu(); UI_CreateEndConversationButton(); dialog_menu_id = HOUSE_DIALOGUE_MAIN; InitializaDialogueOptions(in_current_building_type); @@ -3352,7 +3352,7 @@ case HOUSE_DIALOGUE_TAVERN_ARCOMAGE_RULES: case HOUSE_DIALOGUE_TAVERN_ARCOMAGE_VICTORY_CONDITIONS: case HOUSE_DIALOGUE_TAVERN_ARCOMAGE_RESULT: - pMediaPlayer->_4BF5B2(); + BackToHouseMenu(); UI_CreateEndConversationButton(); dialog_menu_id = HOUSE_DIALOGUE_TAVERN_ARCOMAGE_MAIN; InitializaDialogueOptions_Tavern(in_current_building_type); @@ -3380,14 +3380,37 @@ } } - pMediaPlayer->_4BF5B2(); + BackToHouseMenu(); break; default: - pMediaPlayer->_4BF5B2(); + BackToHouseMenu(); dialog_menu_id = HOUSE_DIALOGUE_MAIN; InitializaDialogueOptions(in_current_building_type); break; } return 1; } + +//----- (004BF5B2) -------------------------------------------------------- +void BackToHouseMenu() +{ + pMouse->_469E24(); + if ( window_SpeakInHouse && window_SpeakInHouse->ptr_1C == (void *)165 && !pMovie_Track)//!this->pSmackerMovie ) + { + bGameoverLoop = true; + HouseDialogPressCloseBtn(); + window_SpeakInHouse->Release(); + pParty->uFlags &= 0xFFFFFFFD; + if ( EnterHouse(HOUSE_BODY_GUILD_ERATHIA) ) + { + pAudioPlayer->PlaySound(SOUND_Invalid, 0, 0, -1, 0, 0, 0, 0); + window_SpeakInHouse = GUIWindow::Create(0, 0, window->GetWidth(), window->GetHeight(), WINDOW_HouseInterior, 165, 0); + window_SpeakInHouse->CreateButton(0x3Du, 0x1A8u, 0x1Fu, 0, 2, 94, UIMSG_SelectCharacter, 1, 0x31, "", 0); + window_SpeakInHouse->CreateButton(0xB1u, 0x1A8u, 0x1Fu, 0, 2, 94, UIMSG_SelectCharacter, 2, 0x32, "", 0); + window_SpeakInHouse->CreateButton(0x124u, 0x1A8u, 0x1Fu, 0, 2, 94, UIMSG_SelectCharacter, 3, 0x33, "", 0); + window_SpeakInHouse->CreateButton(0x197u, 0x1A8u, 0x1Fu, 0, 2, 94, UIMSG_SelectCharacter, 4, 0x34, "", 0); + } + bGameoverLoop = 0; + } +}
--- a/UI/UIHouses.h Fri Jul 25 14:38:08 2014 +0600 +++ b/UI/UIHouses.h Fri Jul 25 15:06:52 2014 +0600 @@ -137,6 +137,7 @@ void __fastcall OnSelectShopDialogueOption(signed int uMessageParam); void PrepareHouse(enum HOUSE_ID house); // idb bool EnterHouse(enum HOUSE_ID uHouseID); +void BackToHouseMenu(); void InitializaDialogueOptions_Tavern(BuildingType type); // idb
--- a/_deleted.cpp Fri Jul 25 14:38:08 2014 +0600 +++ b/_deleted.cpp Fri Jul 25 15:06:52 2014 +0600 @@ -12550,7 +12550,7 @@ { pRenderer->RestoreFrontBuffer(); pRenderer->RestoreBackBuffer(); - pVideoPlayer->_4BF5B2(); + BackToHouseMenu(); } } if ( pAudioPlayer->hAILRedbook && !bGameoverLoop && !pVideoPlayer->pSmackerMovie )