X-Git-Url: https://git.jsancho.org/?a=blobdiff_plain;f=Source%2FGameInitDispose.cpp;h=28b0f69a74965837408a226bfc8096ca4bbfb36b;hb=7a0b90b30144f63105f6efd8f0d969862934b046;hp=a2f93b98502158c19c4f536631f8192c48d22f9e;hpb=03e3d05a91e2a3aea407387d9531177b2ca31813;p=lugaru.git diff --git a/Source/GameInitDispose.cpp b/Source/GameInitDispose.cpp index a2f93b9..28b0f69 100644 --- a/Source/GameInitDispose.cpp +++ b/Source/GameInitDispose.cpp @@ -34,7 +34,6 @@ extern float gravity; extern Light light; extern Skeleton testskeleton; extern int numsounds; -extern int channels[100]; extern Terrain terrain; //extern Sprites sprites; extern int kTextureSize; @@ -97,9 +96,6 @@ extern float accountcampaigntime[10]; extern int accountcampaignchoicesmade[10]; extern int accountcampaignchoices[10][5000]; -extern "C" void PlaySoundEx(int channel, OPENAL_SAMPLE *sptr, OPENAL_DSPUNIT *dsp, signed char startpaused); -extern "C" void PlayStreamEx(int chan, OPENAL_STREAM *sptr, OPENAL_DSPUNIT *dsp, signed char startpaused); - void LOG(const std::string &fmt, ...) { // !!! FIXME: write me. @@ -831,8 +827,6 @@ void Game::InitGame() //terraindetail=2; } - memset(channels, 0xff, sizeof(channels)); - LOG("Initializing sound system..."); int output = -1; @@ -873,11 +867,8 @@ void Game::InitGame() OPENAL_SetSFXMasterVolume((int)(volume*255)); loadAllSounds(); - if(musictoggle){ - PlayStreamEx(stream_music3, samp[stream_music3], 0, true); - OPENAL_SetPaused(channels[stream_music3], false); - OPENAL_SetVolume(channels[stream_music3], 256); - } + if(musictoggle) + emit_stream_np(stream_music3); LoadTexture(":Data:Textures:Cursor.png",&cursortexture,0,1); @@ -926,11 +917,6 @@ void Game::LoadStuff() visibleloading=1; - /*musicvolume[3]=512; - PlaySoundEx( music4, samp[music4], NULL, true); - OPENAL_SetPaused(channels[music4], false); - OPENAL_SetVolume(channels[music4], 512); - */ loadtime=0; stillloading=1;