rnd-20001205-3-src
authorHolger Schemel <info@artsoft.org>
Tue, 5 Dec 2000 00:42:08 +0000 (01:42 +0100)
committerHolger Schemel <info@artsoft.org>
Sat, 30 Aug 2014 08:35:31 +0000 (10:35 +0200)
29 files changed:
src/cartoons.c
src/cartoons.h
src/editor.c
src/editor.h
src/events.c
src/events.h
src/files.c
src/files.h
src/game.c
src/game.h
src/init.c
src/init.h
src/joystick.c
src/joystick.h
src/libgame/sdl.c
src/libgame/system.c
src/libgame/system.h
src/main.c
src/main.h
src/netserv.c
src/netserv.h
src/network.c
src/network.h
src/screens.c
src/screens.h
src/tape.c
src/tape.h
src/tools.c
src/tools.h

index 164fcf220c4d9048eed24609d8dc637fd01db9b5..2ede557a82c7fba4017843f3f6a5e78cde464994 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  cartoons.c                                              *
+* cartoons.c                                               *
 ***********************************************************/
 
 #include "cartoons.h"
index fdde0cbc86789a1070a3d1cd78ab78a113e75fd1..b93c21562323f45602c3c5e97fb59fcc760f765f 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  cartoons.h                                              *
+* cartoons.h                                               *
 ***********************************************************/
 
 #ifndef CARTOONS_H
index 6003fc91245c9eb892cddbf5bfc51894c39453a4..89e8d438d85b3e7947b1eb3930b46f7fc9865f50 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  editor.c                                                *
+* editor.c                                                 *
 ***********************************************************/
 
 #include <math.h>
index 5864d0d4b71d825c2b54a8405dc26fe97eb7c7f1..60bb32d710ec06cfcd1f97fdbd3b01b2d4e76b72 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  editor.h                                                *
+* editor.h                                                 *
 ***********************************************************/
 
 #ifndef EDITOR_H
index 604345d90f07054d1639ee0f285d45c1123547db..1e2ca16841661450886d719a2f701e0c8eea49be 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  events.c                                                *
+* events.c                                                 *
 ***********************************************************/
 
 #include "libgame/libgame.h"
index d08656090b58ab566fdff564c25af35ed8a0496d..b5e522812b2076a5426bc5f8510576682d831d3b 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  events.h                                                *
+* events.h                                                 *
 ***********************************************************/
 
 #ifndef EVENTS_H
index 2c0117ddb77d3a9792fe362c25ba8d62b58a102d..884571eb3b4915e770bd52cbba1152ec490976cd 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  files.h                                                 *
+* files.c                                                  *
 ***********************************************************/
 
 #include <ctype.h>
index 994a503e947bac57e586f8365214334eeb051942..a4aeda095067dfad13fe3b552de09c0c2acd5c02 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  files.h                                                 *
+* files.h                                                  *
 ***********************************************************/
 
 #ifndef FILES_H
index 6febbddb244a04f348922fc45f9a68e89af7ce67..ab7dbb5576784c19827a55245935f8097e0f98fa 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  game.c                                                  *
+* game.c                                                   *
 ***********************************************************/
 
 #include "libgame/libgame.h"
index 20b8e89af99bd53e7b7ce3072faf0ee0abce8b88..220bc1a76200c12817219a499ad846e3f6b59678 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  game.h                                                  *
+* game.h                                                   *
 ***********************************************************/
 
 #ifndef GAME_H
index ae65640f67f152bd51070ef2da3027a9a0a7c10b..3b6072741385769f6a1af70943a85d1e2f046a27 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  init.c                                                  *
+* init.c                                                   *
 ***********************************************************/
 
 #include <signal.h>
@@ -32,7 +32,6 @@ static void InitLevelInfo(void);
 static void InitNetworkServer(void);
 static void InitSound(void);
 static void InitSoundServer(void);
-static void InitDisplay(void);
 static void InitGfx(void);
 static void InitGfxBackground(void);
 static void InitGadgets(void);
