/***********************************************************
* Rocks'n'Diamonds -- McDuffin Strikes Back! *
*----------------------------------------------------------*
-* (c) 1995-2000 Artsoft Entertainment *
+* (c) 1995-2001 Artsoft Entertainment *
* Holger Schemel *
* Detmolder Strasse 189 *
* 33604 Bielefeld *
* init.c *
***********************************************************/
-#include <signal.h>
-
#include "libgame/libgame.h"
#include "init.h"
static void InitLevelInfo(void);
static void InitNetworkServer(void);
static void InitSound(void);
-static void InitSoundServer(void);
static void InitGfx(void);
static void InitGfxBackground(void);
static void InitGadgets(void);
InitCounter();
InitSound();
- InitSoundServer();
InitJoysticks();
InitRND(NEW_RANDOMIZE);
}
num_bg_loops = LoadMusic();
-}
-
-void InitSoundServer()
-{
- if (!audio.sound_available)
- return;
-
-#if !defined(TARGET_SDL)
-#if defined(PLATFORM_UNIX)
-
- if (pipe(audio.soundserver_pipe) < 0)
- {
- Error(ERR_WARN, "cannot create pipe - no sounds");
- audio.sound_available = FALSE;
- return;
- }
-
- if ((audio.soundserver_pid = fork()) < 0)
- {
- Error(ERR_WARN, "cannot create sound server process - no sounds");
- audio.sound_available = FALSE;
- return;
- }
- if (audio.soundserver_pid == 0) /* we are child */
- {
- SoundServer();
-
- /* never reached */
- exit(0);
- }
- else /* we are parent */
- close(audio.soundserver_pipe[0]); /* no reading from pipe needed */
-
-#else /* !PLATFORM_UNIX */
-
- SoundServer();
-
-#endif /* !PLATFORM_UNIX */
-#endif /* !TARGET_SDL */
+ StartSoundserver();
}
void InitJoysticks()
src_x, src_y, TILEX, TILEY, 0, 0);
}
}
-#endif /* TARGET_X11_ANTIVE */
+#endif /* TARGET_X11_NATIVE */
#endif /* TARGET_X11 */
}
EL_AMOEBE_BD,
EL_MORAST_VOLL,
EL_MORAST_LEER,
+ EL_QUICKSAND_FILLING,
+ EL_QUICKSAND_EMPTYING,
EL_MAGIC_WALL_OFF,
EL_MAGIC_WALL_EMPTY,
EL_MAGIC_WALL_FULL,
EL_EDELSTEIN_GELB,
EL_EDELSTEIN_ROT,
EL_EDELSTEIN_LILA,
- EL_DIAMANT,
- EL_SP_INFOTRON
+ EL_DIAMANT
};
static int ep_gem_num = sizeof(ep_gem)/sizeof(int);
StopSounds();
FreeSounds(NUM_SOUNDS);
-
-#if !defined(TARGET_SDL)
- if (audio.soundserver_pid)
- kill(audio.soundserver_pid, SIGTERM);
-#endif
+ CloseAudio();
for(i=0; i<NUM_BITMAPS; i++)
FreeBitmap(pix[i]);
-
- KeyboardAutoRepeatOn();
-
CloseVideoDisplay();
ClosePlatformDependantStuff();