diff mm7_4.cpp @ 162:8ff698000225

Слияние
author Ritor1
date Fri, 30 Nov 2012 18:14:09 +0600
parents 3ee6e30b7943 062e8a8e09bc
children 62585ad07024
line wrap: on
line diff
--- a/mm7_4.cpp	Fri Nov 30 18:13:54 2012 +0600
+++ b/mm7_4.cpp	Fri Nov 30 18:14:09 2012 +0600
@@ -5366,10 +5366,10 @@
   Player *pPlayer;
   const char *pSkillName;
 
-  uColor1 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xD1u, 0xBBu, 0x61u);
-  uColorTeal = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0, 0xF7u, 0xF7u);
-  uColorGreen = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0, 0xFFu, 0);
-  uColorWhite = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0xFFu, 0xFFu);
+  uColor1 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xD1, 0xBB, 0x61);
+  uColorTeal = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0, 0xF7, 0xF7);
+  uColorGreen = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0, 0xFF, 0);
+  uColorWhite = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFF, 0xFF, 0xFF);
   pRenderer->BeginScene();
   pRenderer->DrawTextureRGB(0, 0, &pTexture_PCX);
   uPlayerCreationUI_SkySliderPos = (GetTickCount() % 12800) / 20;
@@ -5449,7 +5449,7 @@
   {
     Str = pPlayer->pName;
 	pGUIWindow_CurrentMenu->DrawText(pFontCreate, pOrder + 73, 100, 0, pClassNames[(unsigned __int8)pPlayer->uClass], 0, 0, 0);
-    pRenderer->DrawTextureTransparent(pOrder + 77, 50u, pTexture_IC_KNIGHT[pPlayer->uClass/4]);
+    pRenderer->DrawTextureTransparent(pOrder + 77, 50, pTexture_IC_KNIGHT[pPlayer->uClass/4]);
     v11 = pGUIWindow_CurrentMenu->field_40;
     if ( v11 && (v12 = pGUIWindow_CurrentMenu->ptr_1C, v12 == v124) )
     {
@@ -5485,7 +5485,7 @@
           }
           if ( v120 && v126 != v120 )
             strcpy(Str, (const char *)pKeyActionMap->pPressedKeysBuffer);
-          pGUIWindow_CurrentMenu->DrawTextInRect(pFontCreate, pOrder, 0x7Cu, 0, Str, 130, 0);
+          pGUIWindow_CurrentMenu->DrawTextInRect(pFontCreate, pOrder, 0x7C, 0, Str, 130, 0);
           *((short *)pPlayer->pName + 3323) = 1;
         }
       }
@@ -5872,7 +5872,7 @@
   Player *v11; // esi@38
   signed int uSpellBookPageCount; // ecx@40
   int v13; // eax@40
-  signed int v14; // eax@45
+  signed int uSkillIdx; // eax@45
   int v15; // eax@70
   signed int v16; // ecx@70
   unsigned int v18; // [sp-4h] [bp-84h]@48
@@ -5994,13 +5994,14 @@
   }
   while ( (signed int)v1 < 32 );
   item.Reset();
-  v10 = (char *)&pParty->pPlayers[0].sResMagicBase;
-  for ( pPlayer = &pParty->pPlayers[0];  (signed int)v10 < (signed int)((char *)&pParty->field_871C[455] + 2); pPlayer++)
-  {
-    v11 = pPlayer;
+  //v10 = (char *)&pParty->pPlayers[0].sResMagicBase;
+  for ( pPlayer = &pParty->pPlayers[0];  pPlayer < &pParty->pPlayers[4]; pPlayer++)
+  {
+    //v11 = pPlayer;
     if ( !pPlayer->uClass )
       pPlayer->sResMagicBase = 10;
-    *((short *)v10 + 400) = 0;
+    //*((short *)v10 + 400) = 0;
+	pPlayer->pPlayerBuffs[22].uExpireTime = 0;
     uSpellBookPageCount = 0;
 	for ( int i = 0; i < 9; i++)
     {
@@ -6009,14 +6010,14 @@
     }
     pPlayer->pNumSpellBookPage = uSpellBookPageCount;
     pItemsTable->GenerateItem(2, 40, &item);
-    pPlayer->AddItem2(0xFFFFFFFFu, &item);
-    v14 = 0;
+    pPlayer->AddItem2(-1, &item);
+    uSkillIdx = 0;
     v24.y = 0;
     do
     {
-      if ( pPlayer->pActiveSkills[v14] )
-      {
-        switch ( v14 )
+      if ( pPlayer->pActiveSkills[uSkillIdx] )
+      {
+        switch ( uSkillIdx )
         {
           case 0:
             v18 = 61;
@@ -6106,13 +6107,13 @@
          }
         pPlayer->sHealth = pPlayer->GetMaxHealth();
         pPlayer->sMana = pPlayer->GetMaxMana();
-        v14 = v24.y;
-      }
-      ++v14;
-      v24.y = v14;
-    }
-    while ( v14 < 37 );
-    v10 += 6972;
+        uSkillIdx = v24.y;
+      }
+      ++uSkillIdx;
+      v24.y = uSkillIdx;
+    }
+    while ( uSkillIdx < 37 );
+    //v10 += 6972;
 	//pPlayer++;
   }
   //while ( (signed int)v10 < (signed int)((char *)&pParty->field_871C[455] + 2) );