[Fix] Fixed linked list for sound, was hanging the entire thing..
This commit is contained in:
parent
b26a1ca968
commit
74719f2cbd
@ -74,7 +74,7 @@ void input_setDefault(void) {
|
||||
input_setKeybind("target_hostile", KEYBIND_KEYBOARD, SDLK_r, KMOD_NONE, 0);
|
||||
/* Combat. */
|
||||
input_setKeybind("primary", KEYBIND_KEYBOARD, SDLK_SPACE, KMOD_NONE, 0);
|
||||
input_setKeybind("face", KEYBIND_KEYBOARD, SDLK_f, KMOD_NONE, 0);
|
||||
input_setKeybind("face", KEYBIND_KEYBOARD, SDLK_1, KMOD_NONE, 0);
|
||||
input_setKeybind("board", KEYBIND_KEYBOARD, SDLK_b, KMOD_NONE, 0);
|
||||
/* Escorts. */
|
||||
input_setKeybind("e_attack", KEYBIND_KEYBOARD, SDLK_f, KMOD_NONE, 0);
|
||||
|
@ -502,7 +502,6 @@ static Mix_Chunk* sound_load(char* filename) {
|
||||
|
||||
/* Get the file data buffer from the packfile. */
|
||||
wavdata = pack_readfile(DATA, filename, &size);
|
||||
|
||||
rw = SDL_RWFromMem(wavdata, size);
|
||||
|
||||
/* Bind to OpenAL buffer. */
|
||||
@ -676,9 +675,11 @@ static int voice_add(alVoice* v) {
|
||||
tv = v->prev;
|
||||
tv->next = v->next;
|
||||
if(tv->next != NULL)
|
||||
voice_pool->prev = NULL;
|
||||
tv->next->prev = tv;
|
||||
} else { /* Set pool to be the next. */
|
||||
voice_pool = v->next;
|
||||
if(voice_pool != NULL)
|
||||
voice_pool->prev = NULL;
|
||||
}
|
||||
|
||||
/* Insert to the front of active voices. */
|
||||
|
Loading…
Reference in New Issue
Block a user