rnd-20030719-1-src
authorHolger Schemel <info@artsoft.org>
Fri, 18 Jul 2003 22:40:48 +0000 (00:40 +0200)
committerHolger Schemel <info@artsoft.org>
Sat, 30 Aug 2014 08:42:44 +0000 (10:42 +0200)
CHANGES
Makefile
src/conftime.h
src/init.c
src/libgame/sdl.c
src/main.h

diff --git a/CHANGES b/CHANGES
index 4a745648e37a580b4c143cae620fcb7546bae116..71822bc7008a6d86b75590d08e86d9c87e558cbd 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,7 +1,11 @@
-Pre-Release Version 2.2.0rc7 [?? ??? ????]
+Pre-Release Version 2.2.0rc8 [?? ??? ????]
+------------------------------------------
+
+Pre-Release Version 2.2.0rc7 [17 JUL 2003]
 ------------------------------------------
        - fixed bug when picking element in the editor
        - added more custom elements properties
+       - fixed bugs when smashing penguin
 
 Pre-Release Version 2.2.0rc6 [22 APR 2003]
 ------------------------------------------
index bdd285b5e775938c501bd4dd53fd57723470f574..0c22aefb3fa9bcb1696e9a9c507b3dde989eaf00 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -49,8 +49,8 @@ CROSS_PATH_WIN32=/usr/local/cross-tools/i386-mingw32msvc
 SRC_DIR = src
 MAKE_CMD = $(MAKE) -C $(SRC_DIR)
 
-DEFAULT_TARGET = x11
-DEFAULT_TARGET = sdl
+DEFAULT_TARGET = x11
+DEFAULT_TARGET = sdl
 
 all:
        @$(MAKE_CMD) TARGET=$(DEFAULT_TARGET)
index d62019f5c495d50192ea87f9b228a094a4ae221f..dba096550f6d6e97dbbefd2e1e6e9fcb789bda23 100644 (file)
@@ -1 +1 @@
-#define COMPILE_DATE_STRING "[2003-07-17 03:44]"
+#define COMPILE_DATE_STRING "[2003-07-19 00:38]"
index 839551baf35d51968493d295071366a34d2f2220..19e3230bc0eafec2ad75d6756dfd1d6d6d441b33 100644 (file)
@@ -3096,19 +3096,23 @@ void ReloadCustomArtwork()
   char *mus_new_identifier = artwork.mus_current->identifier;
   boolean redraw_screen = FALSE;
 
+#if 0
   if (leveldir_current_identifier == NULL)
     leveldir_current_identifier = leveldir_current->identifier;
+#endif
 
-#if 0
+#if 1
   printf("CURRENT GFX: '%s' ['%s']\n", artwork.gfx_current->identifier,
         leveldir_current->graphics_set);
   printf("CURRENT LEV: '%s' / '%s'\n", leveldir_current_identifier,
         leveldir_current->identifier);
 #endif
 
-#if 0
+#if 1
   printf("graphics --> '%s' ('%s')\n",
         artwork.gfx_current_identifier, artwork.gfx_current->filename);
+#endif
+#if 0
   printf("sounds   --> '%s' ('%s')\n",
         artwork.snd_current_identifier, artwork.snd_current->filename);
   printf("music    --> '%s' ('%s')\n",
@@ -3126,16 +3130,48 @@ void ReloadCustomArtwork()
     char *identifier_old = leveldir_current_identifier;
     char *identifier_new = leveldir_current->identifier;
 
-    if (getTreeInfoFromIdentifier(artwork.gfx_first, identifier_old) !=
-       getTreeInfoFromIdentifier(artwork.gfx_first, identifier_new))
+#if 1
+    printf("::: 1: ['%s'] '%s', '%s' [%lx, %lx]\n",
+          gfx_new_identifier, identifier_old, identifier_new,
+          getTreeInfoFromIdentifier(artwork.gfx_first, identifier_old),
+          getTreeInfoFromIdentifier(artwork.gfx_first, identifier_new));
+#endif
+
+#if 0
+    if (getTreeInfoFromIdentifier(artwork.gfx_first, identifier_new) == NULL)
+      gfx_new_identifier = GRAPHICS_SUBDIR;
+    else if (getTreeInfoFromIdentifier(artwork.gfx_first, identifier_old) !=
+            getTreeInfoFromIdentifier(artwork.gfx_first, identifier_new))
+      gfx_new_identifier = identifier_new;
+#else
+    if (getTreeInfoFromIdentifier(artwork.gfx_first, identifier_new) == NULL)
+      gfx_new_identifier = setup.graphics_set;
+    else
       gfx_new_identifier = identifier_new;
-    if (getTreeInfoFromIdentifier(artwork.snd_first, identifier_old) !=
-       getTreeInfoFromIdentifier(artwork.snd_first, identifier_new))
+#endif
+
+#if 1
+    if (leveldir_current_identifier == NULL)
+      leveldir_current_identifier = leveldir_current->identifier;
+#endif
+
+    if (getTreeInfoFromIdentifier(artwork.snd_first, identifier_new) == NULL)
+      snd_new_identifier = SOUNDS_SUBDIR;
+    else if (getTreeInfoFromIdentifier(artwork.snd_first, identifier_old) !=
+            getTreeInfoFromIdentifier(artwork.snd_first, identifier_new))
       snd_new_identifier = identifier_new;
-    if (getTreeInfoFromIdentifier(artwork.mus_first, identifier_new) !=
-       getTreeInfoFromIdentifier(artwork.mus_first, identifier_new))
+
+    if (getTreeInfoFromIdentifier(artwork.mus_first, identifier_new) == NULL)
+      mus_new_identifier = MUSIC_SUBDIR;
+    else if (getTreeInfoFromIdentifier(artwork.mus_first, identifier_new) !=
+            getTreeInfoFromIdentifier(artwork.mus_first, identifier_new))
       mus_new_identifier = identifier_new;
 
+#if 1
+    printf("::: 2: ['%s'] '%s', '%s'\n",
+          gfx_new_identifier, identifier_old, identifier_new);
+#endif
+
     leveldir_current_identifier = leveldir_current->identifier;
   }
 
