X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fmain.h;h=b3a28ffa772454a7ed0e0add2e10873d2a4b1260;hb=35a55f8aa20694a478ab6e70057167014661469b;hp=273052ecb6fe41575b3fca7ee6b255d6cc6d3ff6;hpb=66a22ebb170de96a59c015e49b15d95419fd87ae;p=rocksndiamonds.git diff --git a/src/main.h b/src/main.h index 273052ec..b3a28ffa 100644 --- a/src/main.h +++ b/src/main.h @@ -26,6 +26,7 @@ #include "conf_gfx.h" /* include auto-generated data structure definitions */ #include "conf_snd.h" /* include auto-generated data structure definitions */ +#include "conf_mus.h" /* include auto-generated data structure definitions */ #define IMG_UNDEFINED (-1) #define IMG_EMPTY IMG_EMPTY_SPACE @@ -35,6 +36,7 @@ #define IMG_CUSTOM_START IMG_CUSTOM_1 #define SND_UNDEFINED (-1) +#define MUS_UNDEFINED (-1) #define WIN_XSIZE 672 #define WIN_YSIZE 560 @@ -914,29 +916,32 @@ #define ACTION_EMPTYING 22 #define ACTION_CHANGING 23 #define ACTION_EXPLODING 24 -#define ACTION_DYING 25 -#define ACTION_TURNING 26 -#define ACTION_TURNING_FROM_LEFT 27 -#define ACTION_TURNING_FROM_RIGHT 28 -#define ACTION_TURNING_FROM_UP 29 -#define ACTION_TURNING_FROM_DOWN 30 -#define ACTION_OTHER 31 - -#define NUM_ACTIONS 32 +#define ACTION_BORING 25 +#define ACTION_SLEEPING 26 +#define ACTION_DYING 27 +#define ACTION_TURNING 28 +#define ACTION_TURNING_FROM_LEFT 29 +#define ACTION_TURNING_FROM_RIGHT 30 +#define ACTION_TURNING_FROM_UP 31 +#define ACTION_TURNING_FROM_DOWN 32 +#define ACTION_OTHER 33 + +#define NUM_ACTIONS 34 /* values for special image configuration suffixes (must match game mode) */ -#define GFX_SPECIAL_ARG_MAIN 0 -#define GFX_SPECIAL_ARG_LEVELS 1 -#define GFX_SPECIAL_ARG_SCORES 2 -#define GFX_SPECIAL_ARG_EDITOR 3 -#define GFX_SPECIAL_ARG_INFO 4 -#define GFX_SPECIAL_ARG_SETUP 5 -#define GFX_SPECIAL_ARG_PLAYING 6 -#define GFX_SPECIAL_ARG_DOOR 7 -#define GFX_SPECIAL_ARG_PREVIEW 8 -#define GFX_SPECIAL_ARG_CRUMBLED 9 +#define GFX_SPECIAL_ARG_DEFAULT 0 +#define GFX_SPECIAL_ARG_MAIN 1 +#define GFX_SPECIAL_ARG_LEVELS 2 +#define GFX_SPECIAL_ARG_SCORES 3 +#define GFX_SPECIAL_ARG_EDITOR 4 +#define GFX_SPECIAL_ARG_INFO 5 +#define GFX_SPECIAL_ARG_SETUP 6 +#define GFX_SPECIAL_ARG_PLAYING 7 +#define GFX_SPECIAL_ARG_DOOR 8 +#define GFX_SPECIAL_ARG_PREVIEW 9 +#define GFX_SPECIAL_ARG_CRUMBLED 10 -#define NUM_SPECIAL_GFX_ARGS 10 +#define NUM_SPECIAL_GFX_ARGS 11 /* values for image configuration suffixes */ @@ -977,8 +982,13 @@ #define NUM_SND_ARGS 1 -/* values for font configuration */ +/* values for music configuration suffixes */ +#define MUS_ARG_MODE_LOOP 0 + +#define NUM_MUS_ARGS 1 + +/* values for font configuration */ #define FONT_INITIAL_1 0 #define FONT_INITIAL_2 1 #define FONT_INITIAL_3 2 @@ -1016,29 +1026,32 @@ #define NUM_INITIAL_FONTS 4 /* values for game_status (must match special image configuration suffixes) */ -#define GAME_MODE_MAIN 0 -#define GAME_MODE_LEVELS 1 -#define GAME_MODE_SCORES 2 -#define GAME_MODE_EDITOR 3 -#define GAME_MODE_INFO 4 -#define GAME_MODE_SETUP 5 -#define GAME_MODE_PLAYING 6 -#define GAME_MODE_PSEUDO_DOOR 7 -#define GAME_MODE_PSEUDO_PREVIEW 8 -#define GAME_MODE_PSEUDO_CRUMBLED 9 +#define GAME_MODE_DEFAULT 0 +#define GAME_MODE_MAIN 1 +#define GAME_MODE_LEVELS 2 +#define GAME_MODE_SCORES 3 +#define GAME_MODE_EDITOR 4 +#define GAME_MODE_INFO 5 +#define GAME_MODE_SETUP 6 +#define GAME_MODE_PLAYING 7 +#define GAME_MODE_PSEUDO_DOOR 8 +#define GAME_MODE_PSEUDO_PREVIEW 9 +#define GAME_MODE_PSEUDO_CRUMBLED 10 /* there are no special config file suffixes for these modes */ -#define GAME_MODE_PSEUDO_TYPENAME 10 -#define GAME_MODE_QUIT 11 +#define GAME_MODE_PSEUDO_TYPENAME 11 +#define GAME_MODE_QUIT 12 + +/* special definitions currently only used for custom artwork configuration */ +#define MUSIC_PREFIX_BACKGROUND 0 +#define NUM_MUSIC_PREFIXES 1 +#define MAX_LEVELS 1000 + #define PROGRAM_VERSION_MAJOR 3 #define PROGRAM_VERSION_MINOR 0 -#define PROGRAM_VERSION_PATCH 7 -#define PROGRAM_VERSION_BUILD 1 - -#if 0 -#define PROGRAM_VERSION_STRING "3.0.7" -#endif +#define PROGRAM_VERSION_PATCH 8 +#define PROGRAM_VERSION_BUILD 0 #define PROGRAM_TITLE_STRING "Rocks'n'Diamonds" #define PROGRAM_AUTHOR_STRING "Holger Schemel" @@ -1110,6 +1123,9 @@ struct MenuInfo int list_size_default; int list_size[NUM_SPECIAL_GFX_ARGS]; + + int sound[NUM_SPECIAL_GFX_ARGS]; + int music[NUM_SPECIAL_GFX_ARGS]; }; struct DoorInfo @@ -1186,6 +1202,11 @@ struct PlayerInfo int inventory_size; }; +struct LevelSetInfo +{ + int music[MAX_LEVELS]; +}; + struct LevelInfo { int file_version; /* file format version the level is stored with */ @@ -1451,6 +1472,17 @@ struct SoundInfo boolean loop; }; +struct MusicInfo +{ + boolean loop; +}; + +struct MusicPrefixInfo +{ + char *prefix; + boolean is_loop_music; +}; + struct ElementActionInfo { char *suffix; @@ -1544,6 +1576,7 @@ extern boolean network_player_action_received; extern int graphics_action_mapping[]; +extern struct LevelSetInfo levelset; extern struct LevelInfo level, level_template; extern struct PlayerInfo stored_player[], *local_player; extern struct HiScore highscore[]; @@ -1558,9 +1591,15 @@ extern struct ElementDirectionInfo element_direction_info[]; extern struct SpecialSuffixInfo special_suffix_info[]; extern struct TokenIntPtrInfo image_config_vars[]; extern struct FontInfo font_info[]; +extern struct MusicPrefixInfo music_prefix_info[]; extern struct GraphicInfo *graphic_info; extern struct SoundInfo *sound_info; -extern struct ConfigInfo image_config[], sound_config[]; -extern struct ConfigInfo image_config_suffix[], sound_config_suffix[]; +extern struct MusicInfo *music_info; +extern struct ConfigInfo image_config[]; +extern struct ConfigInfo sound_config[]; +extern struct ConfigInfo music_config[]; +extern struct ConfigInfo image_config_suffix[]; +extern struct ConfigInfo sound_config_suffix[]; +extern struct ConfigInfo music_config_suffix[]; #endif /* MAIN_H */