@@ -40,20 +39,14 @@ static void InitElementProperties(void);
 
 void OpenAll(void)
 {
-#if !defined(PLATFORM_UNIX)
-  initErrorFile();
-#endif
-
   if (options.serveronly)
   {
 #if defined(PLATFORM_UNIX)
     NetworkServer(options.server_port, options.serveronly);
 #else
-    Error(ERR_WARN, "networking not supported in Windows version");
+    Error(ERR_WARN, "networking only supported in Unix version");
 #endif
-
-    /* never reached */
-    exit(0);
+    exit(0);   /* never reached */
   }
 
   InitProgramInfo(UNIX_USERDATA_DIRECTORY,
@@ -69,12 +62,12 @@ void OpenAll(void)
   InitJoysticks();
   InitRND(NEW_RANDOMIZE);
 
-  signal(SIGINT, CloseAllAndExit);
-  signal(SIGTERM, CloseAllAndExit);
-
-  InitDisplay();
   InitEventFilter(FilterMouseMotionEvents);
 
+  InitVideoDisplay();
+  InitVideoBuffer(&backbuffer, &window, WIN_XSIZE, WIN_YSIZE, DEFAULT_DEPTH,
+                 setup.fullscreen);
+
   InitGfx();
   InitElementProperties();     /* initializes IS_CHAR() for el2gfx() */
 
@@ -308,13 +301,6 @@ void InitJoysticks()
 #endif /* !TARGET_SDL */
 }
 
-void InitDisplay()
-{
-  InitVideoDisplay();
-  InitVideoBuffer(&backbuffer, &window, WIN_XSIZE, WIN_YSIZE, DEFAULT_DEPTH,
-                 setup.fullscreen);
-}
-
 void InitGfx()
 {
   int i;
@@ -447,51 +433,7 @@ void InitGfx()
 
   InitFontInfo(pix[PIX_BIGFONT], pix[PIX_MEDIUMFONT], pix[PIX_SMALLFONT]);
 
-  /* create additional image buffers for masking of graphics */
-
-#if defined(TARGET_SDL)
-
-#if 0
-  /* initialize surface array to 'NULL' */
-  for(i=0; i<NUM_TILES; i++)
-    tile_masked[i] = NULL;
-
-  /* create only those masked surfaces we really need */
-  for(i=0; tile_needs_clipping[i].start>=0; i++)
-  {
-    for(j=0; j<tile_needs_clipping[i].count; j++)
-    {
-      SDL_Surface *sdl_image_tmp;
-      int tile = tile_needs_clipping[i].start + j;
-      int graphic = tile;
-      int src_x, src_y;
-      int bitmap_nr;
-      Bitmap src_bitmap;
-
-      getGraphicSource(graphic, &bitmap_nr, &src_x, &src_y);
-      src_bitmap = pix[bitmap_nr];
-
-      /* create surface for masked tile graphic */
-      if ((sdl_image_tmp = SDL_CreateRGBSurface(SDL_SWSURFACE, TILEX, TILEY,
-                                               WIN_SDL_DEPTH, 0, 0, 0, 0))
-         == NULL)
-       Error(ERR_EXIT, "SDL_CreateRGBSurface() failed: %s", SDL_GetError());
-
-      /* create native transparent surface for current image */
-      SDL_SetColorKey(sdl_image_tmp, SDL_SRCCOLORKEY,
-                     SDL_MapRGB(sdl_image_tmp->format, 0x00, 0x00, 0x00));
-      if ((tile_masked[tile] = SDL_DisplayFormat(sdl_image_tmp)) == NULL)
-       Error(ERR_EXIT, "SDL_DisplayFormat() failed: %s", SDL_GetError());
-
-      SDL_FreeSurface(sdl_image_tmp);
-
-      BlitBitmap(src_bitmap, tile_masked[tile], src_x,src_y, TILEX,TILEY, 0,0);
-    }
-  }
-#endif
-
-#else /* !TARGET_SDL */
-
+#if defined(TARGET_X11)
   /* create graphic context structures needed for clipping */
   clip_gc_values.graphics_exposures = False;
   clip_gc_valuemask = GCGraphicsExposures;
@@ -543,8 +485,7 @@ void InitGfx()
                src_x, src_y, TILEX, TILEY, 0, 0);
     }
   }
-
-#endif /* !TARGET_SDL */
+#endif /* TARGET_X11 */
 }
 
 void InitGfxBackground()
@@ -1727,40 +1668,22 @@ void CloseAllAndExit(int exit_value)
 {
   int i;
 
-#if defined(TARGET_SDL)
   StopSounds();
   FreeSounds(NUM_SOUNDS);
-#else
+
+#if !defined(TARGET_SDL)
   if (audio.soundserver_pid)
-  {
-    StopSounds();
     kill(audio.soundserver_pid, SIGTERM);
-    FreeSounds(NUM_SOUNDS);
-  }
 #endif
 
   for(i=0; i<NUM_BITMAPS; i++)
     FreeBitmap(pix[i]);
 
-#if defined(TARGET_SDL)
   KeyboardAutoRepeatOn();
-#else
 
-#if 0
-  if (gc)
-    XFreeGC(display, gc);
-#endif
+  CloseVideoDisplay();
 
-  if (display)
-  {
-    KeyboardAutoRepeatOn();
-    XCloseDisplay(display);
-  }
-#endif
-
-#if !defined(PLATFORM_UNIX)
-  dumpErrorFile();
-#endif
+  ClosePlatformDependantStuff();
 
   exit(exit_value);
 }
