changed some EM engine game element names
[rocksndiamonds.git] / src / game_em / emerald.h
index 9dc949fb1e83bbf9958cc8aa17c4c25361fed458..37b75c66e4be259c95280bcb399c2eb87f05b814 100644 (file)
@@ -48,14 +48,10 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 // constant definitions
 // ----------------------------------------------------------------------------
 
-/* define these to use additional elements */
-#define EM_ENGINE_USE_ADDITIONAL_ELEMENTS
+#define CAVE_WIDTH                     MAX_PLAYFIELD_WIDTH
+#define CAVE_HEIGHT                    MAX_PLAYFIELD_HEIGHT
 
-/* with border for steelwall, if needed (when converted from R'n'D level) */
-#define CAVE_WIDTH                     (MAX_PLAYFIELD_WIDTH  + 2)
-#define CAVE_HEIGHT                    (MAX_PLAYFIELD_HEIGHT + 2)
-
-/* with border for Zborder elements (surrounding the visible playfield) */
+/* additional padding for Zborder elements and linked cave buffer columns */
 #define CAVE_BUFFER_XOFFSET            4
 #define CAVE_BUFFER_YOFFSET            2
 #define CAVE_BUFFER_WIDTH              (CAVE_WIDTH  + 2 * CAVE_BUFFER_XOFFSET)
@@ -64,9 +60,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 /*
   -----------------------------------------------------------------------------
   definition of elements used in the Emerald Mine Club engine;
-  the element names have the following properties:
+  the element names (mostly) have the following properties:
   - elements that start with 'X' can be stored in a level file
-  - elements that start with 'Y' indicate moving elements
+  - elements that start with 'Y' indicate moving or active elements
   - elements that end with 'B' are the "backside" of moving elements
   -----------------------------------------------------------------------------
 */
@@ -75,8 +71,8 @@ enum
 {
   Xblank = 0,
 
-  Xacid_splash_e,
-  Xacid_splash_w,
+  Xsplash_e,
+  Xsplash_w,
 
   Xplant,
   Yplant,
@@ -90,8 +86,7 @@ enum
   Xacid_7,
   Xacid_8,
 
-#ifdef EM_ENGINE_USE_ADDITIONAL_ELEMENTS
-  Xfake_acid_1,
+  Xfake_acid_1,                        /* newly added to EM engine */
   Xfake_acid_2,
   Xfake_acid_3,
   Xfake_acid_4,
@@ -99,7 +94,6 @@ enum
   Xfake_acid_6,
   Xfake_acid_7,
   Xfake_acid_8,
-#endif
 
   Xgrass,
   Ygrass_nB,
@@ -376,16 +370,16 @@ enum
   Ydrip_2_sB,
 
   Xwonderwall,
-  XwonderwallB,
+  Ywonderwall,
 
   Xwheel,
-  XwheelB,
+  Ywheel,
 
   Xswitch,
-  XswitchB,
+  Yswitch,
 
   Xbumper,
-  XbumperB,
+  Ybumper,
 
   Xacid_nw,
   Xacid_ne,
@@ -394,13 +388,13 @@ enum
   Xacid_se,
 
   Xfake_blank,
-  Xfake_blankB,
+  Yfake_blank,
 
   Xfake_grass,
-  Xfake_grassB,
+  Yfake_grass,
 
-  Xfake_amoeba,                /* dripper */
-  Xfake_amoebaB,
+  Xfake_amoeba,                        /* dripper */
+  Yfake_amoeba,
 
   Xlenses,
 
@@ -422,15 +416,13 @@ enum
   Xsand_stonesand_4,
   Xsand_stoneout_1,
   Xsand_stoneout_2,
-#ifdef EM_ENGINE_USE_ADDITIONAL_ELEMENTS
-  Xsand_stonesand_quickout_1,
+  Xsand_stonesand_quickout_1,  /* newly added to EM engine */
   Xsand_stonesand_quickout_2,
-#endif
 
-  Xslidewall_ns,       /* growing wall */
-  Yslidewall_ns_blank,
-  Xslidewall_ew,
-  Yslidewall_ew_blank,
+  Xslide_ns,                   /* growing wall */
+  Yslide_ns_blank,
+  Xslide_ew,
+  Yslide_ew_blank,
 
   Xwind_n,
   Xwind_e,
@@ -521,8 +513,7 @@ enum
   Xalpha_arrow_w,
   Xalpha_copyr,
 
-#ifdef EM_ENGINE_USE_ADDITIONAL_ELEMENTS
-  Ykey_1_blank,
+  Ykey_1_blank,                        /* newly added to EM engine */
   Ykey_2_blank,
   Ykey_3_blank,
   Ykey_4_blank,
@@ -534,7 +525,6 @@ enum
   Ymagnify_blank,
   Ygrass_blank,
   Ydirt_blank,
-#endif
 
   Xboom_bug,           /* passed from explode to synchro (linked explosion);
                           transition to explode_normal */
@@ -607,7 +597,7 @@ enum
   SOUND_dirt,          /* player digs into dirt */
   SOUND_acid,          /* acid splashes */
   SOUND_ball,          /* ball places something */
-  SOUND_slidewall,     /* slide wall grows */
+  SOUND_slide,         /* slide wall grows */
   SOUND_wonder,                /* wonderwall is active */
   SOUND_door,          /* player goes thru door (gate) */
   SOUND_exit_open,     /* exit opens */
@@ -637,6 +627,11 @@ struct LEVEL
   int width;                   /* playfield width */
   int height;                  /* playfield height */
 
+  int left;                    /* playfield left edge */
+  int top;                     /* playfield top edge */
+  int right;                   /* playfield right edge */
+  int bottom;                  /* playfield bottom edge */
+
   int time_seconds;            /* available time (seconds) */
   int time_initial;            /* available time (initial) */
   int time;                    /* time remaining (runtime) */