Mercurial > mm7
comparison LayingItem.cpp @ 187:49728858c35e
On player voices
author | Nomad |
---|---|
date | Fri, 15 Feb 2013 22:38:05 +0200 |
parents | 9c0607679772 |
children | 07eb7d649bd5 |
comparison
equal
deleted
inserted
replaced
186:d65528fc3bda | 187:49728858c35e |
---|---|
11 size_t uNumLayingItems; | 11 size_t uNumLayingItems; |
12 LayingItem pLayingItems[1000]; | 12 LayingItem pLayingItems[1000]; |
13 | 13 |
14 | 14 |
15 //----- (00438E35) -------------------------------------------------------- | 15 //----- (00438E35) -------------------------------------------------------- |
16 __int16 LayingItem::_438E35() | 16 void LayingItem::_438E35() |
17 { | 17 { |
18 LayingItem *v1; // edi@1 | 18 LayingItem *v1; // edi@1 |
19 MapInfo *pMapInfo; // esi@1 | 19 MapInfo *pMapInfo; // esi@1 |
20 int v3; // ebx@1 | 20 int v3; // ebx@1 |
21 int v4; // eax@1 | 21 int v4; // eax@1 |
83 break; | 83 break; |
84 case 0x32Du: | 84 case 0x32Du: |
85 v18 = 2; | 85 v18 = 2; |
86 break; | 86 break; |
87 default: | 87 default: |
88 LOWORD(v10) = v1->uItemType - 814; | 88 //LOWORD(v10) = v1->uItemType - 814; |
89 if ( v1->uItemType != 814 ) | 89 if ( v1->uItemType != 814 ) |
90 return v10; | 90 return; |
91 v18 = 8; | 91 v18 = 8; |
92 break; | 92 break; |
93 } | 93 } |
94 v12 = &pPlayers[1]; | 94 v12 = &pPlayers[1]; |
95 do | 95 do |
96 { | 96 { |
97 if ( (*v12)->CanAct() && (v13 = (*v12)->GetPerception() + 20, rand() % v13 > 20) ) | 97 if ( (*v12)->CanAct() && (v13 = (*v12)->GetPerception() + 20, rand() % v13 > 20) ) |
98 LOWORD(v10) = (*v12)->PlaySound(6, 0); | 98 (*v12)->PlaySound(SPEECH_6, 0); |
99 else | 99 else |
100 LOWORD(v10) = (*v12)->ReceiveDamage(v11, v18); | 100 (*v12)->ReceiveDamage(v11, v18); |
101 ++v12; | 101 ++v12; |
102 } | 102 } |
103 while ( (signed int)v12 <= (signed int)&pPlayers[4] ); | 103 while ( (signed int)v12 <= (signed int)&pPlayers[4] ); |
104 } | 104 } |
105 return v10; | |
106 } | 105 } |
107 | 106 |
108 | 107 |
109 | 108 |
110 //----- (0042F933) -------------------------------------------------------- | 109 //----- (0042F933) -------------------------------------------------------- |