rnd-20090719-1-src
[rocksndiamonds.git] / src / game_sp / MainGameLoop.c
index 9aa59aacf86a89ad72d1bd8b88031d5d14130494..2852dd0639494e48b662ddb0b8f50c4adbadb4d4 100644 (file)
@@ -4,7 +4,8 @@
 
 #include "MainGameLoop.h"
 
-static char *VB_Name = "modMainGameLoop";
+// static char *VB_Name = "modMainGameLoop";
+
 // --- Option Explicit
 
 int GameLoopRunning;
@@ -25,7 +26,8 @@ int subMainGameLoop()
 {
   int subMainGameLoop;
 
-  int al, bx;
+  // int al, bx;
+  int bx;
   TickCountObject Clock;
   currency LastFrame;
 
@@ -61,10 +63,12 @@ int subMainGameLoop()
   // This was a bug in the original Supaplex: sometimes red disks could not
   // be released.  This happened If Murphy was killed DURING a red disk release
   // and the next try started.
+
   RedDiskReleasePhase = 0; // (re-)enable red disk release
   UpdatedFlag = 0;
   GameLoopRunning = 1;
   LevelStatus = 0;
+
   // ----------------------------------------------------------------------------
   // --------------------- START OF GAME-BUSY LOOP ------------------------------
   // ----------------------------------------------------------------------------
@@ -112,8 +116,10 @@ locRepeatMainGameLoop:                           // start repeating game loop
   //    Call subConvertToEasySymbols ' Convert to easy symbols
   //  End If
 
-loc_g_186F:
+  // loc_g_186F:
+
   subProcessKeyboardInput();                 // Check keyboard, act on keys
+
   // 'HACK:
   //  TimerVar = TimerVar + 1
   //  DoEvents
@@ -123,18 +129,23 @@ loc_g_186F:
 
   // ----------------------------------------------------------------------------
   //
+
   subDoGameStuff();                 // do all game stuff
+
   //
   // ----------------------------------------------------------------------------
 
   //  Call subDisplayPlayingTime                 ' playing time on screen
+
   subCheckRestoreRedDiskCountDisplay();    // Restore panel: red-disk hole
 
   subRedDiskReleaseExplosion();       // Red Disk release and explode
   subFollowUpExplosions();  // every explosion may cause up to 8 following explosions
 
   bx = subCalculateScreenScrollPos();     // calculate screen start addrs
+
   ScreenPosition = bx;
+
   // Now new X and new Y are calculated, and bx = screen position = ScreenPosition
   data_h_Ytmp = ScreenScrollYPos; // copy Y for next soft scroll
   data_h_Xtmp = ScreenScrollXPos; // copy X for next soft scroll