Mercurial > mm7
comparison mm7_3.cpp @ 726:9d13d2ec35a6
Слияние
author | Ritor1 |
---|---|
date | Fri, 22 Mar 2013 01:29:46 +0600 |
parents | 737d7fec67f0 e7c86528a2b3 |
children | 2f4e33c1ed24 7378398c34e4 |
comparison
equal
deleted
inserted
replaced
725:7037f22cd716 | 726:9d13d2ec35a6 |
---|---|
8218 v19 = (unsigned __int16 *)v18->pLevelOfDetail3; | 8218 v19 = (unsigned __int16 *)v18->pLevelOfDetail3; |
8219 } | 8219 } |
8220 } | 8220 } |
8221 else | 8221 else |
8222 { | 8222 { |
8223 v19 = (unsigned __int16 *)v18->pLevelOfDetail0; | 8223 v19 = (unsigned __int16 *)v18->pLevelOfDetail0_prolly_alpha_mask; |
8224 } | 8224 } |
8225 a1.pTextureLOD = v19; | 8225 a1.pTextureLOD = v19; |
8226 X = (unsigned __int64)(v36 * (signed __int64)v38) >> 16; | 8226 X = (unsigned __int64)(v36 * (signed __int64)v38) >> 16; |
8227 v20 = v3->ptr_38; | 8227 v20 = v3->ptr_38; |
8228 X = v38; | 8228 X = v38; |
8422 } | 8422 } |
8423 else | 8423 else |
8424 { | 8424 { |
8425 v19 = v3->pTexture; | 8425 v19 = v3->pTexture; |
8426 v84 = 0; | 8426 v84 = 0; |
8427 v18 = (unsigned __int16 *)v19->pLevelOfDetail0; | 8427 v18 = (unsigned __int16 *)v19->pLevelOfDetail0_prolly_alpha_mask; |
8428 } | 8428 } |
8429 a1.pTextureLOD = v18; | 8429 a1.pTextureLOD = v18; |
8430 LABEL_16: | 8430 LABEL_16: |
8431 if ( v18 ) | 8431 if ( v18 ) |
8432 { | 8432 { |
8878 } | 8878 } |
8879 else | 8879 else |
8880 { | 8880 { |
8881 v22 = v5->pTexture; | 8881 v22 = v5->pTexture; |
8882 v75 = 0; | 8882 v75 = 0; |
8883 v21 = (unsigned __int16 *)v22->pLevelOfDetail0; | 8883 v21 = (unsigned __int16 *)v22->pLevelOfDetail0_prolly_alpha_mask; |
8884 } | 8884 } |
8885 a1.pTextureLOD = v21; | 8885 a1.pTextureLOD = v21; |
8886 LABEL_12: | 8886 LABEL_12: |
8887 if ( v21 ) | 8887 if ( v21 ) |
8888 { | 8888 { |
9135 v44 = 2; | 9135 v44 = 2; |
9136 if ( v43 < mipmapping_terrain_mm1 << 16 ) | 9136 if ( v43 < mipmapping_terrain_mm1 << 16 ) |
9137 { | 9137 { |
9138 v20 = v3->pTexture; | 9138 v20 = v3->pTexture; |
9139 v44 = 0; | 9139 v44 = 0; |
9140 v21 = (unsigned __int16 *)v20->pLevelOfDetail0; | 9140 v21 = (unsigned __int16 *)v20->pLevelOfDetail0_prolly_alpha_mask; |
9141 LABEL_11: | 9141 LABEL_11: |
9142 a1.pTextureLOD = v21; | 9142 a1.pTextureLOD = v21; |
9143 goto LABEL_12; | 9143 goto LABEL_12; |
9144 } | 9144 } |
9145 if ( v43 < mipmapping_terrain_mm2 << 16 ) | 9145 if ( v43 < mipmapping_terrain_mm2 << 16 ) |
9311 v20 = 2; | 9311 v20 = 2; |
9312 v35.pTextureLOD = (unsigned __int16 *)v3->pTexture->pLevelOfDetail2; | 9312 v35.pTextureLOD = (unsigned __int16 *)v3->pTexture->pLevelOfDetail2; |
9313 if ( v17 < mipmapping_terrain_mm1 << 16 ) | 9313 if ( v17 < mipmapping_terrain_mm1 << 16 ) |
9314 { | 9314 { |
9315 v20 = 0; | 9315 v20 = 0; |
9316 v21 = (unsigned __int16 *)v3->pTexture->pLevelOfDetail0; | 9316 v21 = (unsigned __int16 *)v3->pTexture->pLevelOfDetail0_prolly_alpha_mask; |
9317 LABEL_11: | 9317 LABEL_11: |
9318 v35.pTextureLOD = v21; | 9318 v35.pTextureLOD = v21; |
9319 goto LABEL_12; | 9319 goto LABEL_12; |
9320 } | 9320 } |
9321 if ( v17 < mipmapping_terrain_mm2 << 16 ) | 9321 if ( v17 < mipmapping_terrain_mm2 << 16 ) |
9536 } | 9536 } |
9537 } | 9537 } |
9538 else | 9538 else |
9539 { | 9539 { |
9540 v16 = 0; | 9540 v16 = 0; |
9541 v17 = (unsigned __int16 *)v4->pTexture->pLevelOfDetail0; | 9541 v17 = (unsigned __int16 *)v4->pTexture->pLevelOfDetail0_prolly_alpha_mask; |
9542 } | 9542 } |
9543 sr.pTextureLOD = v17; | 9543 sr.pTextureLOD = v17; |
9544 LABEL_14: | 9544 LABEL_14: |
9545 sr.field_34_palette = (unsigned __int16 *)sr_sub_485E1F(&sr2, v61, v15, v4, pOutdoorCamera->terrain_gamma, 1u, 1); | 9545 sr.field_34_palette = (unsigned __int16 *)sr_sub_485E1F(&sr2, v61, v15, v4, pOutdoorCamera->terrain_gamma, 1u, 1); |
9546 v18 = v4->ptr_38; | 9546 v18 = v4->ptr_38; |
9886 } | 9886 } |
9887 else | 9887 else |
9888 { | 9888 { |
9889 v21 = v5->pTexture; | 9889 v21 = v5->pTexture; |
9890 v49 = 0; | 9890 v49 = 0; |
9891 pLOD = v21->pLevelOfDetail0; | 9891 pLOD = v21->pLevelOfDetail0_prolly_alpha_mask; |
9892 } | 9892 } |
9893 a1a.pTextureLOD = (unsigned __int16 *)pLOD; | 9893 a1a.pTextureLOD = (unsigned __int16 *)pLOD; |
9894 LABEL_12: | 9894 LABEL_12: |
9895 if ( !pLOD ) | 9895 if ( !pLOD ) |
9896 return 0; | 9896 return 0; |
12326 v20 = viewparams->sViewCenterX; | 12326 v20 = viewparams->sViewCenterX; |
12327 v21 = viewparams->sViewCenterY; | 12327 v21 = viewparams->sViewCenterY; |
12328 v19 = (double)viewparams->field_2C * 0.000015258789; | 12328 v19 = (double)viewparams->field_2C * 0.000015258789; |
12329 if ( viewparams->field_2C == 384 ) | 12329 if ( viewparams->field_2C == 384 ) |
12330 { | 12330 { |
12331 v20 = viewparams->field_38; | 12331 v20 = viewparams->indoor_center_x; |
12332 v21 = viewparams->field_3A; | 12332 v21 = viewparams->indoor_center_y; |
12333 } | 12333 } |
12334 v17 = 0; | 12334 v17 = 0; |
12335 v16 = pOutdoor->uNumBModels; | 12335 v16 = pOutdoor->uNumBModels; |
12336 pMouse->GetClickPos((unsigned int *)&pX, &pY); | 12336 pMouse->GetClickPos((unsigned int *)&pX, &pY); |
12337 v0 = 1.0 / v19; | 12337 v0 = 1.0 / v19; |
12476 v1 = pMapStats->GetMapInfo(pCurrentMapName); | 12476 v1 = pMapStats->GetMapInfo(pCurrentMapName); |
12477 if ( v1 ) | 12477 if ( v1 ) |
12478 sprintf(sHouseName, pGlobalTXT_LocalizationStrings[410], pMapStats->pInfos[v1].pName);// "Leave %s" | 12478 sprintf(sHouseName, pGlobalTXT_LocalizationStrings[410], pMapStats->pInfos[v1].pName);// "Leave %s" |
12479 else | 12479 else |
12480 strcpy(sHouseName, pGlobalTXT_LocalizationStrings[79]);// "Exit" | 12480 strcpy(sHouseName, pGlobalTXT_LocalizationStrings[79]);// "Exit" |
12481 result = GUIWindow::Create(0, 0, 640, 480, (enum WindowType)17, 0, (int)sHouseName); | 12481 result = GUIWindow::Create(0, 0, 640, 480, WINDOW_ChangeLocation, 0, (int)sHouseName); |
12482 pDialogueWindow = result; | 12482 pDialogueWindow = result; |
12483 return result; | 12483 return result; |
12484 } | 12484 } |
12485 | 12485 |
12486 //----- (00444D80) -------------------------------------------------------- | 12486 //----- (00444D80) -------------------------------------------------------- |
12641 pMiscTimer->Pause(); | 12641 pMiscTimer->Pause(); |
12642 pEventTimer->Pause(); | 12642 pEventTimer->Pause(); |
12643 dword_5C3418 = v4; | 12643 dword_5C3418 = v4; |
12644 dword_5C341C = v3; | 12644 dword_5C341C = v3; |
12645 _591094_decoration = activeLevelDecoration; | 12645 _591094_decoration = activeLevelDecoration; |
12646 pGUIWindow2 = GUIWindow::Create(0, 0, 640u, 480u, (enum WindowType)19, a4, 0); | 12646 pGUIWindow2 = GUIWindow::Create(0, 0, 640u, 480u, WINDOW_GreetingNPC, a4, 0); |
12647 pGUIWindow2->CreateButton(61u, 424u, 0x1Fu, 0x28u, 2, 94, 0x6Eu, 1u, 0x31u, "", 0); | 12647 pGUIWindow2->CreateButton(61u, 424u, 0x1Fu, 0x28u, 2, 94, 0x6Eu, 1u, 0x31u, "", 0); |
12648 pGUIWindow2->CreateButton(177u, 424u, 0x1Fu, 0x28u, 2, 94, 0x6Eu, 2u, 0x32u, "", 0); | 12648 pGUIWindow2->CreateButton(177u, 424u, 0x1Fu, 0x28u, 2, 94, 0x6Eu, 2u, 0x32u, "", 0); |
12649 pGUIWindow2->CreateButton(292u, 424u, 0x1Fu, 0x28u, 2, 94, 0x6Eu, 3u, 0x33u, "", 0); | 12649 pGUIWindow2->CreateButton(292u, 424u, 0x1Fu, 0x28u, 2, 94, 0x6Eu, 3u, 0x33u, "", 0); |
12650 pGUIWindow2->CreateButton(407u, 424u, 0x1Fu, 0x28u, 2, 94, 0x6Eu, 4u, 0x34u, "", 0); | 12650 pGUIWindow2->CreateButton(407u, 424u, 0x1Fu, 0x28u, 2, 94, 0x6Eu, 4u, 0x34u, "", 0); |
12651 } | 12651 } |
13211 *(int *)a2 = npcid - 5000; | 13211 *(int *)a2 = npcid - 5000; |
13212 return &pNPCStats->pAdditionalNPC[npcid - 5000]; | 13212 return &pNPCStats->pAdditionalNPC[npcid - 5000]; |
13213 } | 13213 } |
13214 if ( npcid >= 5000 ) | 13214 if ( npcid >= 5000 ) |
13215 goto LABEL_7; | 13215 goto LABEL_7; |
13216 if ( (sDialogue_SpeakingActorNPC_ID & 0x80000000u) == 0 ) | 13216 if ( sDialogue_SpeakingActorNPC_ID >= 0 ) |
13217 { | 13217 { |
13218 *(int *)a2 = 0; | 13218 *(int *)a2 = 0; |
13219 result = 0; | 13219 result = 0; |
13220 } | 13220 } |
13221 else | 13221 else |
15756 v27 = pMiscTimer->uTimeElapsed; | 15756 v27 = pMiscTimer->uTimeElapsed; |
15757 v28 = v21->pMonsterInfo.uRecoveryTime; | 15757 v28 = v21->pMonsterInfo.uRecoveryTime; |
15758 v21->uCurrentActionTime += pMiscTimer->uTimeElapsed; | 15758 v21->uCurrentActionTime += pMiscTimer->uTimeElapsed; |
15759 if ( (signed int)v28 > 0 ) | 15759 if ( (signed int)v28 > 0 ) |
15760 v21->pMonsterInfo.uRecoveryTime = v28 - v27; | 15760 v21->pMonsterInfo.uRecoveryTime = v28 - v27; |
15761 if ( (v21->pMonsterInfo.uRecoveryTime & 0x80000000u) != 0 ) | 15761 if ( v21->pMonsterInfo.uRecoveryTime< 0 ) |
15762 v21->pMonsterInfo.uRecoveryTime = 0; | 15762 v21->pMonsterInfo.uRecoveryTime = 0; |
15763 v29 = v21->uAttributes; | 15763 v29 = v21->uAttributes; |
15764 if ( !(v29 & 0x8000) ) | 15764 if ( !(v29 & 0x8000) ) |
15765 v21->uAttributes = v29 | 0x8000; | 15765 v21->uAttributes = v29 | 0x8000; |
15766 a1 = 8 * actor_id | OBJECT_Actor; | 15766 a1 = 8 * actor_id | OBJECT_Actor; |