X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fgame_em%2Fmain_em.h;h=920498ee0feb65f46f58ef57c6e1aaa61efefe05;hb=f2b486caeabc0548dfa744c1569496c087b7420f;hp=38320ef693fc0637e9a89d959767fb41e01d9ebf;hpb=6f6af05b1d4b9671bc115ab9ab2fa3b9d516a652;p=rocksndiamonds.git diff --git a/src/game_em/main_em.h b/src/game_em/main_em.h index 38320ef6..920498ee 100644 --- a/src/game_em/main_em.h +++ b/src/game_em/main_em.h @@ -1,6 +1,9 @@ #ifndef MAIN_EM_H #define MAIN_EM_H +#include "game_em.h" + + /* 2000-07-30T11:06:03Z ---------------------------------------------------- */ #define EM_MAX_CAVE_WIDTH 102 @@ -10,6 +13,17 @@ #define EM_ENGINE_BAD_ROLL #define EM_ENGINE_BAD_SPRING + +/* + ----------------------------------------------------------------------------- + definition of elements used in the Emerald Mine Club engine; + the element names have the following properties: + - elements that start with an 'X' can be stored in a level file; + - elements that start with an 'Y' indicate moving elements; + - elements that end with a 'B' are the "backside" of a moving element. + ----------------------------------------------------------------------------- +*/ + enum { Xblank = 0, /* still */ @@ -449,9 +463,9 @@ enum SAMPLE_acid, /* acid splashes */ SAMPLE_ball, /* ball places something */ SAMPLE_grow, /* growing wall grows */ - SAMPLE_wonder, /* wonderwall moves (is active) */ - SAMPLE_door, /* player goes thru door */ - SAMPLE_exit, /* player goes in exit */ + SAMPLE_wonder, /* wonderwall is active */ + SAMPLE_door, /* player goes thru door (gate) */ + SAMPLE_exit, /* player goes into exit */ SAMPLE_dynamite, /* player places dynamite */ SAMPLE_tick, /* dynamite ticks */ SAMPLE_press, /* player presses wheel/wind/switch */ @@ -471,10 +485,14 @@ struct LEVEL unsigned int width; /* playfield width */ unsigned int height; /* playfield height */ - unsigned int time_initial; /* time remaining (initial) */ + + unsigned int time_seconds; /* available time (seconds) */ + unsigned int time_initial; /* available time (initial) */ unsigned int time; /* time remaining (runtime) */ + unsigned int required_initial; /* emeralds needed (initial) */ unsigned int required; /* emeralds needed (runtime) */ + unsigned int score; /* score */ /* fill in all below /every/ time you read a level */ @@ -560,12 +578,36 @@ struct PLAYER unsigned joy_spin:1; }; + +/* ------------------------------------------------------------------------- */ +/* definitions and structures for use by the main game functions */ +/* ------------------------------------------------------------------------- */ + +/* values for native Emerald Mine game version */ +#define FILE_VERSION_EM_V3 3 +#define FILE_VERSION_EM_V4 4 +#define FILE_VERSION_EM_V5 5 +#define FILE_VERSION_EM_V6 6 + +#define FILE_VERSION_EM_ACTUAL FILE_VERSION_EM_V6 + struct LevelInfo_EM { + int file_version; + struct LEVEL *lev; struct PLAYER *ply1, *ply2; unsigned short cave[EM_MAX_CAVE_WIDTH][EM_MAX_CAVE_HEIGHT]; }; +struct GraphicInfo_EM +{ + Bitmap *bitmap; + int src_x, src_y; + int src_offset_x, src_offset_y; + int dst_offset_x, dst_offset_y; + int width, height; +}; + #endif /* MAIN_EM_H */