comparison mm7_3.cpp @ 674:c508daac2c07

A bit of minimap cleaning
author Nomad
date Thu, 14 Mar 2013 23:26:01 +0200
parents 1ff57450f090
children 92c1e1250e7c
comparison
equal deleted inserted replaced
658:cec42951eda0 674:c508daac2c07
11881 double v21; // st6@30 11881 double v21; // st6@30
11882 double v22; // st5@33 11882 double v22; // st5@33
11883 signed int v27; // eax@37 11883 signed int v27; // eax@37
11884 unsigned __int16 *v28; // ecx@37 11884 unsigned __int16 *v28; // ecx@37
11885 signed int v29; // edi@40 11885 signed int v29; // edi@40
11886 signed int v33; // ebx@50 11886 //signed int v33; // ebx@50
11887 unsigned int v34; // eax@50 11887 //unsigned int v34; // eax@50
11888 signed int v35; // ecx@50 11888 //signed int v35; // ecx@50
11889 unsigned __int16 v36; // di@66 11889 //unsigned __int16 v36; // di@66
11890 int v37; // edi@72 11890 int v37; // edi@72
11891 int v38; // ebx@72 11891 int v38; // ebx@72
11892 __int16 v39; // ax@87 11892 __int16 v39; // ax@87
11893 int v40; // edi@91 11893 int v40; // edi@91
11894 int v41; // ebx@91 11894 int v41; // ebx@91
11904 unsigned int v52; // [sp-10h] [bp-64h]@100 11904 unsigned int v52; // [sp-10h] [bp-64h]@100
11905 unsigned int v53; // [sp-Ch] [bp-60h]@79 11905 unsigned int v53; // [sp-Ch] [bp-60h]@79
11906 unsigned int v54; // [sp-Ch] [bp-60h]@100 11906 unsigned int v54; // [sp-Ch] [bp-60h]@100
11907 unsigned int v55; // [sp-8h] [bp-5Ch]@77 11907 unsigned int v55; // [sp-8h] [bp-5Ch]@77
11908 unsigned int v56; // [sp-8h] [bp-5Ch]@100 11908 unsigned int v56; // [sp-8h] [bp-5Ch]@100
11909 signed int v57; // [sp-4h] [bp-58h]@54 11909 //signed int v57; // [sp-4h] [bp-58h]@54
11910 unsigned __int16 v58; // [sp-4h] [bp-58h]@77 11910 unsigned __int16 v58; // [sp-4h] [bp-58h]@77
11911 unsigned __int16 v59; // [sp-4h] [bp-58h]@100 11911 unsigned __int16 v59; // [sp-4h] [bp-58h]@100
11912 unsigned __int16 v60; // [sp+10h] [bp-44h]@66 11912 unsigned __int16 v60; // [sp+10h] [bp-44h]@66
11913 unsigned int v61; // [sp+10h] [bp-44h]@85 11913 unsigned int v61; // [sp+10h] [bp-44h]@85
11914 unsigned int v63; // [sp+14h] [bp-40h]@85 11914 unsigned int v63; // [sp+14h] [bp-40h]@85
12113 uBlue); 12113 uBlue);
12114 } 12114 }
12115 } 12115 }
12116 12116
12117 12117
12118 //_draw_party_arrow: 12118 assert(pParty->sRotationY >= 0);
12119 v33 = 0; 12119 float angle = (pParty->sRotationY % 2048) / 2048.0f;
12120 v34 = pParty->sRotationY & stru_5C6E00->uDoublePiMask; 12120 const float two_pi = 2.0f * 3.14159f;
12121 v35 = 0; 12121
12122 if ( (signed int)(pParty->sRotationY & stru_5C6E00->uDoublePiMask) < 128 ) 12122 uint arrow_idx = floorf(0.5f + 7 * angle);
12123 goto LABEL_66; 12123 pRenderer->DrawTextureTransparent(uCenterX - 3, uCenterY - 3, pIcons_LOD->GetTexture(pTextureIDs_pMapDirs[arrow_idx]));
12124 if ( (signed int)v34 <= 384 ) 12124
12125 {
12126 v35 = 1;
12127 goto LABEL_66;
12128 }
12129 if ( (signed int)v34 >= 640 )
12130 {
12131 if ( (signed int)v34 > 896 )
12132 {
12133 if ( (signed int)v34 >= 1152 )
12134 {
12135 if ( (signed int)v34 > 1408 )
12136 {
12137 if ( (signed int)v34 >= 1664 )
12138 {
12139 if ( (signed int)v34 > 1920 )
12140 goto LABEL_66;
12141 v57 = 7;
12142 }
12143 else
12144 {
12145 v57 = 6;
12146 }
12147 }
12148 else
12149 {
12150 v57 = 5;
12151 }
12152 }
12153 else
12154 {
12155 v57 = 4;
12156 }
12157 }
12158 else
12159 {
12160 v57 = 3;
12161 }
12162 }
12163 else
12164 {
12165 v57 = 2;
12166 }
12167 v35 = v57;
12168 LABEL_66:
12169 pRenderer->DrawTextureTransparent(uCenterX - 3, uCenterY - 3,
12170 (Texture *)(pTextureIDs_pMapDirs[v35] != -1 ? &pIcons_LOD->pTextures[pTextureIDs_pMapDirs[v35]] : 0));
12171 v36 = 255;
12172 flagsb = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0, 0, 0xFFu); 12125 flagsb = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0, 0, 0xFFu);
12173 v60 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0, 0); 12126 v60 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0, 0);
12174 if ( bWizardEyeActive = true) 12127 if (bWizardEyeActive)
12175 { 12128 {
12176 uZe = 0; 12129 uZe = 0;
12177 //for (uint i = 0; i < uNumSpriteObjects; ++i) 12130 //for (uint i = 0; i < uNumSpriteObjects; ++i)
12178 if (uNumSpriteObjects > 0) 12131 if (uNumSpriteObjects > 0)
12179 { 12132 {
12215 LABEL_83: 12168 LABEL_83:
12216 ++uZe; 12169 ++uZe;
12217 a2c += 112; 12170 a2c += 112;
12218 if ( uZe >= (signed int)uNumSpriteObjects ) 12171 if ( uZe >= (signed int)uNumSpriteObjects )
12219 { 12172 {
12220 v36 = 255;
12221 v33 = 0;
12222 goto LABEL_85; 12173 goto LABEL_85;
12223 } 12174 }
12224 } 12175 }
12225 v58 = v60; 12176 v58 = v60;
12226 v55 = uCenterY - v79; 12177 v55 = uCenterY - v79;
12228 v53 = v37; 12179 v53 = v37;
12229 v51 = uCenterY - v79; 12180 v51 = uCenterY - v79;
12230 goto LABEL_82; 12181 goto LABEL_82;
12231 } 12182 }
12232 LABEL_85: 12183 LABEL_85:
12233 v63 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(v36, 0, v33); 12184 v63 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(255, 0, 0);
12234 v61 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0, v36, v33); 12185 v61 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0, 255, 0);
12235 v65 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(v36, v36, v33); 12186 v65 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(255, 255, 0);
12236 uZf = v33; 12187 uZf = 0;
12237 if ( (signed int)uNumActors > v33 ) 12188 if ( (signed int)uNumActors > 0 )
12238 { 12189 {
12239 flagsc = pActors;//[0].uAIState; 12190 flagsc = pActors;//[0].uAIState;
12240 do 12191 do
12241 { 12192 {
12242 v39 = flagsc->uAIState; 12193 v39 = flagsc->uAIState;
12286 } 12237 }
12287 ++uZf; 12238 ++uZf;
12288 ++flagsc; 12239 ++flagsc;
12289 } 12240 }
12290 while ( uZf < (signed int)uNumActors ); 12241 while ( uZf < (signed int)uNumActors );
12291 v36 = 255; 12242 }
12292 v33 = 0; 12243 }
12293 } 12244 flagsd = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(255, 255, 255);
12294 } 12245 uZg = 0;
12295 flagsd = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(v36, v36, v36); 12246 if ( (signed int)uNumLevelDecorations > 0 )
12296 uZg = v33;
12297 if ( (signed int)uNumLevelDecorations > v33 )
12298 { 12247 {
12299 v45 = (char *)&pLevelDecorations[0].vPosition; 12248 v45 = (char *)&pLevelDecorations[0].vPosition;
12300 lPitchb = (char *)&pLevelDecorations[0].vPosition; 12249 lPitchb = (char *)&pLevelDecorations[0].vPosition;
12301 do 12250 do
12302 { 12251 {
12329 ++uZg; 12278 ++uZg;
12330 v45 += 32; 12279 v45 += 32;
12331 lPitchb = v45; 12280 lPitchb = v45;
12332 } 12281 }
12333 while ( uZg < (signed int)uNumLevelDecorations ); 12282 while ( uZg < (signed int)uNumLevelDecorations );
12334 v33 = 0; 12283 }
12335 } 12284 pRenderer->DrawTextureTransparent(0x1D4u, 0, (Texture *)(dword_5079D8 != -1 ? &pIcons_LOD->pTextures[dword_5079D8] : 0));
12336 pRenderer->DrawTextureTransparent(0x1D4u, v33, (Texture *)(dword_5079D8 != -1 ? &pIcons_LOD->pTextures[dword_5079D8] : 0));
12337 uZooma = (double)pParty->sRotationY * 0.1171875; 12285 uZooma = (double)pParty->sRotationY * 0.1171875;
12338 //v50 = uZooma + 6.7553994e15; 12286 //v50 = uZooma + 6.7553994e15;
12339 pRenderer->Clip(0x21Du, v33, 0x237u, 0x1E0u); 12287 pRenderer->Clip(541, 0, 567, 480);
12340 pRenderer->DrawTextureIndexed(floorf(uZooma + 0.5f) + 285, 0x88u, (Texture *)(dword_5079B4 != -1 ? &pIcons_LOD->pTextures[dword_5079B4] : 0)); 12288 pRenderer->DrawTextureIndexed(floorf(uZooma + 0.5f) + 285, 136, (Texture *)(dword_5079B4 != -1 ? &pIcons_LOD->pTextures[dword_5079B4] : 0));
12341 pRenderer->ResetClip(); 12289 pRenderer->ResetClip();
12342 } 12290 }
12343 12291
12344 12292
12345 //----- (00442955) -------------------------------------------------------- 12293 //----- (00442955) --------------------------------------------------------