comparison Outdoor.cpp @ 109:62772029b56d

Слияние
author Ritor1
date Tue, 06 Nov 2012 10:07:35 +0600
parents ccc0cf95706a 3b5267621a5b
children 05b2d9653abc d2ca891da89f
comparison
equal deleted inserted replaced
108:d543bd89a31e 109:62772029b56d
1279 //char *v106; // [sp-8h] [bp-B88h]@59 1279 //char *v106; // [sp-8h] [bp-B88h]@59
1280 int v107; // [sp-4h] [bp-B84h]@12 1280 int v107; // [sp-4h] [bp-B84h]@12
1281 int v108; // [sp+0h] [bp-B80h]@10 1281 int v108; // [sp+0h] [bp-B80h]@10
1282 char Src[968]; // [sp+10h] [bp-B70h]@110 1282 char Src[968]; // [sp+10h] [bp-B70h]@110
1283 char Dst[968]; // [sp+3D8h] [bp-7A8h]@50 1283 char Dst[968]; // [sp+3D8h] [bp-7A8h]@50
1284 /*char Str[256]; // [sp+7A0h] [bp-3E0h]@50 1284 char Str[256]; // [sp+7A0h] [bp-3E0h]@50
1285 char DstBuf; // [sp+8A0h] [bp-2E0h]@10 1285 /*char DstBuf; // [sp+8A0h] [bp-2E0h]@10
1286 __int32 Offset; // [sp+8A4h] [bp-2DCh]@10 1286 __int32 Offset; // [sp+8A4h] [bp-2DCh]@10
1287 __int32 v114; // [sp+8B0h] [bp-2D0h]@10 1287 __int32 v114; // [sp+8B0h] [bp-2D0h]@10
1288 __int32 v115; // [sp+8BCh] [bp-2C4h]@10 1288 __int32 v115; // [sp+8BCh] [bp-2C4h]@10
1289 __int32 v116; // [sp+8C8h] [bp-2B8h]@10 1289 __int32 v116; // [sp+8C8h] [bp-2B8h]@10
1290 __int32 v117; // [sp+8D4h] [bp-2ACh]@10 1290 __int32 v117; // [sp+8D4h] [bp-2ACh]@10
2664 } 2664 }
2665 return 1; 2665 return 1;
2666 } 2666 }
2667 2667
2668 //----- (0047F138) -------------------------------------------------------- 2668 //----- (0047F138) --------------------------------------------------------
2669 int OutdoorLocation::PrepareDecorations() 2669 bool OutdoorLocation::PrepareDecorations()
2670 { 2670 {
2671 signed int v1; // ebx@1 2671 signed int v1; // ebx@1
2672 signed int v2; // edi@3
2673 LevelDecoration *v3; // esi@4
2674 __int16 v4; // ax@5 2672 __int16 v4; // ax@5
2675 int v5; // eax@7 2673 int v5; // eax@7
2676 __int16 v6; // ax@14 2674 __int16 v6; // ax@14
2677 signed int v8; // [sp+Ch] [bp-4h]@1 2675 signed int v8; // [sp+Ch] [bp-4h]@1
2678 2676
2679 v1 = 0; 2677 v1 = 0;
2680 v8 = 0; 2678 v8 = 0;
2681 if ( !_strcmpi(pCurrentMapName, "out09.odm") ) 2679 if ( !_strcmpi(pCurrentMapName, "out09.odm") )
2682 v8 = 1; 2680 v8 = 1;
2683 v2 = 0; 2681
2684 if ( (signed int)uNumLevelDecorations > 0 ) 2682 for (uint i = 0; i < uNumLevelDecorations; ++i)
2685 { 2683 {
2686 v3 = pLevelDecorations; 2684 auto decor = pLevelDecorations + i;
2687 do 2685
2688 { 2686 pDecorationList->InitializeDecorationSprite(decor->uDecorationDescID);
2689 pDecorationList->InitializeDecorationSprite(v3->uDecorationDescID); 2687 v4 = pDecorationList->pDecorations[decor->uDecorationDescID].uSoundID;
2690 v4 = pDecorationList->pDecorations[v3->uDecorationDescID].uSoundID;
2691 if ( v4 && _6807E0_num_decorations_with_sounds_6807B8 < 9 ) 2688 if ( v4 && _6807E0_num_decorations_with_sounds_6807B8 < 9 )
2692 { 2689 {
2693 pSoundList->_4A9A67(v4, 0); 2690 pSoundList->_4A9A67(v4, 0);
2694 v5 = _6807E0_num_decorations_with_sounds_6807B8++; 2691 v5 = _6807E0_num_decorations_with_sounds_6807B8++;
2695 _6807B8_level_decorations_ids[v5] = v2; 2692 _6807B8_level_decorations_ids[v5] = i;
2696 } 2693 }
2697 if ( v8 && v3->uCog == 20 ) 2694 if ( v8 && decor->uCog == 20 )
2698 LOBYTE(v3->field_2) |= 0x40u; 2695 LOBYTE(decor->field_2) |= 0x40u;
2699 if ( !v3->field_16_event_id ) 2696 if ( !decor->field_16_event_id )
2700 { 2697 {
2701 if ( v3->IsInteractive() ) 2698 if ( decor->IsInteractive() )
2702 { 2699 {
2703 if ( v1 < 124 ) 2700 if ( v1 < 124 )
2704 { 2701 {
2705 v6 = v1++ + 75; 2702 v6 = v1 + 75;
2706 v3->field_1C = v6; 2703 decor->_idx_in_stru123 = v6;
2707 if ( !stru_5E4C90.field_0[v1 + 74] ) 2704 if ( !stru_5E4C90._decor_events[v1++] )
2708 LOBYTE(v3->field_2) |= 0x20u; 2705 LOBYTE(decor->field_2) |= 0x20u;
2709 } 2706 }
2710 } 2707 }
2711 } 2708 }
2712 ++v2; 2709 }
2713 ++v3; 2710
2714 }
2715 while ( v2 < (signed int)uNumLevelDecorations );
2716 }
2717 pGameLoadingUI_ProgressBar->Progress(); 2711 pGameLoadingUI_ProgressBar->Progress();
2718 return 1; 2712 return true;
2719 } 2713 }
2720 // 6807E0: using guessed type int _6807E0_num_decorations_6807B8; 2714 // 6807E0: using guessed type int _6807E0_num_decorations_6807B8;
2721 2715
2722 //----- (0047F223) -------------------------------------------------------- 2716 //----- (0047F223) --------------------------------------------------------
2723 int OutdoorLocation::_47F223_LooksLikeGenerateMonsterLoot() 2717 int OutdoorLocation::_47F223_LooksLikeGenerateMonsterLoot()