Mercurial > might-and-magic-trilogy
diff Indoor.cpp @ 98:f76e4ea4a224
Outdoor::Load
author | Nomad |
---|---|
date | Sun, 04 Nov 2012 03:58:34 +0200 |
parents | b5e26a133fae |
children | 6305c1cd9f6e |
line wrap: on
line diff
--- a/Indoor.cpp Fri Nov 02 14:45:06 2012 +0200 +++ b/Indoor.cpp Sun Nov 04 03:58:34 2012 +0200 @@ -67,7 +67,7 @@ //----- (0043F39E) -------------------------------------------------------- -void __fastcall sub_43F39E(IndoorLocation_drawstru *_this) +void __fastcall PrepareDrawLists_BLV(IndoorLocation_drawstru *_this) { //int *v1; // ecx@1 //double v2; // ST30_8@3 @@ -93,10 +93,9 @@ { //v2 = pParty->flt_TorchlightColorB + 6.7553994e15; //v11 = LOBYTE(v2); - if ( (signed __int64)pParty->pPartyBuffs[16].uExpireTime <= 0 ) - v5 = 800; - else - v5 = 800 * pParty->pPartyBuffs[16].uPower; + v5 = 800; + if (pParty->TorchlightActive()) + v5 *= pParty->pPartyBuffs[16].uPower; //LOBYTE(v1) = byte_4E94D0; //v4 = pParty->flt_TorchlightColorR + 6.7553994e15; //v3 = pParty->flt_TorchlightColorG + 6.7553994e15; @@ -310,7 +309,7 @@ signed int v6; // [sp+8h] [bp-8h]@7 int v7; // [sp+Ch] [bp-4h]@8 - sub_43F39E(_this); + PrepareDrawLists_BLV(_this); if (pBLVRenderParams->uPartySectorID) IndoorLocation::ExecDraw(pRenderer->pRenderD3D != 0); pRenderer->DrawBillboardList_BLV(); @@ -325,7 +324,7 @@ if ( (signed int)pStru170->std__vector_000FA8 > 0 ) { v7 = 0; - v2 = (char *)&pStru170->field_FA8[0].field_C.field_4; + v2 = (char *)&pStru170->field_FA8[0].field_C._viewport_space_w; do { v3 = *((int *)v2 - 1); @@ -873,7 +872,7 @@ v23 = 640 * stru_F8A590._viewport_space_y; v119 = 640 * stru_F8A590._viewport_space_y; v100 = v22; - if ( stru_F8A590._viewport_space_y <= stru_F8A590.field_4 ) + if ( stru_F8A590._viewport_space_y <= stru_F8A590._viewport_space_w ) { v24 = 2 * stru_F8A590._viewport_space_y; v120 = 2 * stru_F8A590._viewport_space_y; @@ -1197,7 +1196,7 @@ v24 += 2; v120 = v24; v119 = v23; - if ( a2 > stru_F8A590.field_4 ) + if ( a2 > stru_F8A590._viewport_space_w ) break; v21 = a2; } @@ -1646,7 +1645,7 @@ { v4 = stru_F8A590._viewport_space_y; v5 = pBLVRenderParams->pRenderTarget; - if ( stru_F8A590._viewport_space_y <= stru_F8A590.field_4 ) + if ( stru_F8A590._viewport_space_y <= stru_F8A590._viewport_space_w ) { v6 = 640 * stru_F8A590._viewport_space_y; do @@ -1657,7 +1656,7 @@ v5[v7] = -1; ++v4; } - while ( v4 <= stru_F8A590.field_4 ); + while ( v4 <= stru_F8A590._viewport_space_w ); } } } @@ -2027,7 +2026,7 @@ //v5 = 0; //v6 = this; - pNumSoundDecorations = 0; + _6807E0_num_decorations_with_sounds_6807B8 = 0; #pragma region "loading from txt" /*sprintf(FileName, "levels\\%s", pFilename); @@ -4611,10 +4610,10 @@ pDecorationList->InitializeDecorationSprite(pDecortaion->uDecorationDescID); v15 = pDecorationList->pDecorations[pDecortaion->uDecorationDescID].uSoundID; - if (v15 && pNumSoundDecorations < 9) + if (v15 && _6807E0_num_decorations_with_sounds_6807B8 < 9) { pSoundList->_4A9A67(v15, 0); - v16 = pNumSoundDecorations++; + v16 = _6807E0_num_decorations_with_sounds_6807B8++; _6807B8_level_decorations_ids[v16] = i; }