index 714078361bade3108bf20941ea754f48e9f62986..e2bee8105953e59902d9f6369025055729e87777 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  init.h                                                  *
+* init.h                                                   *
 ***********************************************************/
 
 #ifndef INIT_H
index b21d682e3de4a33586984220baeac30e6a8e6499..9fb92d63d307ce0211ef99c6d349eecc08c3c1cf 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  joystick.c                                              *
+* joystick.c                                               *
 ***********************************************************/
 
 #if defined(PLATFORM_FREEBSD)
index 735f75c8f932683afbf3f28ff4c4de3a000d7591..ea74c8b451963a045b3eae92d95a320621c9d311 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  joystick.h                                              *
+* joystick.h                                               *
 ***********************************************************/
 
 #ifndef JOYSTICK_H
index c9de611ecc61779b5d8a35834040acd8001d6608..7c38aa940d26fa1c45f5fc9639a9ca1fd7b17306 100644 (file)
@@ -29,9 +29,6 @@ inline void SDLInitVideoDisplay(void)
 
   /* set default SDL depth */
   video.default_depth = SDL_GetVideoInfo()->vfmt->BitsPerPixel;
-
-  /* set exit function to automatically cleanup SDL stuff after exit() */
-  atexit(SDL_Quit);
 }
 
 inline void SDLInitVideoBuffer(DrawBuffer **backbuffer, DrawWindow **window,
index 7ee3e857872d332b18b2a5083c8d1028f11fdc99..07d4de7986f2d164aef559a12e4bda7c2893f68a 100644 (file)
@@ -12,6 +12,7 @@
 ***********************************************************/
 
 #include <string.h>
+#include <signal.h>
 
 #include "platform.h"
 
@@ -56,7 +57,7 @@ int           FrameCounter = 0;
 
 
 /* ========================================================================= */
-/* init functions                                                            */
+/* init/close functions                                                      */
 /* ========================================================================= */
 
 void InitCommandName(char *argv0)
@@ -68,6 +69,15 @@ void InitCommandName(char *argv0)
 void InitExitFunction(void (*exit_function)(int))
 {
   program.exit_function = exit_function;
+
+  /* set signal handlers to custom exit function */
+  signal(SIGINT, exit_function);
+  signal(SIGTERM, exit_function);
+
+#if defined(TARGET_SDL)
+  /* set exit function to automatically cleanup SDL stuff after exit() */
+  atexit(SDL_Quit);
+#endif
 }
 
 void InitPlatformDependantStuff(void)
@@ -75,6 +85,17 @@ void InitPlatformDependantStuff(void)
 #if defined(PLATFORM_MSDOS)
   _fmode = O_BINARY;
 #endif
+
+#if !defined(PLATFORM_UNIX)
+  initErrorFile();
+#endif
+}
+
+void ClosePlatformDependantStuff(void)
+{
+#if !defined(PLATFORM_UNIX)
+  dumpErrorFile();
+#endif
 }
 
 void InitProgramInfo(char *unix_userdata_directory, char *program_title,
@@ -159,6 +180,14 @@ inline void InitVideoDisplay(void)
 #endif
 }
 
+inline void CloseVideoDisplay(void)
+{
+#if defined(TARGET_X11)
+  if (display)
+    XCloseDisplay(display);
+#endif
+}
+
 inline void InitVideoBuffer(DrawBuffer **backbuffer, DrawWindow **window,
                            int width, int height, int depth,
                            boolean fullscreen)
@@ -452,7 +481,8 @@ inline void KeyboardAutoRepeatOn(void)
                      SDL_DEFAULT_REPEAT_INTERVAL / 2);
   SDL_EnableUNICODE(1);
 #else
-  XAutoRepeatOn(display);
+  if (display)
+    XAutoRepeatOn(display);
 #endif
 }
 
@@ -462,7 +492,8 @@ inline void KeyboardAutoRepeatOff(void)
   SDL_EnableKeyRepeat(0, SDL_DEFAULT_REPEAT_INTERVAL);
   SDL_EnableUNICODE(0);
 #else
-  XAutoRepeatOff(display);
+  if (display)
+    XAutoRepeatOff(display);
 #endif
 }
 
index e65cd99abb63de6177b7041add397f3964cefb63..3ff406f00037a1e953aaf43d9d0f3429c0f628d4 100644 (file)
@@ -255,6 +255,7 @@ extern int          FrameCounter;
 void InitCommandName(char *);
 void InitExitFunction(void (*exit_function)(int));
 void InitPlatformDependantStuff(void);
+void ClosePlatformDependantStuff(void);
 
 void InitProgramInfo(char *, char *, char *, char *, char *, char *, char *);
 
@@ -264,6 +265,7 @@ void InitGfxDoor2Info(int, int, int, int);
 void InitGfxScrollbufferInfo(int, int);
 
 inline void InitVideoDisplay(void);
