Mercurial > mm7
changeset 2279:a01d3cf9ff83
mm7 game sound
author | Ritor1 |
---|---|
date | Fri, 14 Mar 2014 22:26:52 +0600 |
parents | 0cd17b0d36c2 |
children | a5926b36a1b4 |
files | Texture.cpp VideoPlayer.cpp mm7_2.cpp |
diffstat | 3 files changed, 21 insertions(+), 15 deletions(-) [+] |
line wrap: on
line diff
--- a/Texture.cpp Fri Mar 14 17:59:06 2014 +0600 +++ b/Texture.cpp Fri Mar 14 22:26:52 2014 +0600 @@ -528,15 +528,7 @@ file = pIcons_LOD->FindContainer(pContainer, 0); if ( !file ) - { - //char pContainerName[64]; - - //sprintf(pContainerName, "data\\New_Icons/%s", pContainer); - //MMT_Texture.LoadPCXFile(pContainerName, 0); - if ( !file ) - Error("Unable to load %s", pContainer); - //fclose(file); - } + Error("Unable to load %s", pContainer); fread(&DstBuf, 1, 0x30u, file); Count = DstBuf.uTextureSize;
--- a/VideoPlayer.cpp Fri Mar 14 17:59:06 2014 +0600 +++ b/VideoPlayer.cpp Fri Mar 14 22:26:52 2014 +0600 @@ -277,8 +277,8 @@ void ShowIntroVideo_and_LoadingScreen() { RGBTexture tex; // [sp+Ch] [bp-30h]@1 - unsigned int uTrackStartMS; // [sp+34h] [bp-8h]@8 - unsigned int uTrackEndMS; // [sp+38h] [bp-4h]@8 + //unsigned int uTrackStartMS; // [sp+34h] [bp-8h]@8 + //unsigned int uTrackEndMS; // [sp+38h] [bp-4h]@8 pVideoPlayer->bStopBeforeSchedule = false; pVideoPlayer->pResetflag = 0; @@ -321,13 +321,13 @@ Sleep(1500); // let the copyright window stay for a while #endif - if (!bNoSound && pAudioPlayer->hAILRedbook ) + /*if (!bNoSound && pAudioPlayer->hAILRedbook ) { pAudioPlayer->SetMusicVolume((signed __int64)(pSoundVolumeLevels[uMusicVolimeMultiplier] * 64.0)); AIL_redbook_stop(pAudioPlayer->hAILRedbook); AIL_redbook_track_info(pAudioPlayer->hAILRedbook, 14, &uTrackStartMS, &uTrackEndMS); AIL_redbook_play(pAudioPlayer->hAILRedbook, uTrackStartMS + 1, uTrackEndMS); - } + } */ bGameoverLoop = 0; }
--- a/mm7_2.cpp Fri Mar 14 17:59:06 2014 +0600 +++ b/mm7_2.cpp Fri Mar 14 22:26:52 2014 +0600 @@ -2366,8 +2366,7 @@ unsigned int pY; // [sp-18h] [bp-54h]@39 Texture *pTexture; // [sp-14h] [bp-50h]@39 GUIButton *pButton2; // [sp+0h] [bp-3Ch]@27 - //GUIWindow *pWindow; // [sp+4h] [bp-38h]@11 - + pCurrentScreen = SCREEN_GAME; pGUIWindow2 = 0; @@ -3802,7 +3801,22 @@ SecondaryInitialization(); pRenderer->SetRasterClipRect(0, 0, window->GetWidth() - 1, window->GetHeight() - 1); FinalInitialization(); + + //Ritor1: include MMT_MainMenu_Loop(); + + unsigned int uTrackStartMS; + unsigned int uTrackEndMS; + + if (!bNoSound && pAudioPlayer->hAILRedbook ) + { + pAudioPlayer->SetMusicVolume((signed __int64)(pSoundVolumeLevels[uMusicVolimeMultiplier] * 64.0)); + AIL_redbook_stop(pAudioPlayer->hAILRedbook); + AIL_redbook_track_info(pAudioPlayer->hAILRedbook, 14, &uTrackStartMS, &uTrackEndMS); + AIL_redbook_play(pAudioPlayer->hAILRedbook, uTrackStartMS + 1, uTrackEndMS); + } + //-------- + Log::Warning(L"MM: entering main loop"); while ( 1 ) {