changed most comments from C to C++ style for BD engine code
[rocksndiamonds.git] / src / game_bd / bd_gameplay.h
index b87a3aeabddf4afc48ac76c6a3c1c56e407164f7..aa9a48de387be6ec127c0e09cc5853798353800f 100644 (file)
 #ifndef BD_GAMEPLAY_H
 #define BD_GAMEPLAY_H
 
-#include <glib.h>
-
 #include "bd_cave.h"
 
 
 #define GAME_INT_INVALID               -100
 
-/* prepare cave, gfx buffer */
+// prepare cave, gfx buffer
 #define GAME_INT_LOAD_CAVE             -73
 
-/* show description/note of cave. */
+// show description/note of cave.
 #define GAME_INT_SHOW_STORY            -72
 
-/* waiting fire button after showing the story. */
+// waiting fire button after showing the story.
 #define GAME_INT_SHOW_STORY_WAIT       -71
 
-/* start uncovering */
+// start uncovering
 #define GAME_INT_START_UNCOVER         -70
 
-/* ...70 frames until full uncover... */
+// ...70 frames until full uncover...
 #define GAME_INT_UNCOVER_ALL           -1
 
-/* normal running state. */
+// normal running state.
 #define GAME_INT_CAVE_RUNNING          0
 
-/* add points for remaining time */
+// add points for remaining time
 #define GAME_INT_CHECK_BONUS_TIME      1
 
-/* ...2..99 = wait and do nothing, after adding time */
+// ...2..99 = wait and do nothing, after adding time
 #define GAME_INT_WAIT_BEFORE_COVER     2
 
-/* start covering */
+// start covering
 #define GAME_INT_COVER_START           100
 
-/* ... 8 frames of cover animation */
+// ... 8 frames of cover animation
 #define GAME_INT_COVER_ALL             108
 
 
 typedef struct _gd_game
 {
-  GdString player_name;     /* Name of player */
-  int player_score;         /* Score of player */
-  int player_lives;         /* Remaining lives of player */
+  GdString player_name;         // Name of player
+  int player_score;             // Score of player
+  int player_lives;             // Remaining lives of player
 
   GdDirection player_move;
   boolean player_move_stick;
   boolean player_fire;
 
-  GdCave *cave;             /* Copy of the cave. This is the iterated, changed (ruined...) one */
-  GdCave *original_cave;    /* original cave from caveset. used to record highscore */
+  GdCave *cave;                 // Copy of the cave. This is the iterated, changed (ruined...) one
+  GdCave *original_cave;        // original cave from caveset. used to record highscore
 
-  boolean out_of_window;   /* will be set to true, if player is not visible in the window, and we have to wait for scrolling */
+  boolean out_of_window;        // will be set to true, if player is not visible in the window,
+                                // and we have to wait for scrolling
 
-  int cave_num;             /* actual playing cave number */
-  int cave_score;           /* score collected in this cave */
-  int level_num;            /* actual playing level */
-  int bonus_life_flash;     /* different kind of flashing, for bonus life */
+  int cave_num;                 // actual playing cave number
+  int cave_score;               // score collected in this cave
+  int level_num;                // actual playing level
+  int bonus_life_flash;         // different kind of flashing, for bonus life
 
-  int state_counter;        /* counter used to control the game flow, rendering of caves */
+  int state_counter;            // counter used to control the game flow, rendering of caves
   int **element_buffer;
   int **last_element_buffer;
   int **dir_buffer;
-  int **gfx_buffer;         /* contains the indexes to the cells; created by *start_level, deleted by *stop_game */
+  int **gfx_buffer;             // contains the indexes to the cells;
+                                // created by *start_level, deleted by *stop_game
   int itercycle;
   int itermax;
   int itermax_last;
@@ -88,7 +88,7 @@ typedef struct _gd_game
   int milliseconds_anim;
 
   int replay_no_more_movements;
-  boolean show_story;      /* variable to remember that the story for a particular cave was already shown. */
+  boolean show_story;          // to remember that story for a particular cave was already shown.
 } GdGame;
 
 typedef enum _gd_game_state
@@ -99,7 +99,7 @@ typedef enum _gd_game_state
   GD_GAME_CAVE_LOADED,
   GD_GAME_NOTHING,
   GD_GAME_LABELS_CHANGED,
-  GD_GAME_TIMEOUT_NOW,      /* this signals the moment of time out */
+  GD_GAME_TIMEOUT_NOW,          // this signals the moment of time out
   GD_GAME_NO_MORE_LIVES,
   GD_GAME_STOP,
   GD_GAME_GAME_OVER,