comparison Engine/MMT.cpp @ 2506:9b96a51011fb

for sound
author Ritor1
date Thu, 25 Sep 2014 10:39:49 +0600
parents a77c34acdbc9
children 491f0babd563
comparison
equal deleted inserted replaced
2505:e3a619609dae 2506:9b96a51011fb
208 pCurrentScreen = SCREEN_GAME; 208 pCurrentScreen = SCREEN_GAME;
209 209
210 pGUIWindow2 = 0; 210 pGUIWindow2 = 0;
211 pAudioPlayer->StopChannels(-1, -1); 211 pAudioPlayer->StopChannels(-1, -1);
212 212
213 //if (!bNoSound ) 213 if (!bNoSound )
214 //PlayAudio(L"Sounds\\New_Sounds/Stronghold_Theme.mp3"); 214 PlayAudio(L"Sounds\\New_Sounds/Stronghold_Theme.mp3");
215 //if (!bNoVideo ) 215 //if (!bNoVideo )
216 //pVideoPlayer->PlayMovie(L"Anims\\New_Video/3DOLOGO.smk"); 216 //pVideoPlayer->PlayMovie(L"Anims\\New_Video/3DOLOGO.smk");
217 217
218 pMouse->RemoveHoldingItem(); 218 pMouse->RemoveHoldingItem();
219 219
352 switch (pUIMessageType) 352 switch (pUIMessageType)
353 { 353 {
354 case UIMSG_MMT_MainMenu_MM6: 354 case UIMSG_MMT_MainMenu_MM6:
355 //video 355 //video
356 //SetCurrentMenuID(MENU_MAIN_MM6); 356 //SetCurrentMenuID(MENU_MAIN_MM6);
357 pAudioPlayer->PlaySound((SoundID)27, 0, 0, -1, 0, 0, 0, 0);//temporarily 357 alSourcef (mSourceID, AL_GAIN, 0.5f);
358 pAudioPlayer->PlaySound(SOUND_error, 0, 0, -1, 0, 0, 0, 0);//temporarily
358 break; 359 break;
359 case UIMSG_MMT_MainMenu_MM7: //new button for ΜΜ7 360 case UIMSG_MMT_MainMenu_MM7: //new button for ΜΜ7
360 //GUIWindow::Create(495, 172, 0, 0, WINDOW_PressedButton2, (int)pMainMenu_BtnNew, 0); 361 //GUIWindow::Create(495, 172, 0, 0, WINDOW_PressedButton2, (int)pMainMenu_BtnNew, 0);
361 alSourceStop(mSourceID); 362 alSourceStop(mSourceID);
362 pMediaPlayer->ShowMM7IntroVideo_and_LoadingScreen(); 363 pMediaPlayer->ShowMM7IntroVideo_and_LoadingScreen();
363 SetCurrentMenuID(MENU_MAIN); 364 SetCurrentMenuID(MENU_MAIN);
364 break; 365 break;
365 case UIMSG_MMT_MainMenu_MM8: 366 case UIMSG_MMT_MainMenu_MM8:
366 //video 367 //video
367 //SetCurrentMenuID(MENU_MAIN_MM8); 368 //SetCurrentMenuID(MENU_MAIN_MM8);
368 pAudioPlayer->PlaySound((SoundID)27, 0, 0, -1, 0, 0, 0, 0);//temporarily 369 alSourcei (mSourceID, AL_LOOPING, 1);
370 pAudioPlayer->PlaySound(SOUND_error, 0, 0, -1, 0, 0, 0, 0);//temporarily
369 break; 371 break;
370 case UIMSG_MMT_MainMenu_Continue: 372 case UIMSG_MMT_MainMenu_Continue:
371 //video 373 //video
372 //SetCurrentMenuID(MENU_MAIN_Continue); 374 //SetCurrentMenuID(MENU_MAIN_Continue);
373 pAudioPlayer->PlaySound((SoundID)27, 0, 0, -1, 0, 0, 0, 0);//temporarily 375 alSourcef (mSourceID, AL_GAIN, 1.0f);
376 pAudioPlayer->PlaySound(SOUND_error, 0, 0, -1, 0, 0, 0, 0);//temporarily
374 break; 377 break;
375 case UIMSG_ExitToWindows: 378 case UIMSG_ExitToWindows:
376 GUIWindow::Create(495, 337, 0, 0, WINDOW_PressedButton2, (int)pMainMenu_BtnExit, 0); 379 GUIWindow::Create(495, 337, 0, 0, WINDOW_PressedButton2, (int)pMainMenu_BtnExit, 0);
377 SetCurrentMenuID(MENU_EXIT_GAME); 380 SetCurrentMenuID(MENU_EXIT_GAME);
378 381