===================== S_BeginRegistration ===================== */
| 916 | ===================== |
| 917 | */ |
| 918 | void S_BeginRegistration( void ) |
| 919 | { |
| 920 | s_soundMuted = qfalse; // we can play again |
| 921 | |
| 922 | #ifdef USE_OPENAL |
| 923 | // Find name of level so we can load in the appropriate EAL file |
| 924 | if (s_UseOpenAL) |
| 925 | { |
| 926 | const char *mapname = Cvar_VariableString( "mapname" ); |
| 927 | EALFileInit(mapname); |
| 928 | // clear carry crap from previous map |
| 929 | for (int i = 0; i < EAX_MAX_FXSLOTS; i++) |
| 930 | { |
| 931 | s_FXSlotInfo[i].lEnvID = -1; |
| 932 | } |
| 933 | } |
| 934 | #endif |
| 935 | |
| 936 | if (s_numSfx == 0) { |
| 937 | SND_setup(); |
| 938 | |
| 939 | s_numSfx = 0; |
| 940 | memset( s_knownSfx, 0, sizeof( s_knownSfx ) ); |
| 941 | memset(sfxHash, 0, sizeof(sfx_t *)*LOOP_HASH); |
| 942 | |
| 943 | #ifdef _DEBUG |
| 944 | sfx_t *sfx = S_FindName( "***DEFAULT***" ); |
| 945 | S_DefaultSound( sfx ); |
| 946 | #else |
| 947 | S_RegisterSound("sound/null.wav"); |
| 948 | #endif |
| 949 | } |
| 950 | } |
| 951 | |
| 952 | #ifdef USE_OPENAL |
| 953 | static void EALFileInit(const char *level) |
no test coverage detected