comparison mm7_5.cpp @ 959:f8dd764fb7d7

ExitCharacterWindow and other
author Ritor1
date Fri, 03 May 2013 17:38:30 +0600
parents e9292c58644a
children 9a5db2cf999a
comparison
equal deleted inserted replaced
958:9c2d08e42ed3 959:f8dd764fb7d7
436 dword_6BE138 = 132; 436 dword_6BE138 = 132;
437 } 437 }
438 stru_506E40.Release(); 438 stru_506E40.Release();
439 continue; 439 continue;
440 case UIMSG_80: 440 case UIMSG_80:
441 __debugbreak;
441 pIcons_LOD->_40F9C5(); 442 pIcons_LOD->_40F9C5();
442 pIcons_LOD->_4114F2(); 443 pIcons_LOD->_4114F2();
443 pGUIWindow_CurrentMenu->Release(); 444 pGUIWindow_CurrentMenu->Release();
444 pCurrentScreen = SCREEN_OPTIONS; 445 pCurrentScreen = SCREEN_OPTIONS;
445 pGUIWindow_CurrentMenu = GUIWindow::Create(0, 0, 640, 480, WINDOW_8, 0, 0); 446 pGUIWindow_CurrentMenu = GUIWindow::Create(0, 0, 640, 480, WINDOW_8, 0, 0);
455 if ( pSaveListPosition >= uMessageParam ) 456 if ( pSaveListPosition >= uMessageParam )
456 pSaveListPosition = uMessageParam - 1; 457 pSaveListPosition = uMessageParam - 1;
457 GUIWindow::Create(215, 323, 17, 17, WINDOW_5A, (int)pBtnDownArrow, 0); 458 GUIWindow::Create(215, 323, 17, 17, WINDOW_5A, (int)pBtnDownArrow, 0);
458 continue; 459 continue;
459 case UIMSG_Cancel: 460 case UIMSG_Cancel:
460 GUIWindow::Create(350, 302, 106, 42, WINDOW_60, (int)pBtnCancel, 0); 461 GUIWindow::Create(350, 302, 106, 42, WINDOW_ExitRestWindow, (int)pBtnCancel, 0);
461 continue; 462 continue;
462 case UIMSG_LoadSlot: 463 case UIMSG_LoadSlot:
463 GUIWindow::Create(241, 302, 106, 42, WINDOW_5E, (int)pBtnLoadSlot, 0); 464 GUIWindow::Create(241, 302, 106, 42, WINDOW_5E, (int)pBtnLoadSlot, 0);
464 continue; 465 continue;
465 case UIMSG_SelectLoadSlot: 466 case UIMSG_SelectLoadSlot:
1281 pCurrentScreen = SCREEN_GAME; 1282 pCurrentScreen = SCREEN_GAME;
1282 viewparams->bRedrawGameUI = v0; 1283 viewparams->bRedrawGameUI = v0;
1283 pIcons_LOD->_4355F7(); 1284 pIcons_LOD->_4355F7();
1284 continue; 1285 continue;
1285 case SCREEN_E: 1286 case SCREEN_E:
1287 __debugbreak;
1286 pGUIWindow_CurrentMenu->Release(); 1288 pGUIWindow_CurrentMenu->Release();
1287 pCurrentScreen = SCREEN_HOUSE; 1289 pCurrentScreen = SCREEN_HOUSE;
1288 pIcons_LOD->_4114F2(); 1290 pIcons_LOD->_4114F2();
1289 continue; 1291 continue;
1290 case SCREEN_HOUSE: 1292 case SCREEN_HOUSE:
10402 unsigned int v27; // ebp@106 10404 unsigned int v27; // ebp@106
10403 GUIWindow *pGUIWindow2; // ecx@109 10405 GUIWindow *pGUIWindow2; // ecx@109
10404 unsigned int v29; // eax@111 10406 unsigned int v29; // eax@111
10405 GUIFont *pGUIFont; // ST1C_4@115 10407 GUIFont *pGUIFont; // ST1C_4@115
10406 int v31; // eax@115 10408 int v31; // eax@115
10407 void *v32; // ebp@118 10409 GUIButton *pButton; // ebp@118
10408 int v33; // eax@119 10410 int v33; // eax@119
10409 int v34; // eax@120 10411 int v34; // eax@120
10410 int v35; // eax@121 10412 int v35; // eax@121
10411 int v36; // eax@122 10413 int v36; // eax@122
10412 int v37; // eax@123 10414 int v37; // eax@123
10438 { 10440 {
10439 GameUI_MainMenu_DrawLoad(); 10441 GameUI_MainMenu_DrawLoad();
10440 break; 10442 break;
10441 } 10443 }
10442 case WINDOW_5E: // window that initiates savegame loading 10444 case WINDOW_5E: // window that initiates savegame loading
10445 __debugbreak;
10443 { 10446 {
10444 if (pWindow->Hint != (char *)1) 10447 if (pWindow->Hint != (char *)1)
10445 pAudioPlayer->PlaySound(SOUND_Button2, 0, 0, -1, 0, 0, 0, 0); 10448 pAudioPlayer->PlaySound(SOUND_Button2, 0, 0, -1, 0, 0, 0, 0);
10446 auto pGUIButton3 = (GUIButton *)pWindow->ptr_1C; 10449 auto pGUIButton3 = (GUIButton *)pWindow->ptr_1C;
10447 pRenderer->DrawTextureIndexed(pWindow->uFrameX, pWindow->uFrameY, pGUIButton3->pTextures[0]); 10450 pRenderer->DrawTextureIndexed(pWindow->uFrameX, pWindow->uFrameY, pGUIButton3->pTextures[0]);
10535 GameMenuUI_DrawKeyBindings(); 10538 GameMenuUI_DrawKeyBindings();
10536 break; 10539 break;
10537 } 10540 }
10538 case WINDOW_17: 10541 case WINDOW_17:
10539 { 10542 {
10543 __debugbreak;
10540 sub_4606FE(); 10544 sub_4606FE();
10541 break; 10545 break;
10542 } 10546 }
10543 case WINDOW_CastSpell_InInventory: 10547 case WINDOW_CastSpell_InInventory:
10544 { 10548 {
10567 GUIButton2.pParent = 0; 10571 GUIButton2.pParent = 0;
10568 pGUIWindow2 = pWindow; 10572 pGUIWindow2 = pWindow;
10569 pGUIWindow2->Release(); 10573 pGUIWindow2->Release();
10570 break; 10574 break;
10571 } 10575 }
10572 case WINDOW_60: 10576 case WINDOW_ExitRestWindow:
10573 { 10577 {
10574 if ( pWindow->Hint != (char *)1 ) 10578 if ( pWindow->Hint != (char *)1 )
10575 pAudioPlayer->PlaySound(SOUND_Button2, 0, 0, -1, 0, 0, 0, 0); 10579 pAudioPlayer->PlaySound(SOUND_Button2, 0, 0, -1, 0, 0, 0, 0);
10576 pGUIButton = (GUIButton *)pWindow->ptr_1C; 10580 pGUIButton = (GUIButton *)pWindow->ptr_1C;
10577 pRenderer->DrawTextureIndexed(pWindow->uFrameX, pWindow->uFrameY, pGUIButton->pTextures[0]); 10581 pRenderer->DrawTextureIndexed(pWindow->uFrameX, pWindow->uFrameY, pGUIButton->pTextures[0]);
10581 pGUIButton->DrawLabel(pHint, pFontCreate, 0, 0); 10585 pGUIButton->DrawLabel(pHint, pFontCreate, 0, 0);
10582 pWindow->Release(); 10586 pWindow->Release();
10583 pMessageQueue_50CBD0->AddMessage(UIMSG_Escape, 0, 0); 10587 pMessageQueue_50CBD0->AddMessage(UIMSG_Escape, 0, 0);
10584 break; 10588 break;
10585 } 10589 }
10586 case WINDOW_61: 10590 case WINDOW_ExitCharacterWindow:
10587 { 10591 {
10588 if ( pWindow->Hint != (char *)1 )//pWindowType == WINDOW_61 10592 if ( pWindow->Hint != (char *)1 )
10589 pAudioPlayer->PlaySound(SOUND_Button2, 0, 0, -1, 0, 0, 0, 0); 10593 pAudioPlayer->PlaySound(SOUND_Button2, 0, 0, -1, 0, 0, 0, 0);
10590 v32 = pWindow->ptr_1C; 10594 pButton = (GUIButton *)pWindow->ptr_1C;
10591 pRenderer->DrawTextureIndexed(pWindow->uFrameX, pWindow->uFrameY, *((Texture **)v32 + 16)); 10595 pRenderer->DrawTextureIndexed(pWindow->uFrameX, pWindow->uFrameY, pButton->pTextures[1]);
10592 pHint = pWindow->Hint; 10596 pHint = pWindow->Hint;
10593 viewparams->bRedrawGameUI = 1; 10597 viewparams->bRedrawGameUI = 1;
10594 if ( pHint && pHint != (char *)1 ) 10598 if ( pHint && pHint != (char *)1 )
10595 ((GUIButton *)v32)->DrawLabel(pHint, pFontCreate, 0, 0); 10599 pButton->DrawLabel(pHint, pFontCreate, 0, 0);
10596 pWindow->Release(); 10600 pWindow->Release();
10597 pNumMessages = pMessageQueue_50CBD0->uNumMessages; 10601 pNumMessages = pMessageQueue_50CBD0->uNumMessages;
10598 pMessageQueue_50CBD0->AddMessage(UIMSG_Escape, 0, 0); 10602 pMessageQueue_50CBD0->AddMessage(UIMSG_Escape, 0, 0);
10599 break; 10603 break;
10600 } 10604 }