#endif
#include "mikmod.h"
#include "audio.h"
+#include "cfgopt.h"
#ifdef _WIN32
#include <windows.h>
curmod = 0;
vol_master = vol_mus = vol_sfx = 255;
+ if(!opt.music) return 0;
+
#if defined(__linux__)
MikMod_RegisterDriver(&drv_alsa);
#elif defined(__FreeBSD__)
{
#ifdef _WIN32
HANDLE thr;
- if((thr = CreateThread(0, 0, update, 0, 0, 0))) {
+ if((thr = CreateThread(0, 0, upd_thread, 0, 0, 0))) {
CloseHandle(thr);
}
#else
void au_shutdown(void)
{
- curmod = 0;
- MikMod_Exit();
+ if(opt.music) {
+ curmod = 0;
+ MikMod_Exit();
+ }
}
struct au_module *au_load_module(const char *fname)
}
#ifdef _WIN32
-static DWORD WINAPI upd_thread(void *cls);
+static DWORD WINAPI upd_thread(void *cls)
#else
static void *update(void *cls)
#endif