diff mm7_2.cpp @ 190:9b77686e2239

Merge
author Gloval
date Sat, 16 Feb 2013 00:44:38 +0400
parents 038a4d09406f 49728858c35e
children 650d96af8855
line wrap: on
line diff
--- a/mm7_2.cpp	Sat Feb 16 00:33:21 2013 +0400
+++ b/mm7_2.cpp	Sat Feb 16 00:44:38 2013 +0400
@@ -244,7 +244,7 @@
         if ( pParty->uFine < 0 )
           pParty->uFine = 0;
         if ( uActiveCharacter )
-          pPlayers[uActiveCharacter]->PlaySound(81, 0);
+          pPlayers[uActiveCharacter]->PlaySound(SPEECH_81, 0);
         v0 = ptr_507BC0;
       }
       else
@@ -348,7 +348,7 @@
             Party::TakeGold(v7);
             pParty->uNumGoldInBank += v7;
             if ( uActiveCharacter )
-              pPlayers[uActiveCharacter]->PlaySound(81, 0);
+              pPlayers[uActiveCharacter]->PlaySound(SPEECH_81, 0);
           }
           v0 = ptr_507BC0;
 LABEL_16:
@@ -744,7 +744,7 @@
         {
           ShowStatusBarString(pGlobalTXT_LocalizationStrings[140], 2u);
           if ( uActiveCharacter )
-            pPlayers[uActiveCharacter]->PlaySound(67, 0);
+            pPlayers[uActiveCharacter]->PlaySound(SPEECH_67, 0);
           goto LABEL_43;
         }
         if ( pParty->uNumGold >= v7 )
@@ -4189,7 +4189,7 @@
                     Party::TakeGold(v37);
                     dword_F8B1E4 = 1;
                     *(short *)v38 = 1;
-                    v35->PlaySound(78, 0);
+                    v35->PlaySound(SPEECH_78, 0);
                   }
                 }
               }
@@ -4600,7 +4600,7 @@
       memcpy(&v0->spellbook.pDarkSpellbook.bIsSpellAvailable[36 * v25 + 5], v20, 0x24u);
       goto LABEL_42;
     }
-    v0->PlaySound(15, 0);
+    v0->PlaySound(SPEECH_15, 0);
     v54 = 5;
 LABEL_70:
     v9 = pGlobalTXT_LocalizationStrings[563];   // "Pack is Full!"
@@ -4690,12 +4690,12 @@
       pRenderer->ClearZBuffer(0, 479);
       v27 = v77;
       v53 = 0;
-      v51 = 75;
+      v51 = SPEECH_75;
 LABEL_81:
-      v27->PlaySound(v51, v53);
+      v27->PlaySound((PlayerSpeech)v51, v53);
       return;
     }
-    v0->PlaySound(15, 0);
+    v0->PlaySound(SPEECH_15, 0);
     v54 = 2;
     goto LABEL_70;
   }
@@ -4718,7 +4718,7 @@
       v51 = 77;
       goto LABEL_80;
     }
-    v0->PlaySound(79, 0);
+    v0->PlaySound(SPEECH_79, 0);
     v56 = 0;
     v52 = 0;
     v50 = 0;
@@ -4754,7 +4754,7 @@
                 dword_F8B1E4 = 1;
                 Party::TakeGold(v80);
                 *(int *)(v12 + 20) |= 1u;
-                v0->PlaySound(73, 0);
+                v0->PlaySound(SPEECH_73, 0);
                 v9 = pGlobalTXT_LocalizationStrings[569];
                 goto LABEL_25;
               }
@@ -4807,7 +4807,7 @@
                   v8 = *(int *)(v3 + 20);
                   LOBYTE(v8) = v8 & 0xFD;
                   *(int *)(v3 + 20) = v8 | 1;
-                  v0->PlaySound(74, 0);
+                  v0->PlaySound(SPEECH_74, 0);
                   v9 = pGlobalTXT_LocalizationStrings[570];
 LABEL_25:
                   v54 = 2;
@@ -4873,10 +4873,11 @@
   static_stru_F8BA58.field_0 = 0;
   if ( _this && *_this )
   {
-    v2 = (char *)&unk_F8B668;
+    int i = 0;
+    v2 = (char *)&array_F8B668;
     v3 = 1;
     v7 = 0;
-    v4 = _this - (char *)&unk_F8B668;
+    v4 = _this - (char *)&array_F8B668;
     do
     {
       v5 = v2[v4];
@@ -4921,8 +4922,9 @@
       if ( static_stru_F8BA58.field_0 >= 30 )
         break;
       ++v2;
-    }
-    while ( (unsigned int)v2 < (unsigned int)&unk_F8BA50 );
+      ++i;
+    }
+    while (i < 1000);
     *v2 = 0;
   }
   result = a2;
@@ -14794,7 +14796,7 @@
         if ( (signed int)SkillToMastery(v5) < 3 )
         {
 LABEL_8:
-          v0->PlaySound(39, 0);
+          v0->PlaySound(SPEECH_39, 0);
           return;
         }
         v3 = pParty->pPickedItem.uItemID;