@@ -3149,10 +3185,24 @@ void ReloadCustomArtwork()
   if (leveldir_current->music_set != NULL)
     mus_new_identifier = leveldir_current->music_set;
 
+#if 1
+  printf("CHECKING OLD/NEW GFX:\n  OLD: '%s'\n  NEW: '%s' ['%s', '%s']\n",
+        artwork.gfx_current_identifier, gfx_new_identifier,
+        artwork.gfx_current->identifier, leveldir_current->graphics_set);
+#endif
+
   if (strcmp(artwork.gfx_current_identifier, gfx_new_identifier) != 0 ||
       last_override_level_graphics != setup.override_level_graphics)
   {
 #if 0
+    artwork.gfx_current =
+      getTreeInfoFromIdentifier(artwork.gfx_first, gfx_new_identifier);
+#endif
+#if 1
+    artwork.gfx_current_identifier = gfx_new_identifier;
+#endif
+
+#if 1
     printf("RELOADING GRAPHICS '%s' -> '%s' ('%s')\n",
           artwork.gfx_current_identifier,
           artwork.gfx_current->identifier,
@@ -3167,10 +3217,22 @@ void ReloadCustomArtwork()
 
     FreeTileClipmasks();
     InitTileClipmasks();
+#if 0
+    artwork.gfx_current =
+      getTreeInfoFromIdentifier(artwork.gfx_first, gfx_new_identifier);
+#endif
+    printf("::: '%s', %lx\n", gfx_new_identifier, artwork.gfx_current);
 
+#if 0
     artwork.gfx_current_identifier = artwork.gfx_current->identifier;
+#endif
     last_override_level_graphics = setup.override_level_graphics;
 
+#if 0
+    printf("DONE RELOADING GFX: '%s' ['%s']\n",
+          artwork.gfx_current_identifier, artwork.gfx_current->identifier);
+#endif
+
     redraw_screen = TRUE;
   }
 
@@ -3190,6 +3252,8 @@ void ReloadCustomArtwork()
     InitReloadCustomSounds(snd_new_identifier);
     ReinitializeSounds();
 
+    artwork.snd_current =
+      getTreeInfoFromIdentifier(artwork.snd_first, setup.sounds_set);
     artwork.snd_current_identifier = artwork.snd_current->identifier;
     last_override_level_sounds = setup.override_level_sounds;
 
@@ -3205,6 +3269,8 @@ void ReloadCustomArtwork()
     InitReloadCustomMusic(mus_new_identifier);
     ReinitializeMusic();
 
+    artwork.mus_current =
+      getTreeInfoFromIdentifier(artwork.mus_first, setup.music_set);
     artwork.mus_current_identifier = artwork.mus_current->identifier;
     last_override_level_music = setup.override_level_music;
 
index 3ea7dc18e3f721eafea8e340016e768ca2a21dcc..95ef6eef6e9d97dcf3f724c45a1febc7af3d2022 100644 (file)
@@ -26,9 +26,9 @@
 /* functions from SGE library */
 inline void sge_Line(SDL_Surface *, Sint16, Sint16, Sint16, Sint16, Uint32);
 
-#ifdef PLATFORM_WIN32
+/* #ifdef PLATFORM_WIN32 */
 #define FULLSCREEN_BUG
-#endif
+/* #endif */
 
 /* stuff needed to work around SDL/Windows fullscreen drawing bug */
 static int fullscreen_width;
@@ -866,6 +866,14 @@ void sge_LineRGB(SDL_Surface *Surface, Sint16 x1, Sint16 y1, Sint16 x2,
 
 inline void SDLPutPixel(Bitmap *dst_bitmap, int x, int y, Pixel pixel)
 {
+#ifdef FULLSCREEN_BUG
+  if (dst_bitmap == backbuffer || dst_bitmap == window)
+  {
+    x += video_xoffset;
+    y += video_yoffset;
+  }
+#endif
+
   sge_PutPixel(dst_bitmap->surface, x, y, pixel);
 }
 
index 03df0b6c262bba19b4652746989764de2b4caab4..4f431f8a5f2c83d20b8c540f7320fc57c1e8c653 100644 (file)
 #define PROGRAM_VERSION_MAJOR  2
 #define PROGRAM_VERSION_MINOR  2
 #define PROGRAM_VERSION_PATCH  0
-#define PROGRAM_VERSION_RELEASE        7
-#define PROGRAM_VERSION_STRING "2.2.0rc7"
+#define PROGRAM_VERSION_RELEASE        8
+#define PROGRAM_VERSION_STRING "2.2.0rc8"
 
 #define PROGRAM_TITLE_STRING   "Rocks'n'Diamonds"
 #define PROGRAM_AUTHOR_STRING  "Holger Schemel"