Mercurial > mm7
comparison GUI/GUIWindow.cpp @ 2548:87e5590d034b
All Books windows are refactored into respective classes
author | a.parshin |
---|---|
date | Tue, 12 May 2015 03:24:19 +0200 |
parents | fed97f15d1e1 |
children | 3121fb54a110 |
comparison
equal
deleted
inserted
replaced
2547:fed97f15d1e1 | 2548:87e5590d034b |
---|---|
217 | 217 |
218 | 218 |
219 GUIWindow_Spellbook::GUIWindow_Spellbook(unsigned int x, unsigned int y, unsigned int width, unsigned int height, int button, const char *hint) : | 219 GUIWindow_Spellbook::GUIWindow_Spellbook(unsigned int x, unsigned int y, unsigned int width, unsigned int height, int button, const char *hint) : |
220 GUIWindow(x, y, width, height, button, hint) | 220 GUIWindow(x, y, width, height, button, hint) |
221 { | 221 { |
222 InitializeBookTextures(); | 222 InitializeSpellBookTextures(); |
223 OpenSpellBook(); | 223 OpenSpellBook(); |
224 } | 224 } |
225 | 225 |
226 GUIWindow_GenericDialogue::GUIWindow_GenericDialogue(unsigned int x, unsigned int y, unsigned int width, unsigned int height, int button, const char *hint) : | 226 GUIWindow_GenericDialogue::GUIWindow_GenericDialogue(unsigned int x, unsigned int y, unsigned int width, unsigned int height, int button, const char *hint) : |
227 GUIWindow(x, y, width, height, button, hint) | 227 GUIWindow(x, y, width, height, button, hint) |
396 } | 396 } |
397 } | 397 } |
398 | 398 |
399 | 399 |
400 | 400 |
401 void GUIWindow_Book::Release() | |
402 { | |
403 OnCloseBook(); | |
404 | |
405 GUIWindow::Release(); | |
406 } | |
407 | 401 |
408 void GUIWindow_Dialogue::Release() | 402 void GUIWindow_Dialogue::Release() |
409 { | 403 { |
410 if (!dword_591084) | 404 if (!dword_591084) |
411 pDialogueNPCPortraits[0]->Release(); | 405 pDialogueNPCPortraits[0]->Release(); |
505 for ( uID; uID; --uID ) | 499 for ( uID; uID; --uID ) |
506 result = result->pNext; | 500 result = result->pNext; |
507 return result; | 501 return result; |
508 } | 502 } |
509 | 503 |
510 //----- (00411BFC) -------------------------------------------------------- | |
511 void GUIWindow::InitializeBookView() | |
512 { | |
513 char *pString; // eax@12 | |
514 int pTextHeight; // eax@12 | |
515 //__int64 page_count; // qax@12 | |
516 unsigned int page_count; // esi@12 | |
517 unsigned __int16 v18; // ax@38 | |
518 signed int max_beacons; // [sp+10h] [bp-5Ch]@38 | |
519 GUIWindow journal_window; // [sp+18h] [bp-54h]@8 | |
520 | |
521 pAudioPlayer->StopChannels(-1, -1); | |
522 InitializeBookFonts(); | |
523 this->CreateButton(475, 445, 158, 34, 1, 0, UIMSG_Escape, 0, 0, pGlobalTXT_LocalizationStrings[79], 0); // Close | |
524 current_screen_type = SCREEN_BOOKS; | |
525 full_num_items_in_book = 0; | |
526 books_primary_item_per_page = 0; | |
527 books_page_number = 0; | |
528 num_achieved_awards = 0; | |
529 switch (this->par1C) | |
530 { | |
531 case WINDOW_LloydsBeacon: | |
532 { | |
533 byte_506360 = 0; | |
534 pTexture_CurrentBook = pIcons_LOD->LoadTexturePtr("lb_bordr", TEXTURE_16BIT_PALETTE); | |
535 pTexture_LloydBeacons[0] = pIcons_LOD->LoadTexturePtr("sbmap", TEXTURE_16BIT_PALETTE); | |
536 pTexture_LloydBeacons[1] = pIcons_LOD->LoadTexturePtr("sbmap", TEXTURE_16BIT_PALETTE); | |
537 pTex_book_button1_on = pIcons_LOD->LoadTexturePtr("tab-an-6b", TEXTURE_16BIT_PALETTE); | |
538 pTex_book_button1_off = pIcons_LOD->LoadTexturePtr("tab-an-6a", TEXTURE_16BIT_PALETTE); | |
539 | |
540 pBtn_Book_1 = this->CreateButton(415, 13, 39, 36, 1, 0, UIMSG_LloydsBeacon_FlippingBtn, 0, 0, pGlobalTXT_LocalizationStrings[375], 0); // Set Beacon | |
541 pBtn_Book_2 = this->CreateButton(415, 48, 39, 36, 1, 0, UIMSG_LloydsBeacon_FlippingBtn, 1, 0, pGlobalTXT_LocalizationStrings[523], 0); // Recall Beacon | |
542 | |
543 max_beacons = 1; | |
544 v18 = pParty->pPlayers[_506348_current_lloyd_playerid].pActiveSkills[PLAYER_SKILL_WATER]; | |
545 if ( v18 & 0x100 || (v18 & 0x80) ) | |
546 max_beacons = 5; | |
547 else if ( v18 & 0x40 ) | |
548 max_beacons = 3; | |
549 | |
550 for ( int i = 0; i < max_beacons; ++i ) | |
551 CreateButton(pLloydsBeaconsPreviewXs[i], pLloydsBeaconsPreviewYs[i], | |
552 92, 68, 1, 180, UIMSG_InstallBeacon, i, 0, "", 0); | |
553 | |
554 for ( int i = 0; i < 5; ++i ) | |
555 { | |
556 if (pParty->pPlayers[_506348_current_lloyd_playerid].pInstalledBeacons[i].uBeaconTime >= (signed __int64)pParty->uTimePlayed) | |
557 LoadThumbnailLloydTexture(i, _506348_current_lloyd_playerid + 1); | |
558 else | |
559 memset(&pParty->pPlayers[_506348_current_lloyd_playerid].pInstalledBeacons[i], 0, sizeof(LloydBeacon)); | |
560 } | |
561 } | |
562 break; | |
563 | |
564 case WINDOW_TownPortal: | |
565 { | |
566 pTexture_CurrentBook = pIcons_LOD->LoadTexturePtr("townport", TEXTURE_16BIT_PALETTE); | |
567 pTexture_TownPortalIcons[0] = pIcons_LOD->LoadTexturePtr("tpharmndy", TEXTURE_16BIT_PALETTE); | |
568 pTexture_TownPortalIcons[1] = pIcons_LOD->LoadTexturePtr("tpelf", TEXTURE_16BIT_PALETTE); | |
569 pTexture_TownPortalIcons[2] = pIcons_LOD->LoadTexturePtr("tpwarlock", TEXTURE_16BIT_PALETTE); | |
570 pTexture_TownPortalIcons[3] = pIcons_LOD->LoadTexturePtr("tpisland", TEXTURE_16BIT_PALETTE); | |
571 pTexture_TownPortalIcons[4] = pIcons_LOD->LoadTexturePtr("tpheaven", TEXTURE_16BIT_PALETTE); | |
572 pTexture_TownPortalIcons[5] = pIcons_LOD->LoadTexturePtr("tphell", TEXTURE_16BIT_PALETTE); | |
573 | |
574 static int pTownPortalBook_ws[6] = { 80, 66, 68, 72, 67, 74}; | |
575 static int pTownPortalBook_hs[6] = { 55, 56, 65, 67, 67, 59}; | |
576 for ( uint i = 0; i < 6; ++i ) | |
577 this->CreateButton(pTownPortalBook_xs[i], pTownPortalBook_ys[i], pTownPortalBook_ws[i], pTownPortalBook_hs[i], 1, 182, UIMSG_ClickTownInTP, i, 0, "", nullptr); | |
578 | |
579 } | |
580 break; | |
581 | |
582 case WINDOW_QuestBook: | |
583 { | |
584 pTexture_CurrentBook = pIcons_LOD->LoadTexturePtr("sbquiknot", TEXTURE_16BIT_PALETTE); | |
585 pSpellBookPagesTextr_10 = pIcons_LOD->LoadTexturePtr( "divbar", TEXTURE_16BIT_PALETTE); | |
586 pTex_book_button1_on = pIcons_LOD->LoadTexturePtr("tab-an-6b", TEXTURE_16BIT_PALETTE); | |
587 pTex_book_button2_on = pIcons_LOD->LoadTexturePtr("tab-an-7b", TEXTURE_16BIT_PALETTE); | |
588 pTex_book_button1_off = pIcons_LOD->LoadTexturePtr("tab-an-6a", TEXTURE_16BIT_PALETTE); | |
589 pTex_book_button2_off = pIcons_LOD->LoadTexturePtr("tab-an-7a", TEXTURE_16BIT_PALETTE); | |
590 pBtn_Book_1 = this->CreateButton(pViewport->uViewportTL_X + 398, pViewport->uViewportTL_Y + 1, | |
591 pTex_book_button1_on->uTextureWidth, pTex_book_button1_on->uTextureHeight, | |
592 1, 0, UIMSG_ClickBooksBtn, 0xBu, 0, pGlobalTXT_LocalizationStrings[192],// "Scroll Up" | |
593 pTex_book_button1_on, 0); | |
594 pBtn_Book_2 = this->CreateButton(pViewport->uViewportTL_X + 398, pViewport->uViewportTL_Y + 38, | |
595 pTex_book_button2_on->uTextureHeight, pTex_book_button2_on->uTextureHeight, | |
596 1, 0, UIMSG_ClickBooksBtn, 0xAu, 0, pGlobalTXT_LocalizationStrings[193],// "Scroll Down" | |
597 pTex_book_button2_on, 0); | |
598 num_achieved_awards = 0; | |
599 memset(achieved_awards.data(), 0, 4000); | |
600 for ( uint i = books_primary_item_per_page; i < 512; ++i ) | |
601 { | |
602 if ( _449B57_test_bit(pParty->_quest_bits, i) && pQuestTable[i] ) | |
603 { | |
604 achieved_awards[num_achieved_awards] = (AwardType)i; | |
605 ++num_achieved_awards; | |
606 } | |
607 } | |
608 full_num_items_in_book = num_achieved_awards; | |
609 num_achieved_awards = 0; | |
610 } | |
611 break; | |
612 | |
613 case WINDOW_AutonotesBook: | |
614 { | |
615 pTexture_AutonotesBook = pIcons_LOD->LoadTexturePtr("sbautnot", TEXTURE_16BIT_PALETTE); | |
616 pSpellBookPagesTextr_10 = pIcons_LOD->LoadTexturePtr("divbar", TEXTURE_16BIT_PALETTE); | |
617 pTex_book_button1_on = pIcons_LOD->LoadTexturePtr("tab-an-6b", TEXTURE_16BIT_PALETTE); | |
618 pTex_book_button2_on = pIcons_LOD->LoadTexturePtr("tab-an-7b", TEXTURE_16BIT_PALETTE); | |
619 pTex_book_button1_off = pIcons_LOD->LoadTexturePtr("tab-an-6a", TEXTURE_16BIT_PALETTE); | |
620 pTex_book_button2_off = pIcons_LOD->LoadTexturePtr("tab-an-7a", TEXTURE_16BIT_PALETTE); | |
621 pTex_book_button3_on = pIcons_LOD->LoadTexturePtr("tab-an-1b", TEXTURE_16BIT_PALETTE); | |
622 pTex_book_button3_off = pIcons_LOD->LoadTexturePtr("tab-an-1a", TEXTURE_16BIT_PALETTE); | |
623 pTex_book_button4_on = pIcons_LOD->LoadTexturePtr("tab-an-2b", TEXTURE_16BIT_PALETTE); | |
624 pTex_book_button4_off = pIcons_LOD->LoadTexturePtr("tab-an-2a", TEXTURE_16BIT_PALETTE); | |
625 pTex_book_button5_on = pIcons_LOD->LoadTexturePtr("tab-an-3b", TEXTURE_16BIT_PALETTE); | |
626 pTex_book_button5_off = pIcons_LOD->LoadTexturePtr("tab-an-3a", TEXTURE_16BIT_PALETTE); | |
627 pTex_book_button6_on = pIcons_LOD->LoadTexturePtr("tab-an-5b", TEXTURE_16BIT_PALETTE); | |
628 pTex_book_button6_off = pIcons_LOD->LoadTexturePtr("tab-an-5a", TEXTURE_16BIT_PALETTE); | |
629 pTex_book_button7_on = pIcons_LOD->LoadTexturePtr("tab-an-4b", TEXTURE_16BIT_PALETTE); | |
630 pTex_book_button7_off = pIcons_LOD->LoadTexturePtr("tab-an-4a", TEXTURE_16BIT_PALETTE); | |
631 pTex_book_button8_on = pIcons_LOD->LoadTexturePtr("tab-an-8b", TEXTURE_16BIT_PALETTE); | |
632 pTex_book_button8_off = pIcons_LOD->LoadTexturePtr("tab-an-8a", TEXTURE_16BIT_PALETTE); | |
633 | |
634 pBtn_Book_1 = this->CreateButton(pViewport->uViewportTL_X + 398, pViewport->uViewportTL_Y + 1, 50, 34, 1, 0, | |
635 UIMSG_ClickBooksBtn, 11, 0, pGlobalTXT_LocalizationStrings[193], pTex_book_button1_on, 0); | |
636 pBtn_Book_2 = this->CreateButton(pViewport->uViewportTL_X + 398, pViewport->uViewportTL_Y + 38, 50, 34, 1, 0, | |
637 UIMSG_ClickBooksBtn, 10, 0, pGlobalTXT_LocalizationStrings[192], pTex_book_button2_on, 0); | |
638 pBtn_Book_3 = this->CreateButton(pViewport->uViewportTL_X + 398, pViewport->uViewportTL_Y + 113, 50, 34, 1, 0, | |
639 UIMSG_ClickBooksBtn, 2, 0, pGlobalTXT_LocalizationStrings[85], pTex_book_button3_on, 0); // "Potion Notes" | |
640 pBtn_Book_4 = this->CreateButton(pViewport->uViewportTL_X + 399, pViewport->uViewportTL_Y + 150, 50, 34, 1, 0, | |
641 UIMSG_ClickBooksBtn, 3, 0, pGlobalTXT_LocalizationStrings[137], pTex_book_button4_on, 0); // "Fountain Notes" | |
642 pBtn_Book_5 = this->CreateButton(pViewport->uViewportTL_X + 397, pViewport->uViewportTL_Y + 188, 50, 34, 1, 0, | |
643 UIMSG_ClickBooksBtn, 4, 0, pGlobalTXT_LocalizationStrings[8], pTex_book_button5_on, 0); // "Obelisk Notes" | |
644 pBtn_Book_6 = this->CreateButton(pViewport->uViewportTL_X + 397, pViewport->uViewportTL_Y + 226, 50, 34, 1, 0, | |
645 UIMSG_ClickBooksBtn, 5, 0, pGlobalTXT_LocalizationStrings[141], pTex_book_button6_on, 0); // "Seer Notes" | |
646 pBtn_Autonotes_Misc = this->CreateButton(pViewport->uViewportTL_X + 397, pViewport->uViewportTL_Y + 264, 50, 34, 1, 0, | |
647 UIMSG_ClickBooksBtn, 6, 0, pGlobalTXT_LocalizationStrings[123], pTex_book_button7_on, 0); // "Miscellaneous Notes" | |
648 pBtn_Autonotes_Instructors = this->CreateButton(pViewport->uViewportTL_X + 397, pViewport->uViewportTL_Y + 302, 50, 34, 1, 0, | |
649 UIMSG_ClickBooksBtn, 7, 0, pGlobalTXT_LocalizationStrings[662], pTex_book_button8_on, 0); // "Instructors" | |
650 | |
651 num_achieved_awards = 0; | |
652 for ( uint i = books_primary_item_per_page; i < 196; ++i ) | |
653 { | |
654 if ( _506568_autonote_type == pAutonoteTxt[i].eType)//dword_72371C[2 * v10] ) | |
655 { | |
656 if ( i ) | |
657 { | |
658 if ( _449B57_test_bit(pParty->_autonote_bits, i) && pAutonoteTxt[i].pText ) | |
659 { | |
660 achieved_awards[num_achieved_awards] = (AwardType)i; | |
661 ++num_achieved_awards; | |
662 } | |
663 } | |
664 } | |
665 } | |
666 full_num_items_in_book = num_achieved_awards; | |
667 num_achieved_awards = 0; | |
668 } | |
669 break; | |
670 | |
671 case WINDOW_MapsBook: | |
672 { | |
673 dword_506364 = 1; | |
674 pSpellBookPagesTextr_12 = pIcons_LOD->LoadTexturePtr("sbmap", TEXTURE_16BIT_PALETTE); | |
675 pTex_book_button1_on = pIcons_LOD->LoadTexturePtr("zoom-on", TEXTURE_16BIT_PALETTE); | |
676 pTex_book_button2_on = pIcons_LOD->LoadTexturePtr("zoot-on", TEXTURE_16BIT_PALETTE); | |
677 pTex_book_button1_off = pIcons_LOD->LoadTexturePtr("zoom-off", TEXTURE_16BIT_PALETTE); | |
678 pTex_book_button2_off = pIcons_LOD->LoadTexturePtr("zoot-off", TEXTURE_16BIT_PALETTE); | |
679 pTex_book_button3_on = pIcons_LOD->LoadTexturePtr("tabNon", TEXTURE_16BIT_PALETTE); | |
680 pTex_book_button3_off = pIcons_LOD->LoadTexturePtr("tabNoff", TEXTURE_16BIT_PALETTE); | |
681 pTex_book_button4_on = pIcons_LOD->LoadTexturePtr("tabSon", TEXTURE_16BIT_PALETTE); | |
682 pTex_book_button4_off = pIcons_LOD->LoadTexturePtr("tabSoff", TEXTURE_16BIT_PALETTE); | |
683 pTex_book_button5_on = pIcons_LOD->LoadTexturePtr("tabEon", TEXTURE_16BIT_PALETTE); | |
684 pTex_book_button5_off = pIcons_LOD->LoadTexturePtr("tabEoff", TEXTURE_16BIT_PALETTE); | |
685 pTex_book_button6_on = pIcons_LOD->LoadTexturePtr("tabWon", TEXTURE_16BIT_PALETTE); | |
686 pTex_book_button6_off = pIcons_LOD->LoadTexturePtr("tabWoff", TEXTURE_16BIT_PALETTE); | |
687 | |
688 pBtn_Book_1 = this->CreateButton(pViewport->uViewportTL_X + 398, pViewport->uViewportTL_Y + 1, 50, 34, 1, 0, | |
689 UIMSG_ClickBooksBtn, 0, 0, pGlobalTXT_LocalizationStrings[251], pTex_book_button1_on, 0);// "Zoom In" | |
690 pBtn_Book_2 = this->CreateButton(pViewport->uViewportTL_X + 398, pViewport->uViewportTL_Y + 38, 50, 34, 1, 0, | |
691 UIMSG_ClickBooksBtn, 1, 0, pGlobalTXT_LocalizationStrings[252], pTex_book_button2_on, 0);// "Zoom Out" | |
692 pBtn_Book_3 = this->CreateButton(pViewport->uViewportTL_X + 397, pViewport->uViewportTL_Y + 113, 50, 34, 1, 0, | |
693 UIMSG_ClickBooksBtn, 2, 0, pGlobalTXT_LocalizationStrings[192], (Texture *)"", 0);// Scroll Up | |
694 pBtn_Book_4 = this->CreateButton(pViewport->uViewportTL_X + 397, pViewport->uViewportTL_Y + 150, 50, 34, 1, 0, | |
695 UIMSG_ClickBooksBtn, 3, 0, pGlobalTXT_LocalizationStrings[193], (Texture *)"", 0);// Scroll Down | |
696 pBtn_Book_5 = this->CreateButton(pViewport->uViewportTL_X + 397, pViewport->uViewportTL_Y + 188, 50, 34, 1, 0, | |
697 UIMSG_ClickBooksBtn, 4, 0, pGlobalTXT_LocalizationStrings[573], (Texture *)"", 0);// "Scroll Right" | |
698 pBtn_Book_6 = this->CreateButton(pViewport->uViewportTL_X + 397, pViewport->uViewportTL_Y + 226, 50, 34, 1, 0, | |
699 UIMSG_ClickBooksBtn, 5, 0, pGlobalTXT_LocalizationStrings[572], (Texture *)"", 0);// "Scroll Left" | |
700 } | |
701 break; | |
702 | |
703 case WINDOW_CalendarBook: | |
704 { | |
705 pSpellBookPagesTextr_13 = pIcons_LOD->LoadTexturePtr("sbdate-time", TEXTURE_16BIT_PALETTE); | |
706 pTex_moon_new = pIcons_LOD->LoadTexturePtr("moon_new", TEXTURE_16BIT_PALETTE); | |
707 pTex_moon_4 = pIcons_LOD->LoadTexturePtr("moon_4", TEXTURE_16BIT_PALETTE); | |
708 pTex_moon_2 = pIcons_LOD->LoadTexturePtr("moon_2", TEXTURE_16BIT_PALETTE); | |
709 pTex_moon_2_2 = pIcons_LOD->LoadTexturePtr("moon_2", TEXTURE_16BIT_PALETTE); | |
710 pTex_moon_ful = pIcons_LOD->LoadTexturePtr("moon_ful", TEXTURE_16BIT_PALETTE); | |
711 } | |
712 break; | |
713 | |
714 case WINDOW_JournalBook: | |
715 { | |
716 pSpellBookPagesTextr_11 = pIcons_LOD->LoadTexturePtr("sbplayrnot", TEXTURE_16BIT_PALETTE); | |
717 pTex_book_button1_on = pIcons_LOD->LoadTexturePtr("tab-an-6b", TEXTURE_16BIT_PALETTE); | |
718 pTex_book_button2_on = pIcons_LOD->LoadTexturePtr("tab-an-7b", TEXTURE_16BIT_PALETTE); | |
719 pTex_book_button1_off = pIcons_LOD->LoadTexturePtr("tab-an-6a", TEXTURE_16BIT_PALETTE); | |
720 pTex_book_button2_off = pIcons_LOD->LoadTexturePtr("tab-an-7a", TEXTURE_16BIT_PALETTE); | |
721 | |
722 pBtn_Book_1 = this->CreateButton(pViewport->uViewportTL_X + 398, pViewport->uViewportTL_Y + 1, | |
723 pTex_book_button1_on->uTextureWidth, pTex_book_button1_on->uTextureHeight, 1, 0, | |
724 UIMSG_ClickBooksBtn, 11, 0, pGlobalTXT_LocalizationStrings[192], pTex_book_button1_on, 0); | |
725 pBtn_Book_2 = this->CreateButton(pViewport->uViewportTL_X + 398, pViewport->uViewportTL_Y + 38, pTex_book_button2_on->uTextureHeight, | |
726 pTex_book_button2_on->uTextureHeight, 1, 0, UIMSG_ClickBooksBtn, 10, 0, | |
727 pGlobalTXT_LocalizationStrings[193], pTex_book_button2_on, 0); | |
728 | |
729 num_achieved_awards = 0; | |
730 journal_window.uFrameX = 48; | |
731 journal_window.uFrameY = 70; | |
732 journal_window.uFrameWidth = 360; | |
733 journal_window.uFrameHeight = 264; | |
734 journal_window.uFrameZ = 407; | |
735 journal_window.uFrameHeight = (LOBYTE(pAutonoteFont->uFontHeight) - 3) * 264 / LOBYTE(pAutonoteFont->uFontHeight) - 3; | |
736 journal_window.uFrameW = journal_window.uFrameHeight + 69; | |
737 memset(&achieved_awards, 0, 4000); | |
738 memset(Journal_limitation_factor.data(), 0, 100); | |
739 if ( books_primary_item_per_page < 29 ) | |
740 { | |
741 for ( int i = books_primary_item_per_page; i < books_primary_item_per_page + 29; i++ ) | |
742 { | |
743 if ( pParty->PartyTimes.HistoryEventTimes[i] > 0 ) | |
744 { | |
745 if ( pStorylineText->StoreLine[i + 1].pText ) | |
746 { | |
747 pString = BuildDialogueString(pStorylineText->StoreLine[i + 1].pText, uActiveCharacter - 1, 0, 0, 0, &pParty->PartyTimes.HistoryEventTimes[i]); | |
748 pTextHeight = pAutonoteFont->CalcTextHeight(pString, &journal_window, 1, 0); | |
749 page_count = ((pTextHeight - (pAutonoteFont->uFontHeight - 3)) / (signed int)journal_window.uFrameHeight) + 1; | |
750 memset32((char *)&achieved_awards[num_achieved_awards] , i + 1, page_count); | |
751 for ( uint j = 0; j <= page_count - 1; ++j ) | |
752 Journal_limitation_factor[num_achieved_awards++] = j; | |
753 } | |
754 } | |
755 } | |
756 } | |
757 full_num_items_in_book = num_achieved_awards; | |
758 num_achieved_awards = 0; | |
759 } | |
760 break; | |
761 } | |
762 } | |
763 | 504 |
764 //----- (00415551) -------------------------------------------------------- | 505 //----- (00415551) -------------------------------------------------------- |
765 void GUIWindow::DrawMessageBox(int arg0) | 506 void GUIWindow::DrawMessageBox(int arg0) |
766 { | 507 { |
767 unsigned int v2; // edi@1 | 508 unsigned int v2; // edi@1 |
1612 pMiscTimer->Resume(); | 1353 pMiscTimer->Resume(); |
1613 pEventTimer->Resume(); | 1354 pEventTimer->Resume(); |
1614 } | 1355 } |
1615 | 1356 |
1616 | 1357 |
1617 | 1358 void GUIWindow_BooksButtonOverlay::Update() |
1618 void GUIWindow_Book::Update() | |
1619 { | |
1620 // ----------------------------------- | |
1621 // 004156F0 GUI_UpdateWindows --- part | |
1622 BookUI_Draw((WindowType)(int)ptr_1C); | |
1623 } | |
1624 | |
1625 void GUIWindow_BooksWindow::Update() | |
1626 { | 1359 { |
1627 // ----------------------------------- | 1360 // ----------------------------------- |
1628 // 004156F0 GUI_UpdateWindows --- part | 1361 // 004156F0 GUI_UpdateWindows --- part |
1629 auto pButton = (GUIButton *)ptr_1C; | 1362 auto pButton = (GUIButton *)ptr_1C; |
1630 pRenderer->DrawTextureIndexed(uFrameY, uFrameX, pButton->pTextures[0]); | 1363 pRenderer->DrawTextureIndexed(uFrameY, uFrameX, pButton->pTextures[0]); |