comparison UIPopup.cpp @ 739:e0a8cc28caeb

Слияние
author Ritor1
date Fri, 22 Mar 2013 09:14:45 +0600
parents da130dd3092a
children 700b58aac975
comparison
equal deleted inserted replaced
738:7378398c34e4 739:e0a8cc28caeb
73 unsigned int v22; // [sp+34h] [bp-4h]@11 73 unsigned int v22; // [sp+34h] [bp-4h]@11
74 74
75 v4 = uY; 75 v4 = uY;
76 a2a = uX; 76 a2a = uX;
77 a4 = uX + uWidth; 77 a4 = uX + uWidth;
78 pRenderer->Clip(uX, v4, uX + uWidth, v4 + uHeight); 78 pRenderer->SetTextureClipRect(uX, v4, uX + uWidth, v4 + uHeight);
79 v5 = (Texture *)(uTextureID_Parchment != -1 ? (int)&pIcons_LOD->pTextures[uTextureID_Parchment] : 0); 79 v5 = (Texture *)(uTextureID_Parchment != -1 ? (int)&pIcons_LOD->pTextures[uTextureID_Parchment] : 0);
80 uTileWidth = (uTextureID_Parchment != -1 ? pIcons_LOD->pTextures[uTextureID_Parchment].uTextureWidth : 24); 80 uTileWidth = (uTextureID_Parchment != -1 ? pIcons_LOD->pTextures[uTextureID_Parchment].uTextureWidth : 24);
81 v13 = (uTextureID_Parchment != -1 ? pIcons_LOD->pTextures[uTextureID_Parchment].uTextureWidth : 24); 81 v13 = (uTextureID_Parchment != -1 ? pIcons_LOD->pTextures[uTextureID_Parchment].uTextureWidth : 24);
82 uTileHeight = (uTextureID_Parchment != -1 ? pIcons_LOD->pTextures[uTextureID_Parchment].uTextureHeight : 26); 82 uTileHeight = (uTextureID_Parchment != -1 ? pIcons_LOD->pTextures[uTextureID_Parchment].uTextureHeight : 26);
83 if ( (uTextureID_Parchment != -1 ? pIcons_LOD->pTextures[uTextureID_Parchment].uTextureWidth : 24) 83 if ( (uTextureID_Parchment != -1 ? pIcons_LOD->pTextures[uTextureID_Parchment].uTextureWidth : 24)
128 (Texture *)(uTextureID_5076B0 != -1 ? (int)&pIcons_LOD->pTextures[uTextureID_5076B0] : 0)); 128 (Texture *)(uTextureID_5076B0 != -1 ? (int)&pIcons_LOD->pTextures[uTextureID_5076B0] : 0));
129 uNumXTilesb = a2a + 32; 129 uNumXTilesb = a2a + 32;
130 v22 = v4 + uHeight - 10; 130 v22 = v4 + uHeight - 10;
131 if ( (signed int)uWidth > 64 ) 131 if ( (signed int)uWidth > 64 )
132 { 132 {
133 pRenderer->Clip(a2a + 32, v4, a4 - 32, v4 + uHeight); 133 pRenderer->SetTextureClipRect(a2a + 32, v4, a4 - 32, v4 + uHeight);
134 pRenderer->DrawTextureTransparent( 134 pRenderer->DrawTextureTransparent(
135 uNumXTilesb, 135 uNumXTilesb,
136 v4, 136 v4,
137 (Texture *)(uTextureID_507698 != -1 ? &pIcons_LOD->pTextures[uTextureID_507698] : 0)); 137 (Texture *)(uTextureID_507698 != -1 ? &pIcons_LOD->pTextures[uTextureID_507698] : 0));
138 pRenderer->DrawTextureTransparent( 138 pRenderer->DrawTextureTransparent(
152 } 152 }
153 } 153 }
154 v9 = v4 + 32; 154 v9 = v4 + 32;
155 if ( (signed int)uHeight > 64 ) 155 if ( (signed int)uHeight > 64 )
156 { 156 {
157 pRenderer->Clip(a2a, v9, a4, a5a); 157 pRenderer->SetTextureClipRect(a2a, v9, a4, a5a);
158 pRenderer->DrawTextureTransparent( 158 pRenderer->DrawTextureTransparent(
159 a2a, 159 a2a,
160 v9, 160 v9,
161 (Texture *)(uTextureID_5076A0 != -1 ? &pIcons_LOD->pTextures[uTextureID_5076A0] : 0)); 161 (Texture *)(uTextureID_5076A0 != -1 ? &pIcons_LOD->pTextures[uTextureID_5076A0] : 0));
162 pRenderer->DrawTextureTransparent( 162 pRenderer->DrawTextureTransparent(
163 a4 - 10, 163 a4 - 10,
164 v9, 164 v9,
165 (Texture *)(uTextureID_50769C != -1 ? &pIcons_LOD->pTextures[uTextureID_50769C] : 0)); 165 (Texture *)(uTextureID_50769C != -1 ? &pIcons_LOD->pTextures[uTextureID_50769C] : 0));
166 } 166 }
167 pRenderer->ResetClip(); 167 pRenderer->ResetTextureClipRect();
168 } 168 }
169 } 169 }
170 170
171 171
172 172
348 //a2.y = inspect_item->Identified(); 348 //a2.y = inspect_item->Identified();
349 if (inspect_item->Broken()) 349 if (inspect_item->Broken())
350 { 350 {
351 wHintWindow.DrawMessageBox(0); 351 wHintWindow.DrawMessageBox(0);
352 //v15 = &; 352 //v15 = &;
353 pRenderer->Clip(wHintWindow.uFrameX + 12, wHintWindow.uFrameY + 12, 353 pRenderer->SetTextureClipRect(wHintWindow.uFrameX + 12, wHintWindow.uFrameY + 12,
354 wHintWindow.uFrameX + wHintWindow.uFrameWidth - 12, 354 wHintWindow.uFrameX + wHintWindow.uFrameWidth - 12,
355 wHintWindow.uFrameY + wHintWindow.uFrameHeight - 12); 355 wHintWindow.uFrameY + wHintWindow.uFrameHeight - 12);
356 wHintWindow.uFrameWidth -= 24; 356 wHintWindow.uFrameWidth -= 24;
357 wHintWindow.uFrameHeight -= 12; 357 wHintWindow.uFrameHeight -= 12;
358 wHintWindow.uFrameZ = wHintWindow.uFrameX + wHintWindow.uFrameWidth - 1; 358 wHintWindow.uFrameZ = wHintWindow.uFrameX + wHintWindow.uFrameWidth - 1;
365 wHintWindow.DrawTitleText(pFontArrus, 0, 0xCu, var88, v16, 3u); 365 wHintWindow.DrawTitleText(pFontArrus, 0, 0xCu, var88, v16, 3u);
366 v17 = pFontArrus->CalcTextHeight(pGlobalTXT_LocalizationStrings[32], &wHintWindow, 0, 0); //"Broken Item" 366 v17 = pFontArrus->CalcTextHeight(pGlobalTXT_LocalizationStrings[32], &wHintWindow, 0, 0); //"Broken Item"
367 v18 = v17 >> 1; 367 v18 = v17 >> 1;
368 v19 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0x19u, 0x19u); 368 v19 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0x19u, 0x19u);
369 wHintWindow.DrawTitleText(pFontArrus, 0x64u, ((signed int)wHintWindow.uFrameHeight >> 1) - v18, v19, pGlobalTXT_LocalizationStrings[32], 3); //"Broken Item" 369 wHintWindow.DrawTitleText(pFontArrus, 0x64u, ((signed int)wHintWindow.uFrameHeight >> 1) - v18, v19, pGlobalTXT_LocalizationStrings[32], 3); //"Broken Item"
370 pRenderer->ResetClip(); 370 pRenderer->ResetTextureClipRect();
371 if ( !areWeLoadingTexture ) 371 if ( !areWeLoadingTexture )
372 { 372 {
373 v73->Release(); 373 v73->Release();
374 pIcons_LOD->_40F9C5(); 374 pIcons_LOD->_40F9C5();
375 } 375 }
376 return; 376 return;
377 } 377 }
378 if (!inspect_item->Identified()) 378 if (!inspect_item->Identified())
379 { 379 {
380 wHintWindow.DrawMessageBox(0); 380 wHintWindow.DrawMessageBox(0);
381 pRenderer->Clip(wHintWindow.uFrameX + 12, wHintWindow.uFrameY + 12, 381 pRenderer->SetTextureClipRect(wHintWindow.uFrameX + 12, wHintWindow.uFrameY + 12,
382 wHintWindow.uFrameX + wHintWindow.uFrameWidth - 12, 382 wHintWindow.uFrameX + wHintWindow.uFrameWidth - 12,
383 wHintWindow.uFrameY + wHintWindow.uFrameHeight - 12); 383 wHintWindow.uFrameY + wHintWindow.uFrameHeight - 12);
384 wHintWindow.uFrameWidth -= 24; 384 wHintWindow.uFrameWidth -= 24;
385 wHintWindow.uFrameHeight -= 12; 385 wHintWindow.uFrameHeight -= 12;
386 wHintWindow.uFrameZ = wHintWindow.uFrameX + wHintWindow.uFrameWidth - 1; 386 wHintWindow.uFrameZ = wHintWindow.uFrameX + wHintWindow.uFrameWidth - 1;
389 wHintWindow.DrawTitleText(pFontArrus, 0, 0xCu, var88, item_desc->pUnidentifiedName, 3u); 389 wHintWindow.DrawTitleText(pFontArrus, 0, 0xCu, var88, item_desc->pUnidentifiedName, 3u);
390 v17 = pFontArrus->CalcTextHeight(pGlobalTXT_LocalizationStrings[232], &wHintWindow, 0, 0); ///"Not Identified" 390 v17 = pFontArrus->CalcTextHeight(pGlobalTXT_LocalizationStrings[232], &wHintWindow, 0, 0); ///"Not Identified"
391 v18 = v17 >> 1; 391 v18 = v17 >> 1;
392 v19 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0x19u, 0x19u); 392 v19 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0x19u, 0x19u);
393 wHintWindow.DrawTitleText(pFontArrus, 0x64u, ((signed int)wHintWindow.uFrameHeight >> 1) - v18, v19, pGlobalTXT_LocalizationStrings[232], 3); 393 wHintWindow.DrawTitleText(pFontArrus, 0x64u, ((signed int)wHintWindow.uFrameHeight >> 1) - v18, v19, pGlobalTXT_LocalizationStrings[232], 3);
394 pRenderer->ResetClip(); 394 pRenderer->ResetTextureClipRect();
395 if ( !areWeLoadingTexture ) 395 if ( !areWeLoadingTexture )
396 { 396 {
397 v73->Release(); 397 v73->Release();
398 pIcons_LOD->_40F9C5(); 398 pIcons_LOD->_40F9C5();
399 } 399 }
516 wHintWindow.uFrameHeight += (unsigned int)v85; 516 wHintWindow.uFrameHeight += (unsigned int)v85;
517 wHintWindow.uFrameW = wHintWindow.uFrameY + wHintWindow.uFrameHeight - 1; 517 wHintWindow.uFrameW = wHintWindow.uFrameY + wHintWindow.uFrameHeight - 1;
518 wHintWindow.uFrameZ = wHintWindow.uFrameX + wHintWindow.uFrameWidth - 1; 518 wHintWindow.uFrameZ = wHintWindow.uFrameX + wHintWindow.uFrameWidth - 1;
519 wHintWindow.DrawMessageBox(0); 519 wHintWindow.DrawMessageBox(0);
520 //v15 = pRenderer; 520 //v15 = pRenderer;
521 pRenderer->Clip(wHintWindow.uFrameX + 12, wHintWindow.uFrameY + 12, 521 pRenderer->SetTextureClipRect(wHintWindow.uFrameX + 12, wHintWindow.uFrameY + 12,
522 wHintWindow.uFrameX + wHintWindow.uFrameWidth - 12, wHintWindow.uFrameY + wHintWindow.uFrameHeight - 12); 522 wHintWindow.uFrameX + wHintWindow.uFrameWidth - 12, wHintWindow.uFrameY + wHintWindow.uFrameHeight - 12);
523 wHintWindow.uFrameWidth -= 12; 523 wHintWindow.uFrameWidth -= 12;
524 v32 = v73->uTextureHeight; 524 v32 = v73->uTextureHeight;
525 v33 = wHintWindow.uFrameHeight; 525 v33 = wHintWindow.uFrameHeight;
526 wHintWindow.uFrameHeight -= 12; 526 wHintWindow.uFrameHeight -= 12;
606 } 606 }
607 else 607 else
608 { 608 {
609 if ( !(BYTE1(v38) & 2) ) 609 if ( !(BYTE1(v38) & 2) )
610 { 610 {
611 pRenderer->ResetClip(); 611 pRenderer->ResetTextureClipRect();
612 if ( !areWeLoadingTexture ) 612 if ( !areWeLoadingTexture )
613 { 613 {
614 v73->Release(); 614 v73->Release();
615 pIcons_LOD->_40F9C5(); 615 pIcons_LOD->_40F9C5();
616 } 616 }
627 v39 = pFontComic->GetLineWidth(pTmpBuf); 627 v39 = pFontComic->GetLineWidth(pTmpBuf);
628 v40 = pFontComic; 628 v40 = pFontComic;
629 v41 = v39 + 132; 629 v41 = v39 + 132;
630 } 630 }
631 wHintWindow.DrawText(v40, v41, v42, v44, v47, v51, v56, v61); 631 wHintWindow.DrawText(v40, v41, v42, v44, v47, v51, v56, v61);
632 pRenderer->ResetClip(); 632 pRenderer->ResetTextureClipRect();
633 if ( !areWeLoadingTexture ) 633 if ( !areWeLoadingTexture )
634 { 634 {
635 v73->Release(); 635 v73->Release();
636 pIcons_LOD->_40F9C5(); 636 pIcons_LOD->_40F9C5();
637 } 637 }