diff mm7_2.cpp @ 465:e65d75206263

m
author Ritor1
date Mon, 25 Feb 2013 09:08:13 +0600
parents 85edec9da96b
children 91e1ba340f39
line wrap: on
line diff
--- a/mm7_2.cpp	Fri Feb 22 14:47:17 2013 +0600
+++ b/mm7_2.cpp	Mon Feb 25 09:08:13 2013 +0600
@@ -1486,51 +1486,52 @@
   v3 = 0;
   if ( dword_F8B19C == 2 )
   {
-    v48 = 0;
+    //v48 = 0;
     v108 = 0;
-    v109 = 0;
-    do
-    {
-      if ( pParty->field_777C[9 * (int)&v48[3 * (unsigned int)window_SpeakInHouse->ptr_1C]] )
-      {
-        v49 = word_F8B158[(signed int)v48];
-        v50 = dword_F8B168[(signed int)v48];
+    int a = 0;
+    //do
+	for (int i = 0; i < 6; i++)
+    {
+      if ( pParty->field_777C[9 * (i + 12 * (unsigned int)window_SpeakInHouse->ptr_1C)] )
+      {
+        v49 = word_F8B158[i];
+        v50 = dword_F8B168[i];
         v49 += 30;
         v51 = 60 - ((signed int)v50->uTextureWidth >> 1);
         pRenderer->DrawTextureTransparent(v51 + v108, v49, v50);
         sub_40F92A(
           &pRenderer->pActiveZBuffer[v51 + v108 + 640 * v49],
-          dword_F8B168[(signed int)v109],
-          (int)((char *)v109 + 1));
-        v48 = v109;
+          dword_F8B168[a],
+          a++);
+        i = a;
       }
       v108 += 70;
-      v48 = (const char **)((char *)v48 + 1);
-      v109 = v48;
-    }
-    while ( (signed int)v48 < 6 );
+      i++;
+      a = i;
+    }
+    //while ( (signed int)v48 < 6 );
   }
   else
   {
-    v109 = 0;
+    //v109 = 0;
     v108 = 0;
-    do
-    {
-      if ( pParty->field_C59C[9 * (int)&v109[3 * (unsigned int)window_SpeakInHouse->ptr_1C] + 724] )
-      {
-        v52 = word_F8B158[(signed int)v109] + 30;
-        v53 = dword_F8B168[(signed int)v109];
+    //do
+	for (int i = 0; i < 6; i++)
+    {
+      if ( pParty->field_C59C[9 * (i + 12 * (unsigned int)window_SpeakInHouse->ptr_1C) + 724] )
+      {
+        v52 = word_F8B158[i] + 30;
+        v53 = dword_F8B168[i];
         v54 = 60 - ((signed int)v53->uTextureWidth >> 1);
-        pRenderer->DrawTextureTransparent(v54 + v108, word_F8B158[(signed int)v109] + 30, v53);
-        sub_40F92A(
-          &pRenderer->pActiveZBuffer[v54 + v108 + 640 * v52],
-          dword_F8B168[(signed int)v109],
-          (int)((char *)v109 + 1));
-      }
-      v109 = (const char **)((char *)v109 + 1);
+        pRenderer->DrawTextureTransparent(v54 + v108, word_F8B158[i] + 30, v53);
+        sub_40F92A(&pRenderer->pActiveZBuffer[v54 + v108 + 640 * v52],
+          dword_F8B168[i],
+          i++);
+      }
+      i++;
       v108 += 70;
     }
-    while ( (signed int)v109 < 6 );
+    //while ( (signed int)v109 < 6 );
   }
   result = (char *)sub_4B1784_check_if_player_concious__draw_warning_else_mess_with_dlg_win();
   if ( result )
@@ -3701,7 +3702,7 @@
 }
 
 //----- (004BCACC) --------------------------------------------------------
-void __fastcall sub_4BCACC_bounties(signed int a1)
+void __fastcall sub_4BCACC_bounties(signed int a1)//Shop_MsgUI
 {
   unsigned int v1; // edi@1
   //signed int v2; // ebx@1
@@ -13806,6 +13807,7 @@
     aborting_app = 1;
     if ( !pRenderer->bWindowMode )
       pRenderer->ChangeBetweenWinFullscreenModes();
+    __debugbreak;
     if ( MessageBoxA(0, pGlobalTXT_LocalizationStrings[176], pGlobalTXT_LocalizationStrings[59], 0x34u) == 6 )
       SaveGame(1, 0);                           // "Internal Error"
                                                 // "Might and Magic VII has detected an internal error and will be forced to close.  Would you like us to autosave your game before closing?"