From 8e0c58b2a77c271b485e403cc6edd6ba6e0125cc Mon Sep 17 00:00:00 2001 From: Holger Schemel Date: Thu, 2 Jan 2003 01:57:55 +0100 Subject: [PATCH] rnd-20030102-1-src --- CHANGES | 20 +++++++++++++------- src/conf_gfx.c | 3 --- src/conftime.h | 2 +- src/init.c | 26 ++++++++++++++++++++++---- src/libgame/image.c | 13 +++++++++++++ src/libgame/image.h | 2 ++ src/libgame/sound.c | 8 +++++++- src/main.h | 2 +- 8 files changed, 59 insertions(+), 17 deletions(-) diff --git a/CHANGES b/CHANGES index 1c154bd5..9107d377 100644 --- a/CHANGES +++ b/CHANGES @@ -1,5 +1,5 @@ -Release Version 2.2.0 [?? ??? ????] ------------------------------------ +Pre-Release Version 2.2.0rc1 [31 DEC 2002] +------------------------------------------ - level series artwork now configurable via level series config file - single graphics and animations can now be replaced with different ones (independantly from default image files which may be larger) @@ -7,6 +7,12 @@ Release Version 2.2.0 [?? ??? ????] - element animation length, speed and mode now freely configurable - automatic tape playing function for game engine and level testing - missing steel wall graphic added (thanks to Equinox Tetrachloride) + - added new contributed levels from the following players: + + Abby King (14 levels) + + Andreas Buschbeck (80 levels with complete artwork set) + + David Hutchinson (25 levels with graphics set) + + Equinox Tetrachloride (150 levels guaranteed to be solvable) + + Sylvan Hancock (39 levels) Release Version 2.1.1 [13 AUG 2002] ----------------------------------- @@ -16,7 +22,7 @@ Release Version 2.1.1 [13 AUG 2002] - default keys for "snap field" and "place bomb" fixed for Mac OS X - added new contributed levels from the following players: + Alan Bond - + Gerrit Holl + + Gerrit Holl and Timen van den Berg Release Version 2.1.0 [05 AUG 2002] ----------------------------------- @@ -190,8 +196,8 @@ Version 0.9b2 [21 NOV 1995] [NOT RELEASED] ------------------------------------------ - new game elements -Prerelease Version 0.9b [4 NOV 1995] ------------------------------------- +Pre-Release Version 0.9b [4 NOV 1995] +------------------------------------- - the game is now completely Freeware - the game is now better playable by keyboard (in the last version, the player was making more than @@ -206,6 +212,6 @@ Prerelease Version 0.9b [4 NOV 1995] - FreeBSD sound and joystick support (thanks to Jean-Marc Zucconi) -Prerelease Version 0.9 [23 OCT 1995] ------------------------------------- +Pre-Release Version 0.9 [23 OCT 1995] +------------------------------------- - first (pre)release version diff --git a/src/conf_gfx.c b/src/conf_gfx.c index f35c21cf..523b53ea 100644 --- a/src/conf_gfx.c +++ b/src/conf_gfx.c @@ -1185,7 +1185,6 @@ struct ConfigInfo image_config[] = { "conveyor_belt2_right.active.ypos", "5" }, { "conveyor_belt2_right.active.frames", "8" }, { "conveyor_belt2_right.active.delay", "2" }, - { "conveyor_belt2_right.active.delay", "2" }, { "conveyor_belt2_switch_left", "RocksDC.pcx" }, { "conveyor_belt2_switch_left.xpos", "1" }, { "conveyor_belt2_switch_left.ypos", "12" }, @@ -1226,7 +1225,6 @@ struct ConfigInfo image_config[] = { "conveyor_belt3_right.active.ypos", "8" }, { "conveyor_belt3_right.active.frames", "8" }, { "conveyor_belt3_right.active.delay", "2" }, - { "conveyor_belt3_right.active.delay", "2" }, { "conveyor_belt3_switch_left", "RocksDC.pcx" }, { "conveyor_belt3_switch_left.xpos", "2" }, { "conveyor_belt3_switch_left.ypos", "12" }, @@ -1267,7 +1265,6 @@ struct ConfigInfo image_config[] = { "conveyor_belt4_right.active.ypos", "11" }, { "conveyor_belt4_right.active.frames", "8" }, { "conveyor_belt4_right.active.delay", "2" }, - { "conveyor_belt4_right.active.delay", "2" }, { "conveyor_belt4_switch_left", "RocksDC.pcx" }, { "conveyor_belt4_switch_left.xpos", "3" }, { "conveyor_belt4_switch_left.ypos", "12" }, diff --git a/src/conftime.h b/src/conftime.h index a6ab0657..bb7f1521 100644 --- a/src/conftime.h +++ b/src/conftime.h @@ -1 +1 @@ -#define COMPILE_DATE_STRING "[2002-12-30 03:03]" +#define COMPILE_DATE_STRING "[2003-01-02 01:11]" diff --git a/src/init.c b/src/init.c index 76bf20c3..b1f5af0e 100644 --- a/src/init.c +++ b/src/init.c @@ -876,16 +876,34 @@ static void InitGraphicInfo() if (src_x < 0 || src_y < 0 || src_x + TILEX > src_bitmap->width || src_y + TILEY > src_bitmap->height) - Error(ERR_EXIT, "InitGraphicInfo: first frame of graphic animation object %d outside of image bitmap file '%s' (%d,%d)", - i, src_bitmap->source_filename, src_x, src_y); + { + Error(ERR_RETURN, "custom artwork configuration error:"); + Error(ERR_RETURN, "- config file: '%s'", + getImageConfigFilename()); + Error(ERR_RETURN, "- config token: '%s'", + getTokenFromImageID(i)); + Error(ERR_RETURN, "- image file: '%s'", + src_bitmap->source_filename); + Error(ERR_EXIT, "error: first animation frame out of bounds (%d,%d)", + src_x, src_y); + } last_frame = new_graphic_info[i].anim_frames - 1; getGraphicSource(i, last_frame, &src_bitmap, &src_x, &src_y); if (src_x < 0 || src_y < 0 || src_x + TILEX > src_bitmap->width || src_y + TILEY > src_bitmap->height) - Error(ERR_EXIT, "InitGraphicInfo: last frame of graphic animation object %d outside of image bitmap file '%s' (%d,%d)", - i, src_bitmap->source_filename, src_x, src_y); + { + Error(ERR_RETURN, "custom artwork configuration error:"); + Error(ERR_RETURN, "- config file: '%s'", + getImageConfigFilename()); + Error(ERR_RETURN, "- config token: '%s'", + getTokenFromImageID(i)); + Error(ERR_RETURN, "- image file: '%s'", + src_bitmap->source_filename); + Error(ERR_EXIT, "error: last animation frame out of bounds (%d,%d)", + src_x, src_y); + } } } diff --git a/src/libgame/image.c b/src/libgame/image.c index 8e69de54..a649e40a 100644 --- a/src/libgame/image.c +++ b/src/libgame/image.c @@ -14,6 +14,7 @@ #include "image.h" #include "pcx.h" #include "misc.h" +#include "setup.h" /* ========================================================================= */ @@ -707,6 +708,18 @@ Bitmap *getBitmapFromImageID(int graphic) return img_info[graphic]->bitmap; } +char *getTokenFromImageID(int graphic) +{ + struct FileInfo *file_list = (struct FileInfo *)image_info->file_list; + + return file_list[graphic].token; +} + +char *getImageConfigFilename() +{ + return getCustomArtworkConfigFilename(image_info->type); +} + void InitImageList(struct ConfigInfo *config_list, struct ConfigInfo *config_suffix_list, int num_file_list_entries) diff --git a/src/libgame/image.h b/src/libgame/image.h index 342b2536..75c9ad18 100644 --- a/src/libgame/image.h +++ b/src/libgame/image.h @@ -74,6 +74,8 @@ int Read_PCX_to_Pixmap(Display *, Window, GC, char *, Pixmap *, Pixmap *); struct FileInfo *getCurrentImageList(); Bitmap *getBitmapFromImageID(int); +char *getTokenFromImageID(int); +char *getImageConfigFilename(); void InitImageList(struct ConfigInfo *, struct ConfigInfo *, int); void ReloadCustomImages(); void FreeAllImages(); diff --git a/src/libgame/sound.c b/src/libgame/sound.c index 14aacba0..835adab8 100644 --- a/src/libgame/sound.c +++ b/src/libgame/sound.c @@ -956,11 +956,16 @@ static void Mixer_InsertSound(SoundControl snd_ctrl) unsigned long playing_current = Counter(); int longest = 0, longest_nr = audio.first_sound_channel; +#if 0 +#if DEBUG + /* print some debugging information about audio channel usage */ for (i=audio.first_sound_channel; i