Permalink
Browse files

Remove more audio code.

git-svn-id: svn+ssh://jay/var/svn/wolf/trunk@126 32837ae5-38f0-4cfd-8401-3ff76d8497c4
  • Loading branch information...
1 parent ed548fc commit 256877a9cf056cd1dcf99e6b1494f9b9495c330d paul committed Aug 19, 2007
Showing with 27 additions and 1 deletion.
  1. +1 −1 Makefile
  2. +6 −0 sd_comm.h
  3. +10 −0 wl_agent.c
  4. +6 −0 wl_main.c
  5. +4 −0 wl_play.c
View
@@ -33,7 +33,7 @@ EOBJS = $(OBJS) $(ROBJS) vi_bare.o arm_support.o
LDLIBS =
# no sound
-OBJS += sd_null.o
+#OBJS += sd_null.o
# sound using OSS
#OBJS += sd_oss.o fmopl.o
#CFLAGS += -D_REENTRANT
View
@@ -1,6 +1,7 @@
#ifndef __SD_COMM_H__
#define __SD_COMM_H__
+#ifdef ENABLE_AUDIO
typedef enum {
sdm_Off,
sdm_PC,sdm_AdLib
@@ -40,5 +41,10 @@ void UpdateSoundLoc(fixed x, fixed y, myint angle);
extern myint DigiMap[];
void InitDigiMap();
+#else
+#define SD_WaitSoundDone() do {} while(0)
+#define SD_PlaySound(n) do {} while (0)
+#define PlaySoundLocGlobal(s, id, gx, gy)
+#endif
#endif
View
@@ -225,6 +225,7 @@ void DrawFace()
}
+#ifndef EMBEDDED
/*
===============
=
@@ -253,6 +254,7 @@ void UpdateFace()
DrawFace();
}
}
+#endif
/*
@@ -664,8 +666,10 @@ void GetBonus (statobj_t *check)
SD_PlaySound (GETGATLINGSND);
GiveWeapon (wp_chaingun);
+#ifndef EMBEDDED
StatusDrawPic (17,4,GOTGATLINGPIC);
facecount = 0;
+#endif
gotgatgun = 1;
break;
@@ -807,8 +811,10 @@ void ClipMove(objtype *ob, long xmove, long ymove)
return; // walk through walls
#endif
+#ifdef ENABLE_AUDIO
if (!SD_SoundPlaying())
SD_PlaySound (HITWALLSND);
+#endif
ob->x = basex+xmove;
ob->y = basey;
@@ -1223,7 +1229,9 @@ void T_Attack(objtype *ob)
{
const struct atkinf *cur;
+#ifndef EMBEDDED
UpdateFace();
+#endif
if (gamestate.victoryflag) // watching the BJ actor
{
@@ -1323,7 +1331,9 @@ void T_Player(objtype *ob)
return;
}
+#ifndef EMBEDDED
UpdateFace();
+#endif
CheckWeaponChange();
if (buttonstate[bt_use])
View
@@ -253,9 +253,11 @@ static void SetDefaults()
mouseadjustment = 5;
+#ifdef ENABLE_AUDIO
SD_SetMusicMode(smm_AdLib);
SD_SetSoundMode(sdm_AdLib);
SD_SetDigiDevice(sds_SoundBlaster);
+#endif
}
myint ReadConfig()
@@ -1125,7 +1127,9 @@ void DoJukebox()
void ShutdownId()
{
US_Shutdown();
+#ifndef ENABLE_AUDIO
SD_Shutdown();
+#endif
IN_Shutdown();
VW_Shutdown();
CA_Shutdown();
@@ -1182,7 +1186,9 @@ void InitGame()
CA_Startup();
VW_Startup();
IN_Startup();
+#ifdef ENABLE_AUDIO
SD_Startup();
+#endif
US_Startup();
//
View
@@ -1255,7 +1255,9 @@ void PlayLoop()
frameon = 0;
anglefrac = 0;
+#ifndef EMBEDDED
facecount = 0;
+#endif
funnyticount = 0;
memset (buttonstate,0,sizeof(buttonstate));
@@ -1306,7 +1308,9 @@ void PlayLoop()
gamestate.TimeCount += tics;
+#ifdef ENABE_AUDIO
UpdateSoundLoc(player->x, player->y, player->angle);
+#endif
if (screenfaded)
VW_FadeIn();

0 comments on commit 256877a

Please sign in to comment.