Mercurial > mm7
comparison UIPartyCreation.cpp @ 982:08fd1436ef35
enums & lod
author | Nomad |
---|---|
date | Sat, 11 May 2013 13:19:55 +0200 |
parents | ac85898f5903 |
children | a704435d3285 c45d51b3f4f4 |
comparison
equal
deleted
inserted
replaced
981:a6ef7125f6e4 | 982:08fd1436ef35 |
---|---|
651 pFontCChar = LoadFont("cchar.fnt", "FONTPAL", NULL); | 651 pFontCChar = LoadFont("cchar.fnt", "FONTPAL", NULL); |
652 } | 652 } |
653 // 4E28F8: using guessed type int pCurrentScreen; | 653 // 4E28F8: using guessed type int pCurrentScreen; |
654 | 654 |
655 //----- (0049750E) -------------------------------------------------------- | 655 //----- (0049750E) -------------------------------------------------------- |
656 void __cdecl DeleteCCharFont() | 656 void DeleteCCharFont() |
657 { | 657 { |
658 pAllocator->FreeChunk(pFontCChar); | 658 pAllocator->FreeChunk(pFontCChar); |
659 pFontCChar = 0; | 659 pFontCChar = 0; |
660 } | 660 } |
661 //----- (00497526) -------------------------------------------------------- | 661 //----- (00497526) -------------------------------------------------------- |
662 bool __cdecl PlayerCreationUI_Loop() | 662 bool PlayerCreationUI_Loop() |
663 { | 663 { |
664 //RGBTexture *pTexture; // ebx@1 | 664 //RGBTexture *pTexture; // ebx@1 |
665 UINT v1; // esi@1 | 665 //UINT v1; // esi@1 |
666 unsigned int v2; // ecx@3 | 666 unsigned int v2; // ecx@3 |
667 LONG uMouseX; // edi@6 | 667 LONG uMouseX; // edi@6 |
668 LONG uMouseY; // eax@6 | 668 LONG uMouseY; // eax@6 |
669 GUIButton *pControlsHead; // edx@6 | 669 GUIButton *pControlsHead; // edx@6 |
670 //unsigned int pNumMessage; // ecx@7 | 670 //unsigned int pNumMessage; // ecx@7 |
689 bool v26; // [sp+74h] [bp-Ch]@1 | 689 bool v26; // [sp+74h] [bp-Ch]@1 |
690 //POINT v24; // [sp+78h] [bp-8h]@6 | 690 //POINT v24; // [sp+78h] [bp-8h]@6 |
691 //Player *pPlayer; | 691 //Player *pPlayer; |
692 | 692 |
693 //pTexture = &pTexture_PCX; | 693 //pTexture = &pTexture_PCX; |
694 v1 = 0; | |
695 v26 = 0; | 694 v26 = 0; |
696 pTexture_PCX.Release(); | 695 pTexture_PCX.Release(); |
697 pTexture_PCX.Load("makeme.pcx", 0); | 696 pTexture_PCX.Load("makeme.pcx", 0); |
698 if (pAsyncMouse) | 697 if (pAsyncMouse) |
699 pAsyncMouse->Resume(); | 698 pAsyncMouse->Resume(); |
701 pGUIWindow_CurrentMenu->field_40 = 0; | 700 pGUIWindow_CurrentMenu->field_40 = 0; |
702 //LABEL_27: | 701 //LABEL_27: |
703 SetCurrentMenuID((MENU_STATE)v2); | 702 SetCurrentMenuID((MENU_STATE)v2); |
704 while ( GetCurrentMenuID() == MENU_CREATEPARTY ) | 703 while ( GetCurrentMenuID() == MENU_CREATEPARTY ) |
705 { | 704 { |
706 if ( pAsyncMouse != (void *)v1 ) | 705 if (pAsyncMouse) |
707 pAsyncMouse->_46B736_consume_click_lists(1); | 706 pAsyncMouse->_46B736_consume_click_lists(1); |
708 uMouseX = pMouse->GetCursorPos(&v25)->x; | 707 uMouseX = pMouse->GetCursorPos(&v25)->x; |
709 uMouseY = pMouse->GetCursorPos(&v25)->y; | 708 uMouseY = pMouse->GetCursorPos(&v25)->y; |
710 pControlsHead = pGUIWindow_CurrentMenu->pControlsHead; | 709 pControlsHead = pGUIWindow_CurrentMenu->pControlsHead; |
711 | 710 |
725 pControlsHead = pControlsHead->pNext; | 724 pControlsHead = pControlsHead->pNext; |
726 } | 725 } |
727 while ( pControlsHead != (GUIButton *)v1 ); | 726 while ( pControlsHead != (GUIButton *)v1 ); |
728 }*/ | 727 }*/ |
729 | 728 |
730 while ( PeekMessageA(&Msg, (HWND)v1, v1, v1, PM_REMOVE) ) | 729 while ( PeekMessageA(&Msg, 0, 0, 0, PM_REMOVE) ) |
731 { | 730 { |
732 if ( Msg.message == WM_QUIT ) | 731 if ( Msg.message == WM_QUIT ) |
733 Game_DeinitializeAndTerminate(0); | 732 Game_DeinitializeAndTerminate(0); |
734 TranslateMessage(&Msg); | 733 TranslateMessage(&Msg); |
735 DispatchMessageA(&Msg); | 734 DispatchMessageA(&Msg); |
749 if ( uGameState == GAME_FINISHED )//if click Esc in PlayerCreation Window | 748 if ( uGameState == GAME_FINISHED )//if click Esc in PlayerCreation Window |
750 { | 749 { |
751 v26 = 1; | 750 v26 = 1; |
752 //v2 = 0; | 751 //v2 = 0; |
753 //goto LABEL_27; | 752 //goto LABEL_27; |
754 SetCurrentMenuID((MENU_STATE)MENU_MAIN); | 753 SetCurrentMenuID(MENU_MAIN); |
755 continue; | 754 continue; |
756 } | 755 } |
757 if ( uGameState == GAME_STATE_6 )//if click OK in PlayerCreation Window | 756 if ( uGameState == GAME_STATE_STARTING_NEW_GAME )//if click OK in PlayerCreation Window |
758 { | 757 { |
759 uGameState = v1; | 758 uGameState = GAME_STATE_PLAYING; |
760 //v2 = 1; | 759 //v2 = 1; |
761 //goto LABEL_27; | 760 //goto LABEL_27; |
762 SetCurrentMenuID((MENU_STATE)MENU_NEWGAME); | 761 SetCurrentMenuID(MENU_NEWGAME); |
763 continue; | 762 continue; |
764 } | 763 } |
765 } | 764 } |
766 } | 765 } |
767 pTexture_PCX.Release(); | 766 pTexture_PCX.Release(); |
768 pGUIWindow_CurrentMenu->Release(); | 767 pGUIWindow_CurrentMenu->Release(); |
769 pIcons_LOD->_4114F2(); | 768 pIcons_LOD->_4114F2(); |
770 | 769 |
770 int v1 = 0; | |
771 memset(v20, 0, 32); | 771 memset(v20, 0, 32); |
772 do | 772 do |
773 { | 773 { |
774 v8 = 0; | 774 v8 = 0; |
775 do | 775 do |
888 break; | 888 break; |
889 } | 889 } |
890 | 890 |
891 for (uint k = 0; k < 138; k++) | 891 for (uint k = 0; k < 138; k++) |
892 { | 892 { |
893 if (&player->pInventoryItems[k]) | 893 if (player->pInventoryItems[k].uItemID) |
894 player->pInventoryItems[k].SetIdentified(); | 894 player->pInventoryItems[k].SetIdentified(); |
895 } | 895 } |
896 } | 896 } |
897 } | 897 } |
898 | 898 |