+inline void CloseVideoDisplay(void);
 inline void InitVideoBuffer(DrawBuffer **,DrawWindow **, int,int,int, boolean);
 inline Bitmap *CreateBitmapStruct(void);
 inline Bitmap *CreateBitmap(int, int, int);
index a79aa4a6d62e554e1b1e93796c77cdfb002ce7d2..4d2ca8f0f9a6d1a42e716ab353ec81a516615fbc 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  main.c                                                  *
+* main.c                                                   *
 ***********************************************************/
 
 #include "libgame/libgame.h"
index 4313bf7eb8071ce773fc4db735ee17c17eebe935..e1539d281eef9c5348934be43d27900a332e5177 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  main.h                                                  *
+* main.h                                                   *
 ***********************************************************/
 
 #ifndef MAIN_H
 #include <unistd.h>
 #include <fcntl.h>
 
-#ifdef DEBUG
-#define DEBUG_TIMING   0
-#endif
-
 #include "libgame/libgame.h"
 
 #define WIN_XSIZE      672
 #define WIN_YSIZE      560
-#define WIN_SDL_DEPTH  16      /* !!! change this !!! */
 
 #if !defined(PLATFORM_MSDOS)
 #define WIN_XPOS       0
index 6a2479e53df35a2f638533ab85f57065701029bf..e6e9b10410dc1ee0f48e4aa2de53d1a3ce0c00c1 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  network.c                                               *
+* network.c                                                *
 ***********************************************************/
 
 #include "libgame/libgame.h"
index 5177fb4ab2aca8acb48d864c1d59767c97fad367..5c251c77227df5c0e665136e3038ca7d9bd8c83f 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  netserv.h                                               *
+* netserv.h                                                *
 ***********************************************************/
 
 #ifndef NETSERV_H
index 410695be366b1441a4899a1a573d58f7a444a309..822b7ee02bdf8f85e14942463ba8540ccb1e4200 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  network.c                                               *
+* network.c                                                *
 ***********************************************************/
 
 #include "libgame/libgame.h"
index 162f0f7df98d28e12fa1fd774dd61bbc44836a12..4a47091af39ffef2a13e46da0fe204681d512b9b 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  network.h                                               *
+* network.h                                                *
 ***********************************************************/
 
 #ifndef NETWORK_H
index 40bbdb4ccf3d003b94dffefcdbfb45346129eb04..91aa31b8d2cfad6e6683773c5cd4a3b5b43d6986 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  screens.c                                               *
+* screens.c                                                *
 ***********************************************************/
 
 #include "libgame/libgame.h"
index e5053667fc241e130538a8a8ad8fb2258f9bbf97..0cae1835db918ff6baf49573e14651cc204d4c4a 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  screens.h                                               *
+* screens.h                                                *
 ***********************************************************/
 
 #ifndef SCREENS_H
index f3509cec0110f4208454cbf5d9afb4e30d21231e..05d5956cb117dcf5a25061652a424587f1c6f05c 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  tape.c                                                  *
+* tape.c                                                   *
 ***********************************************************/
 
 #include "libgame/libgame.h"
index 1727ecf50faa4e6c46e1418bcebc5c4408ef3e48..b41d9f3cd951d79ba1fe059224b3e1bc3f56f1e8 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  tape.c                                                  *
+* tape.h                                                   *
 ***********************************************************/
 
 #ifndef TAPE_H
index 0effe46b497cc626bebd5ed35c2bc8aae48a32e8..3bd370dcfd4c0993863f6b2f4b58093ea31d90ef 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  tools.c                                                 *
+* tools.c                                                  *
 ***********************************************************/
 
 #include <stdarg.h>
index 63ae5c593425e5c677878d53065c133dc48d0464..5501d705f84a2b83626f92968a8682c68b7daa7c 100644 (file)
@@ -1,14 +1,14 @@
 /***********************************************************
-*  Rocks'n'Diamonds -- McDuffin Strikes Back!              *
+* Rocks'n'Diamonds -- McDuffin Strikes Back!               *
 *----------------------------------------------------------*
-*  (c) 1995-98 Artsoft Entertainment                       *
-*              Holger Schemel                              *
-*              Oststrasse 11a                              *
-*              33604 Bielefeld                             *
-*              phone: ++49 +521 290471                     *
-*              email: aeglos@valinor.owl.de                *
+* (c) 1995-2000 Artsoft Entertainment                      *
+*               Holger Schemel                             *
+*               Detmolder Strasse 189                      *
+*               33604 Bielefeld                            *
+*               Germany                                    *
+*               e-mail: info@artsoft.org                   *
 *----------------------------------------------------------*
-*  tools.h                                                 *
+* tools.h                                                  *
 ***********************************************************/
 
 #ifndef TOOLS_H