comparison mm7_5.cpp @ 999:dcdfbb6eede9

Слияние
author Ritor1
date Tue, 14 May 2013 17:38:14 +0600
parents e4383e6dfbef 5876a9cafa3e
children 53109a1455fc
comparison
equal deleted inserted replaced
998:e4383e6dfbef 999:dcdfbb6eede9
80 //const char *v31; // ecx@262 80 //const char *v31; // ecx@262
81 signed int v32; // eax@269 81 signed int v32; // eax@269
82 unsigned int v33; // eax@277 82 unsigned int v33; // eax@277
83 unsigned __int8 v34; // al@279 83 unsigned __int8 v34; // al@279
84 unsigned __int8 v35; // al@280 84 unsigned __int8 v35; // al@280
85 //GUIWindow *pWindow3; // ecx@332 85 GUIWindow *pWindow3; // ecx@332
86 int v37; // eax@341 86 int v37; // eax@341
87 int v38; // eax@358 87 int v38; // eax@358
88 SHORT v39; // ax@365 88 SHORT v39; // ax@365
89 //signed int v40; // eax@365 89 //signed int v40; // eax@365
90 char *v41; // eax@380 90 char *v41; // eax@380
95 signed int v46; // ecx@398 95 signed int v46; // ecx@398
96 char v47; // zf@399 96 char v47; // zf@399
97 char v48; // zf@405 97 char v48; // zf@405
98 BLVFace *pBLVFace; // ecx@410 98 BLVFace *pBLVFace; // ecx@410
99 ODMFace *pODMFace; // ecx@412 99 ODMFace *pODMFace; // ecx@412
100 CastSpellInfo *pSpellInfo; // ecx@415 100 CastSpellInfo *v51; // ecx@415
101 void *v52; // eax@424 101 void *v52; // eax@424
102 __int16 v53; // ax@431 102 __int16 v53; // ax@431
103 int v54; // eax@432 103 int v54; // eax@432
104 int v55; // ecx@432 104 int v55; // ecx@432
105 int v56; // edx@432 105 int v56; // edx@432
153 Player *pPlayer4; // ecx@718 153 Player *pPlayer4; // ecx@718
154 int v105; // eax@718 154 int v105; // eax@718
155 Player *pPlayer5; // ST78_4@758 155 Player *pPlayer5; // ST78_4@758
156 unsigned int v107; // eax@758 156 unsigned int v107; // eax@758
157 unsigned int v108; // eax@758 157 unsigned int v108; // eax@758
158 char *v109; // ST64_4@759
159 Player *v110; // ST78_4@759
160 int v111; // ST60_4@759
161 int v112; // ST5C_4@759
162 char *v113; // ST58_4@759
163 signed int v114; // eax@759
158 unsigned int v115; // eax@764 164 unsigned int v115; // eax@764
159 int v116; // eax@776 165 int v116; // eax@776
160 POINT *pPoint3; // eax@777 166 POINT *pPoint3; // eax@777
161 unsigned int v118; // eax@785 167 unsigned int v118; // eax@785
162 unsigned int v119; // ecx@786 168 unsigned int v119; // ecx@786
1484 pCurrentScreen = SCREEN_GAME; 1490 pCurrentScreen = SCREEN_GAME;
1485 viewparams->bRedrawGameUI = 1; 1491 viewparams->bRedrawGameUI = 1;
1486 pIcons_LOD->_4355F7(); 1492 pIcons_LOD->_4355F7();
1487 continue; 1493 continue;
1488 } 1494 }
1495 LABEL_319:
1489 CharacterUI_ReleaseButtons(); 1496 CharacterUI_ReleaseButtons();
1490 sub_419379(); 1497 sub_419379();
1491 pIcons_LOD->_4114F2(); 1498 pIcons_LOD->_4114F2();
1492 } 1499 }
1493 if ( pGUIWindow_Settings ) 1500 if ( pGUIWindow_Settings )
1516 pCurrentScreen = SCREEN_GAME; 1523 pCurrentScreen = SCREEN_GAME;
1517 viewparams->bRedrawGameUI = 1; 1524 viewparams->bRedrawGameUI = 1;
1518 pIcons_LOD->_4355F7(); 1525 pIcons_LOD->_4355F7();
1519 continue; 1526 continue;
1520 } 1527 }
1528 pWindow3 = pGUIWindow_Settings;
1521 if ( !pGUIWindow_Settings )//Draw Menu 1529 if ( !pGUIWindow_Settings )//Draw Menu
1522 { 1530 {
1523 dword_6BE138 = -1; 1531 dword_6BE138 = -1;
1524 GUIWindow::Create(0x25Au, 0x1C2u, 0, 0, WINDOW_PressedButton2, (int)pBtn_GameSettings, 1); 1532 GUIWindow::Create(0x25Au, 0x1C2u, 0, 0, WINDOW_PressedButton2, (int)pBtn_GameSettings, 1);
1525 pEventTimer->Pause(); 1533 pEventTimer->Pause();
1561 pRenderer->SavePCXImage("gamma.pcx", (char *)uNumSeconds, 155, 117); 1569 pRenderer->SavePCXImage("gamma.pcx", (char *)uNumSeconds, 155, 117);
1562 free((void *)uNumSeconds); 1570 free((void *)uNumSeconds);
1563 stru_506E40._40E55E("gamma.pcx", 0); 1571 stru_506E40._40E55E("gamma.pcx", 0);
1564 continue; 1572 continue;
1565 } 1573 }
1566 pGUIWindow_Settings->Release(); 1574 pWindow3->Release();
1567 pGUIWindow_Settings = 0; 1575 pGUIWindow_Settings = 0;
1568 pMouse->SetCursorBitmap("MICON1"); 1576 pMouse->SetCursorBitmap("MICON1");
1569 GameUI_Footer_TimeLeft = 0; 1577 GameUI_Footer_TimeLeft = 0;
1570 unk_50C9A0 = 0; 1578 unk_50C9A0 = 0;
1571 back_to_game(); 1579 back_to_game();
1593 --pParty->field_709; 1601 --pParty->field_709;
1594 if ( pParty->field_709 < 1 ) 1602 if ( pParty->field_709 < 1 )
1595 pParty->field_709 = 0; 1603 pParty->field_709 = 0;
1596 } 1604 }
1597 } 1605 }
1598 DrawHiredNPCs(); 1606 GameUI_DrawHiredNPCs();
1599 continue; 1607 continue;
1600 case UIMSG_TransitionUI_Confirm: 1608 case UIMSG_TransitionUI_Confirm:
1601 if ( pMessageQueue_50CBD0->uNumMessages ) 1609 if ( pMessageQueue_50CBD0->uNumMessages )
1602 pMessageQueue_50CBD0->uNumMessages = pMessageQueue_50CBD0->pMessages[0].field_8 != 0; 1610 pMessageQueue_50CBD0->uNumMessages = pMessageQueue_50CBD0->pMessages[0].field_8 != 0;
1603 dword_50CDC8 = 1; 1611 dword_50CDC8 = 1;
1801 if ( v45 == 3 ) 1809 if ( v45 == 3 )
1802 { 1810 {
1803 v47 = pActors[v46].uAIState == Dead; 1811 v47 = pActors[v46].uAIState == Dead;
1804 if ( !v47 ) 1812 if ( !v47 )
1805 continue; 1813 continue;
1806 pSpellInfo = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C; 1814 v51 = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C;
1807 LOBYTE(pSpellInfo->field_8) &= 0xBFu; 1815 LOBYTE(v51->field_8) &= 0xBFu;
1808 pSpellInfo->uPlayerID_2 = uMessageParam; 1816 v51->uPlayerID_2 = uMessageParam;
1809 pSpellInfo->spell_target_pid = v44; 1817 v51->spell_target_pid = v44;
1810 pParty->pPlayers[pSpellInfo->uPlayerID].SetRecoveryTime(300); 1818 pParty->pPlayers[v51->uPlayerID].SetRecoveryTime(300);
1811 pGUIWindow_Settings->Release(); 1819 pWindow3 = pGUIWindow_Settings;
1820 pWindow3->Release();
1812 pGUIWindow_Settings = 0; 1821 pGUIWindow_Settings = 0;
1813 pMouse->SetCursorBitmap("MICON1"); 1822 pMouse->SetCursorBitmap("MICON1");
1814 GameUI_Footer_TimeLeft = 0; 1823 GameUI_Footer_TimeLeft = 0;
1815 unk_50C9A0 = 0; 1824 unk_50C9A0 = 0;
1816 back_to_game(); 1825 back_to_game();
1819 if ( v45 == 2 ) 1828 if ( v45 == 2 )
1820 { 1829 {
1821 v47 = (pObjectList->pObjects[pSpriteObjects[v46].uObjectDescID].uFlags & 0x10) == 0; 1830 v47 = (pObjectList->pObjects[pSpriteObjects[v46].uObjectDescID].uFlags & 0x10) == 0;
1822 if ( !v47 ) 1831 if ( !v47 )
1823 continue; 1832 continue;
1824 pSpellInfo = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C; 1833 v51 = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C;
1825 LOBYTE(pSpellInfo->field_8) &= 0xBFu; 1834 LOBYTE(v51->field_8) &= 0xBFu;
1826 pSpellInfo->uPlayerID_2 = uMessageParam; 1835 v51->uPlayerID_2 = uMessageParam;
1827 pSpellInfo->spell_target_pid = v44; 1836 v51->spell_target_pid = v44;
1828 pParty->pPlayers[pSpellInfo->uPlayerID].SetRecoveryTime(300); 1837 pParty->pPlayers[v51->uPlayerID].SetRecoveryTime(300);
1829 pGUIWindow_Settings->Release(); 1838 pWindow3 = pGUIWindow_Settings;
1839 pWindow3->Release();
1830 pGUIWindow_Settings = 0; 1840 pGUIWindow_Settings = 0;
1831 pMouse->SetCursorBitmap("MICON1"); 1841 pMouse->SetCursorBitmap("MICON1");
1832 GameUI_Footer_TimeLeft = 0; 1842 GameUI_Footer_TimeLeft = 0;
1833 unk_50C9A0 = 0; 1843 unk_50C9A0 = 0;
1834 back_to_game(); 1844 back_to_game();
1846 { 1856 {
1847 pODMFace = &pOutdoor->pBModels[v44 >> 9].pFaces[v46 & 0x3F]; 1857 pODMFace = &pOutdoor->pBModels[v44 >> 9].pFaces[v46 & 0x3F];
1848 if ( !(pODMFace->uAttributes & 0x02000000) || !pODMFace->sCogTriggeredID ) 1858 if ( !(pODMFace->uAttributes & 0x02000000) || !pODMFace->sCogTriggeredID )
1849 continue; 1859 continue;
1850 v44 = uNumSeconds; 1860 v44 = uNumSeconds;
1851 pSpellInfo = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C; 1861 v51 = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C;
1852 LOBYTE(pSpellInfo->field_8) &= 0xBFu; 1862 *((char *)v51 + 8) &= 0xBFu;
1853 pSpellInfo->uPlayerID_2 = uMessageParam; 1863 v51->uPlayerID_2 = uMessageParam;
1854 pSpellInfo->spell_target_pid = v44; 1864 v51->spell_target_pid = v44;
1855 pParty->pPlayers[pSpellInfo->uPlayerID].SetRecoveryTime(300); 1865 pParty->pPlayers[v51->uPlayerID].SetRecoveryTime(300);
1856 pGUIWindow_Settings->Release(); 1866 pWindow3 = pGUIWindow_Settings;
1867 pWindow3->Release();
1857 pGUIWindow_Settings = 0; 1868 pGUIWindow_Settings = 0;
1858 pMouse->SetCursorBitmap("MICON1"); 1869 pMouse->SetCursorBitmap("MICON1");
1859 GameUI_Footer_TimeLeft = 0; 1870 GameUI_Footer_TimeLeft = 0;
1860 unk_50C9A0 = 0; 1871 unk_50C9A0 = 0;
1861 back_to_game(); 1872 back_to_game();
1866 continue; 1877 continue;
1867 v48 = pIndoor->pFaceExtras[pBLVFace->uFaceExtraID].uEventID == 0; 1878 v48 = pIndoor->pFaceExtras[pBLVFace->uFaceExtraID].uEventID == 0;
1868 } 1879 }
1869 if ( v48 ) 1880 if ( v48 )
1870 continue; 1881 continue;
1871 pSpellInfo = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C; 1882 v51 = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C;
1872 LOBYTE(pSpellInfo->field_8) &= 0xBFu; 1883 LOBYTE(v51->field_8) &= 0xBFu;
1873 pSpellInfo->uPlayerID_2 = uMessageParam; 1884 v51->uPlayerID_2 = uMessageParam;
1874 pSpellInfo->spell_target_pid = v44; 1885 v51->spell_target_pid = v44;
1875 pParty->pPlayers[pSpellInfo->uPlayerID].SetRecoveryTime(300); 1886 pParty->pPlayers[v51->uPlayerID].SetRecoveryTime(300);
1876 pGUIWindow_Settings->Release(); 1887 pWindow3 = pGUIWindow_Settings;
1888 pWindow3->Release();
1877 pGUIWindow_Settings = 0; 1889 pGUIWindow_Settings = 0;
1878 pMouse->SetCursorBitmap("MICON1"); 1890 pMouse->SetCursorBitmap("MICON1");
1879 GameUI_Footer_TimeLeft = 0; 1891 GameUI_Footer_TimeLeft = 0;
1880 unk_50C9A0 = 0; 1892 unk_50C9A0 = 0;
1881 back_to_game(); 1893 back_to_game();
1882 continue; 1894 continue;
1883 case UIMSG_CastSpell_Character_Big_Improvement://Preservation and blessing, treatment paralysis, hand hammers(individual upgrade),regeneration 1895 case UIMSG_CastSpell_8F:
1884 case UIMSG_CastSpell_Character_Small_Improvement://Fate, cure 1896 __debugbreak();
1885 case UIMSG_HiredNPC_CastSpell: 1897 case UIMSG_CastSpell_SPIRIT_Preservation://and blessing, treatment paralysis, hand hammers(individual upgrade)
1898 case UIMSG_CastSpell_SPIRIT_Fate:
1886 if ( pMessageQueue_50CBD0->uNumMessages ) 1899 if ( pMessageQueue_50CBD0->uNumMessages )
1887 pMessageQueue_50CBD0->uNumMessages = pMessageQueue_50CBD0->pMessages[0].field_8 != 0; 1900 pMessageQueue_50CBD0->uNumMessages = pMessageQueue_50CBD0->pMessages[0].field_8 != 0;
1888 if ( unk_50C9A0 ) 1901 if ( unk_50C9A0 )
1889 { 1902 {
1890 uActiveCharacter = uMessageParam; 1903 uActiveCharacter = uMessageParam;
1892 } 1905 }
1893 else 1906 else
1894 { 1907 {
1895 if ( pGUIWindow_Settings ) 1908 if ( pGUIWindow_Settings )
1896 { 1909 {
1897 pSpellInfo = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C; 1910 v51 = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C;
1898 switch ( uMessage ) 1911 switch ( uMessage )
1899 { 1912 {
1900 case UIMSG_CastSpell_Character_Big_Improvement: 1913 case UIMSG_CastSpell_SPIRIT_Preservation:
1901 LOBYTE(pSpellInfo->field_8) &= 0xFDu; 1914 LOBYTE(v51->field_8) &= 0xFDu;
1902 break; 1915 break;
1903 case UIMSG_CastSpell_Character_Small_Improvement: 1916 case UIMSG_CastSpell_SPIRIT_Fate:
1904 HIBYTE(pSpellInfo->field_8) &= 0xFEu; 1917 HIBYTE(v51->field_8) &= 0xFEu;
1905 break; 1918 break;
1906 case UIMSG_HiredNPC_CastSpell: 1919 case UIMSG_CastSpell_8F:
1907 HIBYTE(pSpellInfo->field_8) &= 0xFDu; 1920 HIBYTE(v51->field_8) &= 0xFDu;
1908 break; 1921 break;
1909 } 1922 }
1910 pSpellInfo->uPlayerID_2 = uMessageParam; 1923 v51->uPlayerID_2 = uMessageParam;
1911 pParty->pPlayers[pSpellInfo->uPlayerID].SetRecoveryTime(300); 1924 pParty->pPlayers[v51->uPlayerID].SetRecoveryTime(300);
1912 pGUIWindow_Settings->Release(); 1925 pGUIWindow_Settings->Release();
1913 pGUIWindow_Settings = 0; 1926 pGUIWindow_Settings = 0;
1914 pEventTimer->Resume(); 1927 pEventTimer->Resume();
1915 pMouse->SetCursorBitmap("MICON1"); 1928 pMouse->SetCursorBitmap("MICON1");
1916 GameUI_Footer_TimeLeft = 0; 1929 GameUI_Footer_TimeLeft = 0;
1978 { 1991 {
1979 if ( !*((int *)&pSavegameThumbnails->pPixels + 10 * uMessageParam) ) 1992 if ( !*((int *)&pSavegameThumbnails->pPixels + 10 * uMessageParam) )
1980 continue; 1993 continue;
1981 v173 = pMapStats->pInfos[sub_410D99_get_map_index(HIWORD(pPlayer->pInstalledBeacons[uMessageParam].field_18))].pName; 1994 v173 = pMapStats->pInfos[sub_410D99_get_map_index(HIWORD(pPlayer->pInstalledBeacons[uMessageParam].field_18))].pName;
1982 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[474], v173);// "Recall to %s" 1995 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[474], v173);// "Recall to %s"
1983 sub_41C0B8_set_status_string(pTmpBuf); 1996 GameUI_SetFooterString(pTmpBuf);
1984 continue; 1997 continue;
1985 } 1998 }
1986 v59 = pMapStats->GetMapInfo(pCurrentMapName); 1999 v59 = pMapStats->GetMapInfo(pCurrentMapName);
1987 thise = "Not in Map Stats"; 2000 thise = "Not in Map Stats";
1988 if ( v59 ) 2001 if ( v59 )
1989 thise = pMapStats->pInfos[v59].pName; 2002 thise = pMapStats->pInfos[v59].pName;
1990 if ( !*((int *)&pSavegameThumbnails->pPixels + 10 * uMessageParam) || !v59 ) 2003 if ( !*((int *)&pSavegameThumbnails->pPixels + 10 * uMessageParam) || !v59 )
1991 { 2004 {
1992 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[476], thise);// "Set to %s" 2005 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[476], thise);// "Set to %s"
1993 sub_41C0B8_set_status_string(pTmpBuf); 2006 GameUI_SetFooterString(pTmpBuf);
1994 continue; 2007 continue;
1995 } 2008 }
1996 v174 = pMapStats->pInfos[sub_410D99_get_map_index(*(short *)(uNumSeconds + 26))].pName; 2009 v174 = pMapStats->pInfos[sub_410D99_get_map_index(*(short *)(uNumSeconds + 26))].pName;
1997 v158 = (unsigned int)thise; 2010 v158 = (unsigned int)thise;
1998 sprintf(pTmpBuf, pGlobalTXT_LocalizationStrings[475], v158, v174);// "Set %s over %s" 2011 sprintf(pTmpBuf, pGlobalTXT_LocalizationStrings[475], v158, v174);// "Set %s over %s"
1999 sub_41C0B8_set_status_string(pTmpBuf); 2012 GameUI_SetFooterString(pTmpBuf);
2000 continue; 2013 continue;
2001 case UIMSG_CloseAfterInstallBeacon: 2014 case UIMSG_CloseAfterInstallBeacon:
2002 dword_50CDC8 = 1; 2015 dword_50CDC8 = 1;
2003 pMessageQueue_50CBD0->AddMessage(UIMSG_Escape, 0, 0); 2016 pMessageQueue_50CBD0->AddMessage(UIMSG_Escape, 0, 0);
2004 /*if ( (signed int)pMessageQueue_50CBD0->uNumMessages >= 40 ) 2017 /*if ( (signed int)pMessageQueue_50CBD0->uNumMessages >= 40 )
2209 break; 2222 break;
2210 default: 2223 default:
2211 if ( uMessageParam != 5 ) 2224 if ( uMessageParam != 5 )
2212 { 2225 {
2213 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[35], v200); 2226 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[35], v200);
2214 sub_41C0B8_set_status_string(pTmpBuf); 2227 GameUI_SetFooterString(pTmpBuf);
2215 continue; 2228 continue;
2216 } 2229 }
2217 v69 = pMapStats->pInfos[8].pName; 2230 v69 = pMapStats->pInfos[8].pName;
2218 break; 2231 break;
2219 } 2232 }
2221 else 2234 else
2222 { 2235 {
2223 v69 = pMapStats->pInfos[21].pName; 2236 v69 = pMapStats->pInfos[21].pName;
2224 } 2237 }
2225 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[35], v69); 2238 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[35], v69);
2226 sub_41C0B8_set_status_string(pTmpBuf); 2239 GameUI_SetFooterString(pTmpBuf);
2227 continue; 2240 continue;
2228 } 2241 }
2229 v68 = 210; 2242 v68 = 210;
2230 break; 2243 break;
2231 } 2244 }
2259 default: 2272 default:
2260 if ( uMessageParam != 5 ) 2273 if ( uMessageParam != 5 )
2261 //goto LABEL_519; 2274 //goto LABEL_519;
2262 { 2275 {
2263 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[35], v200); 2276 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[35], v200);
2264 sub_41C0B8_set_status_string(pTmpBuf); 2277 GameUI_SetFooterString(pTmpBuf);
2265 continue; 2278 continue;
2266 } 2279 }
2267 v69 = pMapStats->pInfos[8].pName; 2280 v69 = pMapStats->pInfos[8].pName;
2268 break; 2281 break;
2269 } 2282 }
2271 else 2284 else
2272 { 2285 {
2273 v69 = pMapStats->pInfos[21].pName; 2286 v69 = pMapStats->pInfos[21].pName;
2274 } 2287 }
2275 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[35], v69); 2288 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[35], v69);
2276 sub_41C0B8_set_status_string(pTmpBuf); 2289 GameUI_SetFooterString(pTmpBuf);
2277 continue; 2290 continue;
2278 case UIMSG_ShowFinalWindow: 2291 case UIMSG_ShowFinalWindow:
2279 sprintf(pFinalMessage, "%s\n \n%s\n \n%s", pGlobalTXT_LocalizationStrings[151],// "Congratulations Adventurer." 2292 sprintf(pFinalMessage, "%s\n \n%s\n \n%s", pGlobalTXT_LocalizationStrings[151],// "Congratulations Adventurer."
2280 pGlobalTXT_LocalizationStrings[118],// "We hope that you've enjoyed playing Might and Magic VII as much as we did making it. We have saved this screen as MM7_WIN.PCX in your MM7 directory. You can print it out as proof of your accomplishment." 2293 pGlobalTXT_LocalizationStrings[118],// "We hope that you've enjoyed playing Might and Magic VII as much as we did making it. We have saved this screen as MM7_WIN.PCX in your MM7 directory. You can print it out as proof of your accomplishment."
2281 pGlobalTXT_LocalizationStrings[167]);// "- The Might and Magic VII Development Team." 2294 pGlobalTXT_LocalizationStrings[167]);// "- The Might and Magic VII Development Team."
2390 v1 = ""; 2403 v1 = "";
2391 continue; 2404 continue;
2392 } 2405 }
2393 _42777D_CastSpell_UseWand_ShootArrow(pPlayer2->uQuickSpell, uActiveCharacter - 1, 0, 0, uActiveCharacter); 2406 _42777D_CastSpell_UseWand_ShootArrow(pPlayer2->uQuickSpell, uActiveCharacter - 1, 0, 0, uActiveCharacter);
2394 continue; 2407 continue;
2395 case UIMSG_CastSpell_Monster_Improvement://Fate, cure 2408 case UIMSG_CastSpell_GreatShot://???
2396 case UIMSG_CastSpell_Shoot_Monster://FireBlow, Lightning, Ice Lightning, Swarm, 2409 __debugbreak();
2410 case UIMSG_CastSpell_SmallShot://FireBlow, Lightning, Ice Lightning, Swarm,
2397 if ( pRenderer->pRenderD3D ) 2411 if ( pRenderer->pRenderD3D )
2398 { 2412 {
2399 v81 = pGame->pVisInstance->get_picked_object_zbuf_val(); 2413 v81 = pGame->pVisInstance->get_picked_object_zbuf_val();
2400 } 2414 }
2401 else 2415 else
2410 if ( PID_TYPE(v44) != 3 || v84 >= 5120 ) 2424 if ( PID_TYPE(v44) != 3 || v84 >= 5120 )
2411 { 2425 {
2412 v1 = ""; 2426 v1 = "";
2413 continue; 2427 continue;
2414 } 2428 }
2415 pSpellInfo = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C; 2429 v51 = (CastSpellInfo *)pGUIWindow_Settings->ptr_1C;
2416 if ( uMessage == UIMSG_CastSpell_Shoot_Monster ) 2430 if ( uMessage == UIMSG_CastSpell_SmallShot )
2417 { 2431 {
2418 LOBYTE(pSpellInfo->field_8) &= 0xF7; 2432 LOBYTE(v51->field_8) &= 0xF7;
2419 } 2433 }
2420 else 2434 else
2421 { 2435 {
2422 if ( uMessage == UIMSG_CastSpell_Monster_Improvement ) 2436 if ( uMessage == UIMSG_CastSpell_GreatShot )
2423 HIBYTE(pSpellInfo->field_8) &= 0xFEu; 2437 HIBYTE(v51->field_8) &= 0xFEu;
2424 else 2438 else
2425 HIBYTE(pSpellInfo->field_8) &= 0xFDu; 2439 HIBYTE(v51->field_8) &= 0xFDu;
2426 } 2440 }
2427 pSpellInfo->uPlayerID_2 = uMessageParam; 2441 v51->uPlayerID_2 = uMessageParam;
2428 pSpellInfo->spell_target_pid = v44; 2442 v51->spell_target_pid = v44;
2429 pParty->pPlayers[pSpellInfo->uPlayerID].SetRecoveryTime(300); 2443 pParty->pPlayers[v51->uPlayerID].SetRecoveryTime(300);
2430 pGUIWindow_Settings->Release(); 2444 pWindow3 = pGUIWindow_Settings;
2445 pWindow3->Release();
2431 pGUIWindow_Settings = 0; 2446 pGUIWindow_Settings = 0;
2432 pMouse->SetCursorBitmap("MICON1"); 2447 pMouse->SetCursorBitmap("MICON1");
2433 GameUI_Footer_TimeLeft = 0; 2448 GameUI_Footer_TimeLeft = 0;
2434 unk_50C9A0 = 0; 2449 unk_50C9A0 = 0;
2435 back_to_game(); 2450 back_to_game();
2677 v177 = pGlobalTXT_LocalizationStrings[584];// "Click here to remove your Quick Spell" 2692 v177 = pGlobalTXT_LocalizationStrings[584];// "Click here to remove your Quick Spell"
2678 else 2693 else
2679 v177 = pGlobalTXT_LocalizationStrings[484];// "Select a spell then click here to set a QuickSpell" 2694 v177 = pGlobalTXT_LocalizationStrings[484];// "Select a spell then click here to set a QuickSpell"
2680 strcpy(pTmpBuf, v177); 2695 strcpy(pTmpBuf, v177);
2681 } 2696 }
2682 sub_41C0B8_set_status_string(pTmpBuf); 2697 GameUI_SetFooterString(pTmpBuf);
2683 continue; 2698 continue;
2684 case UIMSG_SPellbook_ShowHightlightedSpellInfo: 2699 case UIMSG_SPellbook_ShowHightlightedSpellInfo:
2685 if ( !uActiveCharacter || (uNumSeconds = (unsigned int)pPlayers[uActiveCharacter], 2700 if ( !uActiveCharacter || (uNumSeconds = (unsigned int)pPlayers[uActiveCharacter],
2686 !*(char *)(uNumSeconds + 11 * *(char *)(uNumSeconds + 6734) + uMessageParam + 402)) ) 2701 !*(char *)(uNumSeconds + 11 * *(char *)(uNumSeconds + 6734) + uMessageParam + 402)) )
2687 continue; 2702 continue;
2697 { 2712 {
2698 v178 = pSpellStats->pInfos[uMessageParam + 11 * v98 + 1].pName; 2713 v178 = pSpellStats->pInfos[uMessageParam + 11 * v98 + 1].pName;
2699 v161 = pGlobalTXT_LocalizationStrings[486]; 2714 v161 = pGlobalTXT_LocalizationStrings[486];
2700 } 2715 }
2701 sprintfex(pTmpBuf, v161, v178); 2716 sprintfex(pTmpBuf, v161, v178);
2702 sub_41C0B8_set_status_string(pTmpBuf); 2717 GameUI_SetFooterString(pTmpBuf);
2703 continue; 2718 continue;
2704 case UIMSG_ClickInstallRemoveQuickSpellBtn: 2719 case UIMSG_ClickInstallRemoveQuickSpellBtn:
2705 GUIWindow::Create(pBtn_InstallRemoveSpell->uX, pBtn_InstallRemoveSpell->uY, 0, 0, WINDOW_PressedButton2, (int)pBtn_InstallRemoveSpell, 0); 2720 GUIWindow::Create(pBtn_InstallRemoveSpell->uX, pBtn_InstallRemoveSpell->uY, 0, 0, WINDOW_PressedButton2, (int)pBtn_InstallRemoveSpell, 0);
2706 if ( !uActiveCharacter ) 2721 if ( !uActiveCharacter )
2707 continue; 2722 continue;
2794 pEventTimer->Resume(); 2809 pEventTimer->Resume();
2795 viewparams->bRedrawGameUI = 1; 2810 viewparams->bRedrawGameUI = 1;
2796 pCurrentScreen = SCREEN_GAME; 2811 pCurrentScreen = SCREEN_GAME;
2797 pIcons_LOD->_4114F2(); 2812 pIcons_LOD->_4114F2();
2798 v103 = quick_spell_at_page + 11 * player->lastOpenedSpellbookPage; 2813 v103 = quick_spell_at_page + 11 * player->lastOpenedSpellbookPage;
2799 /*if ( dword_50C9E8 < 40 ) 2814 if ( dword_50C9E8 < 40 )
2800 { 2815 {
2801 dword_50C9EC[3 * dword_50C9E8] = UIMSG_CastSpellFromBook; 2816 dword_50C9EC[3 * dword_50C9E8] = UIMSG_CastSpellFromBook;
2802 dword_50C9EC[3 * dword_50C9E8 + 1] = v103; 2817 dword_50C9EC[3 * dword_50C9E8 + 1] = v103;
2803 dword_50C9EC[3 * dword_50C9E8 + 2] = uActiveCharacter - 1; 2818 dword_50C9EC[3 * dword_50C9E8 + 2] = uActiveCharacter - 1;
2804 ++dword_50C9E8; 2819 ++dword_50C9E8;
2805 }*/ 2820 }
2806 pMessageQueue_50CBD0->AddMessage(UIMSG_CastSpellFromBook, v103, uActiveCharacter - 1);
2807 } 2821 }
2808 else 2822 else
2809 { 2823 {
2810 byte_506550 = 1; 2824 byte_506550 = 1;
2811 quick_spell_at_page = uMessageParam + 1; 2825 quick_spell_at_page = uMessageParam + 1;
3000 sub_419220(); 3014 sub_419220();
3001 pWindowList_at_506F50_minus1_indexing_buttons____and_an_int_[0] = 102; 3015 pWindowList_at_506F50_minus1_indexing_buttons____and_an_int_[0] = 102;
3002 GUIWindow::Create(pCharacterScreen_AwardsBtn->uX, pCharacterScreen_AwardsBtn->uY, 0, 0, WINDOW_CharactersPressedButton, (int)pCharacterScreen_AwardsBtn, 0); 3016 GUIWindow::Create(pCharacterScreen_AwardsBtn->uX, pCharacterScreen_AwardsBtn->uY, 0, 0, WINDOW_CharactersPressedButton, (int)pCharacterScreen_AwardsBtn, 0);
3003 FillAwardsData(); 3017 FillAwardsData();
3004 continue; 3018 continue;
3005 case UIMSG_ClickBooksBtn: 3019 case UIMSG_AutonotesBook:// ( )
3006 switch ( uMessageParam ) 3020 switch ( uMessageParam )
3007 { 3021 {
3008 case 11://Page UP 3022 case 11://Page UP
3009 BtnUp_flag = 1; 3023 BtnUp_flag = 1;
3010 pButton = pBtn_Book_2; 3024 pButton = pBtn_Book_2;
3011 break; 3025 break;
3012 case 10://Page DOWN 3026 case 10://Page DOWN
3013 BtnDown_flag = 1; 3027 BtnDown_flag = 1;
3014 pButton = pBtn_Book_1; 3028 pButton = pBtn_Book_1;
3015 break; 3029 break;
3016 case 0://Zoom plus 3030 case 0:
3017 pButton = pBtn_Book_1; 3031 pButton = pBtn_Book_1;
3018 BtnDown_flag = 1; 3032 BtnDown_flag = 1;
3019 break; 3033 break;
3020 case 1://Zoom minus 3034 case 1:
3021 pButton = pBtn_Book_2; 3035 pButton = pBtn_Book_2;// MapsBook
3022 BtnUp_flag = 1; 3036 BtnUp_flag = 1;
3023 break; 3037 break;
3024 case 2://Potions 3038 case 2://Potions
3025 Book_PageBtn3_flag = 1; 3039 Book_PageBtn3_flag = 1;
3026 if ( dword_506364 ) 3040 if ( dword_506364 )
3065 continue; 3079 continue;
3066 case UIMSG_ShowStatus_Funds: 3080 case UIMSG_ShowStatus_Funds:
3067 v174 = (char *)pParty->uNumGoldInBank; 3081 v174 = (char *)pParty->uNumGoldInBank;
3068 v158 = pParty->uNumGold + pParty->uNumGoldInBank; 3082 v158 = pParty->uNumGold + pParty->uNumGoldInBank;
3069 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[489], v158, v174);// "You have %d total gold, %d in the Bank" 3083 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[489], v158, v174);// "You have %d total gold, %d in the Bank"
3070 sub_41C0B8_set_status_string(pTmpBuf); 3084 GameUI_SetFooterString(pTmpBuf);
3071 continue; 3085 continue;
3072 case UIMSG_ShowStatus_DateTime: 3086 case UIMSG_ShowStatus_DateTime:
3073 pNPCData4 = (NPCData *)pParty->uCurrentHour; 3087 pNPCData4 = (NPCData *)pParty->uCurrentHour;
3074 if ( (signed int)pParty->uCurrentHour <= 12 ) 3088 if ( (signed int)pParty->uCurrentHour <= 12 )
3075 { 3089 {
3082 } 3096 }
3083 if ( pParty->uCurrentHour < 0xC || (uNumSeconds = 1, pParty->uCurrentHour >= 0x18) ) 3097 if ( pParty->uCurrentHour < 0xC || (uNumSeconds = 1, pParty->uCurrentHour >= 0x18) )
3084 uNumSeconds = 0; 3098 uNumSeconds = 0;
3085 sprintf(pTmpBuf, "%d:%02d%s %s %d %s %d", pNPCData4, pParty->uCurrentMinute, aAMPMNames[uNumSeconds], aDayNames[pParty->uDaysPlayed % 7], 3099 sprintf(pTmpBuf, "%d:%02d%s %s %d %s %d", pNPCData4, pParty->uCurrentMinute, aAMPMNames[uNumSeconds], aDayNames[pParty->uDaysPlayed % 7],
3086 7 * pParty->uCurrentMonthWeek + pParty->uDaysPlayed % 7 + 1, aMonthNames[pParty->uCurrentMonth], pParty->uCurrentYear); 3100 7 * pParty->uCurrentMonthWeek + pParty->uDaysPlayed % 7 + 1, aMonthNames[pParty->uCurrentMonth], pParty->uCurrentYear);
3087 sub_41C0B8_set_status_string(pTmpBuf); 3101 GameUI_SetFooterString(pTmpBuf);
3088 continue; 3102 continue;
3089 case UIMSG_ShowStatus_Food: 3103 case UIMSG_ShowStatus_Food:
3090 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[501], pParty->uNumFoodRations); // "You have %lu food" 3104 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[501], pParty->uNumFoodRations); // "You have %lu food"
3091 sub_41C0B8_set_status_string(pTmpBuf); 3105 GameUI_SetFooterString(pTmpBuf);
3092 continue; 3106 continue;
3093 case UIMSG_ShowStatus_Player: 3107 case UIMSG_ShowStatus_Player:
3094 pPlayer5 = pPlayers[uMessageParam]; 3108 pPlayer5 = pPlayers[uMessageParam];
3095 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[429], pPlayer5->pName, pClassNames[pPlayer5->classType]);// "%s the %s" 3109 sprintfex(pTmpBuf, pGlobalTXT_LocalizationStrings[429], pPlayer5->pName, pClassNames[pPlayer5->classType]);// "%s the %s"
3096 strcat(pTmpBuf, ": "); 3110 strcat(pTmpBuf, ": ");
3097 v107 = pPlayer5->GetMajorConditionIdx(); 3111 v107 = pPlayer5->GetMajorConditionIdx();
3098 strcat(pTmpBuf, aCharacterConditionNames[v107]); 3112 strcat(pTmpBuf, aCharacterConditionNames[v107]);
3099 sub_41C0B8_set_status_string(pTmpBuf); 3113 GameUI_SetFooterString(pTmpBuf);
3100 v108 = 8 * uMessageParam - 8; 3114 v108 = 8 * uMessageParam - 8;
3101 LOBYTE(v108) = v108 | 4; 3115 LOBYTE(v108) = v108 | 4;
3102 pMouse->uPointingObjectID = PID(OBJECT_Player,v108); 3116 pMouse->uPointingObjectID = PID(OBJECT_Player,v108);
3103 continue; 3117 continue;
3104 case UIMSG_ShowStatus_ManaHP: 3118 case UIMSG_ShowStatus_ManaHP:
3105 sprintf(pTmpBuf, "%d / %d %s %d / %d %s", pPlayers[uMessageParam]->sHealth, pPlayers[uMessageParam]->GetMaxHealth(), 3119 v109 = pGlobalTXT_LocalizationStrings[212];// "Spell Points"
3106 pGlobalTXT_LocalizationStrings[108], pPlayers[uMessageParam]->sMana, pPlayers[uMessageParam]->GetMaxMana(), 3120 v110 = pPlayers[uMessageParam];
3107 pGlobalTXT_LocalizationStrings[212]); 3121 v111 = v110->GetMaxMana();
3108 sub_41C0B8_set_status_string(pTmpBuf); 3122 v112 = v110->sMana;
3123 v113 = pGlobalTXT_LocalizationStrings[108];// "Hit Points"
3124 v114 = v110->GetMaxHealth();
3125 sprintf(pTmpBuf, "%d / %d %s %d / %d %s", v110->sHealth, v114, v113, v112, v111, v109);
3126 GameUI_SetFooterString(pTmpBuf);
3109 continue; 3127 continue;
3110 case UIMSG_CHEST_ClickItem: 3128 case UIMSG_CHEST_ClickItem:
3111 if ( pCurrentScreen == SCREEN_CHEST_INVENTORY ) 3129 if ( pCurrentScreen == SCREEN_CHEST_INVENTORY )
3112 { 3130 {
3113 OnInventoryLeftClick(); 3131 OnInventoryLeftClick();
3126 OnGameViewportClick(); 3144 OnGameViewportClick();
3127 continue; 3145 continue;
3128 } 3146 }
3129 v115 = pMessageQueue_50CBD0->uNumMessages; 3147 v115 = pMessageQueue_50CBD0->uNumMessages;
3130 if ( !pMessageQueue_50CBD0->uNumMessages ) 3148 if ( !pMessageQueue_50CBD0->uNumMessages )
3149 //goto LABEL_768;
3131 { 3150 {
3132 pMessageQueue_50CBD0->AddMessage(UIMSG_MouseLeftClickInScreen, 0, 0); 3151 pMessageQueue_50CBD0->AddMessage(UIMSG_MouseLeftClickInScreen, 0, 0);
3133 /*if ( (signed int)v115 < 40 ) 3152 /*if ( (signed int)v115 < 40 )
3134 //goto LABEL_769; 3153 //goto LABEL_769;
3135 { 3154 {
3199 continue; 3218 continue;
3200 case UIMSG_ClickZoomOutBtn: 3219 case UIMSG_ClickZoomOutBtn:
3201 if ( pCurrentScreen ) 3220 if ( pCurrentScreen )
3202 continue; 3221 continue;
3203 pParty->uFlags |= 2u; 3222 pParty->uFlags |= 2u;
3204 GUIWindow::Create(519, 136, 0, 0, WINDOW_PressedButton2, (int)pBtn_ZoomOut, 0); 3223 GUIWindow::Create(0x207u, 0x88u, 0, 0, WINDOW_PressedButton2, (int)pBtn_ZoomOut, 0);
3205 uNumSeconds = 131072; 3224 uNumSeconds = 131072;
3206 v118 = 2 * viewparams->uMinimapZoom; 3225 v118 = 2 * viewparams->uMinimapZoom;
3207 ++viewparams->field_28; 3226 ++viewparams->field_28;
3208 viewparams->uMinimapZoom *= 2; 3227 viewparams->uMinimapZoom *= 2;
3209 if ( uCurrentlyLoadedLevelType != LEVEL_Outdoor) 3228 if ( uCurrentlyLoadedLevelType != LEVEL_Outdoor)
3229 break; 3248 break;
3230 case UIMSG_ClickZoomInBtn: 3249 case UIMSG_ClickZoomInBtn:
3231 if ( pCurrentScreen ) 3250 if ( pCurrentScreen )
3232 continue; 3251 continue;
3233 pParty->uFlags |= 2u; 3252 pParty->uFlags |= 2u;
3234 GUIWindow::Create(574, 136, 0, 0, WINDOW_PressedButton2, (int)pBtn_ZoomIn, 0); 3253 GUIWindow::Create(0x23Eu, 0x88u, 0, 0, WINDOW_PressedButton2, (int)pBtn_ZoomIn, 0);
3235 uNumSeconds = 32768; 3254 uNumSeconds = 32768;
3236 v118 = (unsigned __int64)((signed __int64)(signed int)viewparams->uMinimapZoom << 15) >> 16; 3255 v118 = (unsigned __int64)((signed __int64)(signed int)viewparams->uMinimapZoom << 15) >> 16;
3237 --viewparams->field_28; 3256 --viewparams->field_28;
3238 viewparams->uMinimapZoom = (unsigned __int64)((signed __int64)(signed int)viewparams->uMinimapZoom << 15) >> 16; 3257 viewparams->uMinimapZoom = (unsigned __int64)((signed __int64)(signed int)viewparams->uMinimapZoom << 15) >> 16;
3239 if ( uCurrentlyLoadedLevelType == LEVEL_Outdoor) 3258 if ( uCurrentlyLoadedLevelType == LEVEL_Outdoor)
9969 return pGlobalTXT_LocalizationStrings[56]; 9988 return pGlobalTXT_LocalizationStrings[56];
9970 } 9989 }
9971 return pGlobalTXT_LocalizationStrings[567]; 9990 return pGlobalTXT_LocalizationStrings[567];
9972 } 9991 }
9973 9992
9974 //----- (00413D6F) --------------------------------------------------------
9975 char __cdecl DrawBook_Calendar()
9976 {
9977 unsigned int v0; // esi@1
9978 char *v1; // eax@5
9979 int v2; // ecx@5
9980 char *v3; // eax@6
9981 GUIWindow a1; // [sp+Ch] [bp-60h]@5
9982 unsigned int v6; // [sp+60h] [bp-Ch]@1
9983 int v7; // [sp+64h] [bp-8h]@1
9984 int a5; // [sp+68h] [bp-4h]@1
9985
9986 v0 = pParty->uCurrentHour;
9987 v6 = pMapStats->GetMapInfo(pCurrentMapName);
9988 a5 = TargetColor(0x4Bu, 0x4Bu, 0x4Bu);
9989 pRenderer->DrawTextureIndexed(pViewport->uViewportTL_X, pViewport->uViewportTL_Y, pSpellBookPagesTextr_13);
9990 v7 = (unsigned __int8)pDayMoonPhase[pParty->uDaysPlayed];
9991 if ( (signed int)v0 <= 12 )
9992 {
9993 if ( !v0 )
9994 v0 = 12;
9995 }
9996 else
9997 {
9998 v0 -= 12;
9999 }
10000 a1.uFrameX = game_viewport_x;
10001 a1.uFrameY = game_viewport_y;
10002 a1.uFrameWidth = game_viewport_width;
10003 a1.uFrameHeight = game_viewport_height;
10004 a1.uFrameZ = game_viewport_z;
10005 a1.uFrameW = game_viewport_w;
10006 a1.DrawTitleText(pBook2Font, 0, 0x16u, 0, pGlobalTXT_LocalizationStrings[186], 3u);
10007 if ( pParty->uCurrentHour >= 12 )
10008 {
10009 if ( pParty->uCurrentHour >= 24 )
10010 v2=0;
10011 else
10012 v2=1;
10013 }
10014 else
10015 v2=0;
10016 v1 = GetDayPart();
10017 sprintf(
10018 pTmpBuf,
10019 "%s\t100:\t110%d:%02d %s - %s",
10020 pGlobalTXT_LocalizationStrings[526],
10021 v0,
10022 pParty->uCurrentMinute,
10023 aAMPMNames[v2],
10024 v1);
10025 a1.DrawText(pBookFont, 70, 55, a5, pTmpBuf, 0, 0, 0);
10026 sprintf(
10027 pTmpBuf,
10028 "%s\t100:\t110%d - %s",
10029 pGlobalTXT_LocalizationStrings[56],
10030 pParty->uDaysPlayed + 1,
10031 aDayNames[pParty->uDaysPlayed % 7]);
10032 a1.DrawText(pBookFont, 70, 2 * LOBYTE(pBookFont->uFontHeight) + 49, a5, pTmpBuf, 0, 0, 0);
10033 sprintf(
10034 pTmpBuf,
10035 "%s\t100:\t110%d - %s",
10036 pGlobalTXT_LocalizationStrings[146],
10037 pParty->uCurrentMonth + 1,
10038 aMonthNames[pParty->uCurrentMonth]);
10039 a1.DrawText(pBookFont, 70, 4 * LOBYTE(pBookFont->uFontHeight) + 43, a5, pTmpBuf, 0, 0, 0);
10040 sprintf(pTmpBuf, "%s\t100:\t110%d", pGlobalTXT_LocalizationStrings[245], pParty->uCurrentYear);
10041 a1.DrawText(pBookFont, 70, 6 * LOBYTE(pBookFont->uFontHeight) + 37, a5, pTmpBuf, 0, 0, 0);
10042 sprintf(pTmpBuf, "%s\t100:\t110%s", pGlobalTXT_LocalizationStrings[530], aMoonPhaseNames[v7]);
10043 a1.DrawText(pBookFont, 70, 8 * LOBYTE(pBookFont->uFontHeight) + 31, a5, pTmpBuf, 0, 0, 0);
10044 if ( v6 )
10045 v3 = pMapStats->pInfos[v6].pName;
10046 else
10047 v3 = "Unknown";
10048 sprintf(pTmpBuf, "%s\t100:\t110%s", pGlobalTXT_LocalizationStrings[531], v3);
10049 return a1.DrawText(pBookFont, 70, 10 * LOBYTE(pBookFont->uFontHeight) + 25, a5, pTmpBuf, 0, 0, 0);
10050 }
10051
10052 //----- (00413FF1) -------------------------------------------------------- 9993 //----- (00413FF1) --------------------------------------------------------
10053 void __cdecl SetMonthNames() 9994 void SetMonthNames()
10054 { 9995 {
10055 aMonthNames[0] = pGlobalTXT_LocalizationStrings[415]; 9996 aMonthNames[0] = pGlobalTXT_LocalizationStrings[415];
10056 aMonthNames[1] = pGlobalTXT_LocalizationStrings[416]; 9997 aMonthNames[1] = pGlobalTXT_LocalizationStrings[416];
10057 aMonthNames[2] = pGlobalTXT_LocalizationStrings[417]; 9998 aMonthNames[2] = pGlobalTXT_LocalizationStrings[417];
10058 aMonthNames[3] = pGlobalTXT_LocalizationStrings[418]; 9999 aMonthNames[3] = pGlobalTXT_LocalizationStrings[418];
10065 aMonthNames[10] = pGlobalTXT_LocalizationStrings[425]; 10006 aMonthNames[10] = pGlobalTXT_LocalizationStrings[425];
10066 aMonthNames[11] = pGlobalTXT_LocalizationStrings[426]; 10007 aMonthNames[11] = pGlobalTXT_LocalizationStrings[426];
10067 } 10008 }
10068 10009
10069 //----- (0041406F) -------------------------------------------------------- 10010 //----- (0041406F) --------------------------------------------------------
10070 void __cdecl SetDayNames() 10011 void SetDayNames()
10071 { 10012 {
10072 aDayNames[0] = pGlobalTXT_LocalizationStrings[145]; 10013 aDayNames[0] = pGlobalTXT_LocalizationStrings[145];
10073 aDayNames[1] = pGlobalTXT_LocalizationStrings[230]; 10014 aDayNames[1] = pGlobalTXT_LocalizationStrings[230];
10074 aDayNames[2] = pGlobalTXT_LocalizationStrings[243]; 10015 aDayNames[2] = pGlobalTXT_LocalizationStrings[243];
10075 aDayNames[3] = pGlobalTXT_LocalizationStrings[227]; 10016 aDayNames[3] = pGlobalTXT_LocalizationStrings[227];
10077 aDayNames[5] = pGlobalTXT_LocalizationStrings[188]; 10018 aDayNames[5] = pGlobalTXT_LocalizationStrings[188];
10078 aDayNames[6] = pGlobalTXT_LocalizationStrings[222]; 10019 aDayNames[6] = pGlobalTXT_LocalizationStrings[222];
10079 } 10020 }
10080 10021
10081 //----- (004140BB) -------------------------------------------------------- 10022 //----- (004140BB) --------------------------------------------------------
10082 void __cdecl SetSpellSchoolNames() 10023 void SetSpellSchoolNames()
10083 { 10024 {
10084 aSpellSchoolNames[0] = pGlobalTXT_LocalizationStrings[87]; 10025 aSpellSchoolNames[0] = pGlobalTXT_LocalizationStrings[87];
10085 aSpellSchoolNames[1] = pGlobalTXT_LocalizationStrings[6]; 10026 aSpellSchoolNames[1] = pGlobalTXT_LocalizationStrings[6];
10086 aSpellSchoolNames[2] = pGlobalTXT_LocalizationStrings[240]; 10027 aSpellSchoolNames[2] = pGlobalTXT_LocalizationStrings[240];
10087 aSpellSchoolNames[3] = pGlobalTXT_LocalizationStrings[70]; 10028 aSpellSchoolNames[3] = pGlobalTXT_LocalizationStrings[70];
10091 aSpellSchoolNames[7] = pGlobalTXT_LocalizationStrings[133]; 10032 aSpellSchoolNames[7] = pGlobalTXT_LocalizationStrings[133];
10092 aSpellSchoolNames[8] = pGlobalTXT_LocalizationStrings[54]; 10033 aSpellSchoolNames[8] = pGlobalTXT_LocalizationStrings[54];
10093 } 10034 }
10094 10035
10095 //----- (0041411B) -------------------------------------------------------- 10036 //----- (0041411B) --------------------------------------------------------
10096 void __cdecl SetAttributeNames() 10037 void SetAttributeNames()
10097 { 10038 {
10098 aAttributeNames[0] = pGlobalTXT_LocalizationStrings[144]; 10039 aAttributeNames[0] = pGlobalTXT_LocalizationStrings[144];
10099 aAttributeNames[1] = pGlobalTXT_LocalizationStrings[116]; 10040 aAttributeNames[1] = pGlobalTXT_LocalizationStrings[116];
10100 aAttributeNames[2] = pGlobalTXT_LocalizationStrings[163]; 10041 aAttributeNames[2] = pGlobalTXT_LocalizationStrings[163];
10101 aAttributeNames[3] = pGlobalTXT_LocalizationStrings[75]; 10042 aAttributeNames[3] = pGlobalTXT_LocalizationStrings[75];
10103 aAttributeNames[5] = pGlobalTXT_LocalizationStrings[211]; 10044 aAttributeNames[5] = pGlobalTXT_LocalizationStrings[211];
10104 aAttributeNames[6] = pGlobalTXT_LocalizationStrings[136]; 10045 aAttributeNames[6] = pGlobalTXT_LocalizationStrings[136];
10105 } 10046 }
10106 10047
10107 //----- (00414162) -------------------------------------------------------- 10048 //----- (00414162) --------------------------------------------------------
10108 void __cdecl uGameUIFontMain_initialize() 10049 void uGameUIFontMain_initialize()
10109 { 10050 {
10110 uGameUIFontMain = TargetColor(0xAu, 0, 0); 10051 uGameUIFontMain = TargetColor(0xAu, 0, 0);
10111 } 10052 }
10112 10053
10113 //----- (00414174) -------------------------------------------------------- 10054 //----- (00414174) --------------------------------------------------------
10114 void __cdecl uGameUIFontShadow_initialize() 10055 void uGameUIFontShadow_initialize()
10115 { 10056 {
10116 uGameUIFontShadow = TargetColor(0xE6u, 214u, 193u); 10057 uGameUIFontShadow = TargetColor(0xE6u, 214u, 193u);
10117 } 10058 }
10118 10059
10119 10060
10255 DrawGameOptions(); 10196 DrawGameOptions();
10256 continue; 10197 continue;
10257 } 10198 }
10258 case WINDOW_Book: 10199 case WINDOW_Book:
10259 { 10200 {
10260 DrawCurrentBook((unsigned int)pWindow->ptr_1C); 10201 BookUI_Draw((WindowType)(int)pWindow->ptr_1C);
10261 continue; 10202 continue;
10262 } 10203 }
10263 case WINDOW_Dialogue: 10204 case WINDOW_Dialogue:
10264 { 10205 {
10265 DrawDialogueUI(); 10206 DrawDialogueUI();