diff GUIWindow.cpp @ 1004:eac5af72b614

UI cleans
author Nomad
date Thu, 16 May 2013 15:14:58 +0200
parents dcdfbb6eede9
children e865f349aa41
line wrap: on
line diff
--- a/GUIWindow.cpp	Tue May 14 23:16:10 2013 +0600
+++ b/GUIWindow.cpp	Thu May 16 15:14:58 2013 +0200
@@ -254,126 +254,6 @@
 }
 
 
-//----- (0041D3B7) --------------------------------------------------------
-void GUIWindow::DrawQuickCharRecord()
-    {
-  Player *pPlayer; // esi@1
-  int v6; // eax@5
-  int v7; // ebx@5
-  unsigned int v8; // ecx@5
-  int v9; // ebx@5
-  unsigned int v10; // eax@5
-  int v11; // eax@5
-  unsigned int v12; // ecx@5
-  Texture *v13; // eax@6
-  unsigned int v14; // eax@12
-  PlayerFrame *v15; // eax@12
-  unsigned int v16; // eax@15
-  unsigned int v20; // eax@15
-  unsigned int v24; // eax@15
-  unsigned int v25; // eax@15
-  unsigned __int8 v28; // al@15
-  char *v29; // eax@16
-  __int64 v35; // ST38_8@22
-  int v36; // esi@22
-  unsigned int v38; // eax@22
-  char *v39; // eax@24
-  signed int uFramesetID; // [sp+20h] [bp-8h]@9
-  int uFramesetIDa; // [sp+20h] [bp-8h]@18
-
-  pPlayer = &pParty->pPlayers[(unsigned int)ptr_1C];
-
-  uint numActivePlayerBuffs = 0;
-
-  for (uint i = 0; i < 24; ++i)
-    if (pPlayer->pPlayerBuffs[i].uExpireTime > 0)
-      ++numActivePlayerBuffs;
-
-  v6 = pFontArrus->uFontHeight + 162;
-  uFrameHeight = v6;
-  v7 = (numActivePlayerBuffs - 1) * pFontArrus->uFontHeight;
-  v8 = uFrameX;
-  v9 = v6 + v7;
-  v10 = uFrameWidth;
-  uFrameHeight = v9;
-  v11 = v10 + v8 - 1;
-  v12 = uFrameY;
-  uFrameZ = v11;
-  uFrameW = v9 + v12 - 1;
-  DrawMessageBox(0);
-  if (pPlayer->Eradicated())
-    v13 = pTexture_PlayerFaceEradicated;
-  else if (pPlayer->Dead())
-    v13 = pTexture_PlayerFaceDead;
-  else
-  {
-      uFramesetID = pPlayerFrameTable->GetFrameIdByExpression(pPlayer->expression);
-      if ( !uFramesetID )
-        uFramesetID = 1;
-      if ( pPlayer->expression == CHARACTER_EXPRESSION_21)
-      {
-        v15 = pPlayerFrameTable->GetFrameBy_y(&pPlayer->_expression21_frameset, &pPlayer->_expression21_animtime, pMiscTimer->uTimeElapsed);
-      }
-      else
-      {
-        v14 = pMiscTimer->Time();
-        v15 = pPlayerFrameTable->GetFrameBy_x(uFramesetID, v14);
-      }
-      pPlayer->field_1AA2 = v15->uTextureID - 1;
-      v13 = pTextures_PlayerFaces[(unsigned int)ptr_1C][v15->uTextureID-1];
-  }
-
-  pRenderer->DrawTextureTransparent(uFrameX + 24, uFrameY + 24, v13);
-  v16 = TargetColor(0xFFu, 0xFFu, 0x9Bu);
-  sprintf(pTmpBuf, "\f%05d", v16);
-  sprintfex(pTmpBuf2, pGlobalTXT_LocalizationStrings[429], pPlayer->pName, pClassNames[pPlayer->classType]);
-  strcat(pTmpBuf, pTmpBuf2);
-  strcat(pTmpBuf, "\f00000\n");
-  v20 = UI_GetHealthManaStringColor(pPlayer->sHealth, pPlayer->GetMaxHealth());
-  sprintf(pTmpBuf2, "%s : \f%05u%d\f00000 / %d\n", pGlobalTXT_LocalizationStrings[108],
-          v20, pPlayer->sHealth, pPlayer->GetMaxHealth());
-  strcat(pTmpBuf, pTmpBuf2);
-  v24 = UI_GetHealthManaStringColor(pPlayer->sMana, pPlayer->GetMaxMana());
-  sprintf(pTmpBuf2, "%s : \f%05u%d\f00000 / %d\n", pGlobalTXT_LocalizationStrings[212],
-          v24, pPlayer->sMana, pPlayer->GetMaxMana());
-  strcat(pTmpBuf, pTmpBuf2);
-  v25 = pPlayer->GetMajorConditionIdx();
-  sprintf(pTmpBuf2, "%s: \f%05d%s\f00000\n", pGlobalTXT_LocalizationStrings[47],
-          GetConditionDrawColor(v25), aCharacterConditionNames[v25]);
-  strcat(pTmpBuf, pTmpBuf2);
-  v28 = pPlayer->uQuickSpell;
-  if ( v28 )
-    v29 = pSpellStats->pInfos[v28].pShortName;
-  else
-    v29 = pGlobalTXT_LocalizationStrings[153];
-  sprintf((char*)pTmpBuf2, "%s: %s", (char*)pGlobalTXT_LocalizationStrings[172], v29);
-  strcat((char*)pTmpBuf, (char*)pTmpBuf2);
-  DrawText(pFontArrus, 120, 22, 0, pTmpBuf, 0, 0, 0);
-
-  uFramesetIDa = 0;
-  for (uint i = 0; i < 24; ++i)
-  {
-    auto buff = pPlayer->pPlayerBuffs + i;
-    if (buff->uExpireTime > 0)
-    {
-      v35 = buff->uExpireTime - pParty->uTimePlayed;
-      v36 = uFramesetIDa++ * pFontComic->uFontHeight + 134;
-      v38 = TargetColor(
-              _4E2AD8_ui_colors[i * 3],
-              _4E2AD8_ui_colors[i * 3 + 1],
-              _4E2AD8_ui_colors[i * 3 + 2]);
-      DrawText(pFontComic, 52, v36, v38, aSpellNames[20 + i], 0, 0, 0);
-      sub_41D20D_buff_remaining_time_string(v36, this, v35, pFontComic);
-    }
-  }
-
-  v39 = "";
-  if ( uFramesetIDa == 0 )
-    v39 = pGlobalTXT_LocalizationStrings[153];
-  sprintf(pTmpBuf, pGlobalTXT_LocalizationStrings[450], v39);
-  DrawText(pFontArrus, 14, 114, 0, pTmpBuf, 0, 0, 0);
-}
-
 //----- (0041D08F) --------------------------------------------------------
 void GUIWindow::_41D08F_set_keyboard_control_group(int a2, int a3, int a4, int a5)
 {
@@ -768,7 +648,7 @@
       }
       break;
 
-  case WINDOW_HistoryBook:
+  case WINDOW_JournalBook:
   {
       pSpellBookPagesTextr_11  = pIcons_LOD->LoadTexturePtr("sbplayrnot", TEXTURE_16BIT_PALETTE);
       pTex_tab_an_6b__zoom_on  = pIcons_LOD->LoadTexturePtr("tab-an-6b", TEXTURE_16BIT_PALETTE);
@@ -939,7 +819,7 @@
   if ( v17 )
   {
     v18 = pFontLucida->CalcTextHeight(v17, &v19, 0, 0);
-    v19.DrawTitleText(pFontLucida, 0, (signed int)(v16 - v18) / 2 - 14, 0, v17, 3u);
+    v19.DrawTitleText(pFontLucida, 0, (signed int)(v16 - v18) / 2 - 14, 0, v17, 3);
   }
 }