projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
rnd-19981217-3
[rocksndiamonds.git]
/
src
/
init.c
diff --git
a/src/init.c
b/src/init.c
index 321875dc2aba3f1a5b042f160a56aee319b2fddf..f2e48bf0b82f5a66d5e173892df1067721b8ddb7 100644
(file)
--- a/
src/init.c
+++ b/
src/init.c
@@
-17,6
+17,7
@@
#include "misc.h"
#include "sound.h"
#include "screens.h"
#include "misc.h"
#include "sound.h"
#include "screens.h"
+#include "editor.h"
#include "tools.h"
#include "files.h"
#include "joystick.h"
#include "tools.h"
#include "files.h"
#include "joystick.h"
@@
-66,6
+67,7
@@
void OpenAll(int argc, char *argv[])
InitSoundServer();
InitJoysticks();
InitRND(NEW_RANDOMIZE);
InitSoundServer();
InitJoysticks();
InitRND(NEW_RANDOMIZE);
+ InitLevelEditorGadgets();
signal(SIGINT, CloseAllAndExit);
signal(SIGTERM, CloseAllAndExit);
signal(SIGINT, CloseAllAndExit);
signal(SIGTERM, CloseAllAndExit);
@@
-172,8
+174,9
@@
void InitSound()
for(i=0; i<NUM_SOUNDS; i++)
{
#ifdef MSDOS
for(i=0; i<NUM_SOUNDS; i++)
{
#ifdef MSDOS
-
sprintf(sound_name[i], "%d", i+
1);
+
sprintf(sound_name[i], "%d", i +
1);
#endif
#endif
+
Sound[i].name = sound_name[i];
if (!LoadSound(&Sound[i]))
{
Sound[i].name = sound_name[i];
if (!LoadSound(&Sound[i]))
{
@@
-188,10
+191,7
@@
void InitSoundServer()
if (sound_status == SOUND_OFF)
return;
if (sound_status == SOUND_OFF)
return;
-#ifdef MSDOS
- SoundServer();
- return;
-#endif
+#ifndef MSDOS
if (pipe(sound_pipe)<0)
{
if (pipe(sound_pipe)<0)
{
@@
-216,6
+216,12
@@
void InitSoundServer()
}
else /* we are parent */
close(sound_pipe[0]); /* no reading from pipe needed */
}
else /* we are parent */
close(sound_pipe[0]); /* no reading from pipe needed */
+
+#else /* MSDOS */
+
+ SoundServer();
+
+#endif /* MSDOS */
}
void InitJoysticks()
}
void InitJoysticks()