diff Game.cpp @ 2067:2e08496c40c2

Слияние
author Ritor1
date Tue, 03 Dec 2013 09:22:28 +0600
parents b2a434d65344
children 259df09dfb50
line wrap: on
line diff
--- a/Game.cpp	Tue Dec 03 09:22:24 2013 +0600
+++ b/Game.cpp	Tue Dec 03 09:22:28 2013 +0600
@@ -304,7 +304,6 @@
   if (bLoading)
   {
     pParty->Reset();
-    dword_6BE340 = 0;
     uGameState = GAME_STATE_PLAYING;
     LoadGame(uLoadGameUI_SelectedSlot);
   }
@@ -333,8 +332,7 @@
     }
     DoPrepareWorld(bLoading, 1);
     pEventTimer->Resume();
-    dword_6BE364_game_settings_1 |= 0x80;
-    dword_6BE340 = 2;
+    dword_6BE364_game_settings_1 |= GAME_SETTINGS_0080_SKIP_USER_INPUT_THIS_FRAME;
     // uGame_if_0_else_ui_id__11_save__else_load__8_drawSpellInfoPopup__22_final_window__26_keymapOptions__2_options__28_videoOptions = 0;
     pCurrentScreen = SCREEN_GAME;
 
@@ -351,7 +349,7 @@
         TranslateMessage(&Msg);
         DispatchMessageA(&Msg);
       }
-      if (dword_6BE364_game_settings_1 & 0x0100 )
+      if (dword_6BE364_game_settings_1 & GAME_SETTINGS_APP_INACTIVE)
       {
         WaitMessage();
         continue;
@@ -382,10 +380,9 @@
       {
         if ( !pEventTimer->bTackGameTime )
           _494035_timed_effects__water_walking_damage__etc();
-        if ( dword_6BE364_game_settings_1 & 1 )
-        {
-          dword_6BE364_game_settings_1 &= 0xFFFFFFFEu;
-        }
+
+        if (dword_6BE364_game_settings_1 & GAME_SETTINGS_0001)
+          dword_6BE364_game_settings_1 &= ~GAME_SETTINGS_0001;
         else
         {
           UpdateActorAI();
@@ -547,7 +544,6 @@
     }
     while (!game_finished);
 
-    dword_6BE340 = 0;
     pEventTimer->Pause();
     ResetCursor_Palettes_LODs_Level_Audio_SFT_Windows();
     if ( uGameState == GAME_STATE_LOADING_GAME )
@@ -754,7 +750,6 @@
     WriteWindowsRegistryInt("window X", window->GetX());
     WriteWindowsRegistryInt("window Y", window->GetY());
   }
-  window->Delete();
   WriteWindowsRegistryInt("valAlwaysRun", bAlwaysRun);
   pItemsTable->Release();
   pNPCStats->Release();
@@ -3049,7 +3044,7 @@
           sub_42FBDD();
           SaveGame(1, 0);
           strcpy(pCurrentMapName, pMapStats->pInfos[uHouse_ExitPic].pFilename);
-          dword_6BE364_game_settings_1 |= 1;
+          dword_6BE364_game_settings_1 |= GAME_SETTINGS_0001;
           uGameState = GAME_STATE_2;
           //v53 = p2DEvents_minus1_::30[26 * (unsigned int)ptr_507BC0->ptr_1C];
           v53 = p2DEvents[(unsigned int)window_SpeakInHouse->ptr_1C - 1]._quest_related;
@@ -3157,7 +3152,7 @@
               SaveGame(1, 0);
               OnMapLeave();
               strcpy(pCurrentMapName, (const char *)&pGames_LOD->pSubIndices[pPlayer9->pInstalledBeacons[uMessageParam].SaveFileID]);
-              dword_6BE364_game_settings_1 |= 1;
+              dword_6BE364_game_settings_1 |= GAME_SETTINGS_0001;
               uGameState = GAME_STATE_2;
               _5B65A8_npcdata_uflags_or_other = pPlayer9->pInstalledBeacons[uMessageParam].PartyPos_X;
               _5B65AC_npcdata_fame_or_other = pPlayer9->pInstalledBeacons[uMessageParam].PartyPos_Y;
@@ -3238,7 +3233,7 @@
                   {
                     SaveGame(1, 0);
                     OnMapLeave();
-                    dword_6BE364_game_settings_1 |= 1;
+                    dword_6BE364_game_settings_1 |= GAME_SETTINGS_0001;
                     uGameState = GAME_STATE_2;
                     strcpy(pCurrentMapName, pMapStats->pInfos[TownPortalList[uMessageParam].uMapInfoID].pFilename);
                     dword_5B65C0 = 1;
@@ -3421,7 +3416,7 @@
               if ( (signed int)pNPCData3 < (signed int)pNPCData4 )
               {
                 strcpy(pCurrentMapName, (const char *)&pGames_LOD->pSubIndices[(int)pNPCData3]);
-                dword_6BE364_game_settings_1 |= 1u;
+                dword_6BE364_game_settings_1 |= GAME_SETTINGS_0001;
                 uGameState = GAME_STATE_2;
                 OnMapLeave();
                 continue;
@@ -4608,7 +4603,7 @@
             ModalWindow_Release();
             break;
           }
-          if ( !(BYTE1(dword_6BE364_game_settings_1) & 0x40) )
+          if ( !(dword_6BE364_game_settings_1 & GAME_SETTINGS_4000))
             break;
           v15 = 1;
           pVideoPlayer->bStopBeforeSchedule = 1;