Right. I have the old version working fine. I got rid of all the annoying messages when using NEW_SOUND. Here is a diff - I just used cvs diff, if I need to use other parameters (-u ?) let me know. If somebody could re-try without NEW_SOUND then we need to check in the changes since the client is kind of broken currently!
I did reproduce the error when ou turn off sound&music and then turn one back on. I don't get any lag but the game jsut hangs on exit. I've not fixed this yet - I'll look but it seems more urgent to fix the version that is being used!
Diff follows...
Index: asc.c
===================================================================
RCS file: /cvsroot/elc/elc/asc.c,v
retrieving revision 1.58
diff -r1.58 asc.c
505c505
< LOG_ERROR("Unable to find property %s in node %s\n", prop, node->name);
---
> if(log)LOG_ERROR("Unable to find property %s in node %s\n", prop, node->name);
509c509
< char *get_string_property (xmlNode *node, const char *prop) {
---
> char *get_string_property (xmlNode *node, const char *prop, int log) {
518,519c518,519
< LOG_ERROR("Unable to find property %s in node %s\n", prop, node->name);
< return;
---
> if(log)LOG_ERROR("Unable to find property %s in node %s\n", prop, node->name);
> return NULL;
Index: asc.h
===================================================================
RCS file: /cvsroot/elc/elc/asc.h,v
retrieving revision 1.34
diff -r1.34 asc.h
253c253
< char *get_string_property (xmlNode *node, const char *prop);
---
> char *get_string_property (xmlNode *node, const char *prop, int log);
Index: actor_scripts.c
===================================================================
RCS file: /cvsroot/elc/elc/actor_scripts.c,v
retrieving revision 1.137
diff -r1.137 actor_scripts.c
1402c1402
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1412c1412
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1422c1422
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1432c1432
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1658c1658
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1668c1668
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1678c1678
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1688c1688
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1698c1698
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1708c1708
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1718c1718
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1728c1728
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1738c1738
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1748c1748
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1758c1758
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1768c1768
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1778c1778
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1788c1788
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1798c1798
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1808c1808
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1818c1818
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1828c1828
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1838c1838
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1848c1848
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1858c1858
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1868c1868
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1878c1878
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
1888c1888
< , get_string_property(item,"sound")
---
> , get_string_property(item,"sound",0)
2106c2106
< strcpy(name,get_string_property(cfg, "type"));
---
> strcpy(name,get_string_property(cfg, "type",1));
2121c2121
< strcpy(name,get_string_property(cfg, "type"));
---
> strcpy(name,get_string_property(cfg, "type",1));
2129c2129
< strcpy(act->actor_name, get_string_property(cfg, "type"));
---
> strcpy(act->actor_name, get_string_property(cfg, "type",1));
Index: sound.c
===================================================================
RCS file: /cvsroot/elc/elc/sound.c,v
retrieving revision 1.83
diff -r1.83 sound.c
14,15c14,15
< #define LOCK_SOUND_LIST()// SDL_LockMutex(sound_list_mutex)
< #define UNLOCK_SOUND_LIST()// SDL_UnlockMutex(sound_list_mutex);
---
> #define LOCK_SOUND_LIST() SDL_LockMutex(sound_list_mutex)
> #define UNLOCK_SOUND_LIST() SDL_UnlockMutex(sound_list_mutex);
148a149
> LOCK_SOUND_LIST();
160c161,162
<
---
>
> UNLOCK_SOUND_LIST();
182a185
> LOCK_SOUND_LIST();
183a187
> UNLOCK_SOUND_LIST();
374c378
<
---
> LOCK_SOUND_LIST();
388a393
> UNLOCK_SOUND_LIST();
401a407
> UNLOCK_SOUND_LIST();
413a420
> UNLOCK_SOUND_LIST();
422a430
> UNLOCK_SOUND_LIST();
517a526
> UNLOCK_SOUND_LIST();
528a538,539
> {
> UNLOCK_SOUND_LIST();
529a541
> }
534a547,548
> {
> UNLOCK_SOUND_LIST();
535a550
> }
730a746
> LOCK_SOUND_LIST();
743a760
> UNLOCK_SOUND_LIST();
1282,1290c1299,1302
< void toggle_music(int * var){
< if(!have_music && *var){
< #ifdef NEW_SOUND
< init_sound(SOUND_CONFIG_PATH);
< #else
< init_sound();
< #endif //NEW_SOUND
< }
< if(music_on){
---
> void toggle_music(int * var)
> {
> *var=!*var;
> if(!music_on)
1292c1304
< } else {
---
> else
1294,1295d1305
< }
< *var=!*var;
1309d1318
< music_on=0;
1567c1576
< if(!inited){
---
> if(!inited)
1576c1585,1586
< if(music_thread != NULL){
---
> if(music_thread != NULL)
> {
1580c1590,1591
< while(queued-- > 0){
---
> while(queued-- > 0)
> {
1612,1613c1623,1626
< for(i=0;i<MAX_BUFFERS;i++) {
< if(alIsBuffer(sound_buffer)) {
---
> for(i=0;i<MAX_BUFFERS;i++)
> {
> if(alIsBuffer(sound_buffer))
> {
1619a1633
> {
1631c1645,1646
< if(context != NULL) {
---
> if(context != NULL)
> {
2136a2152
> LOCK_SOUND_LIST();
2151a2168
> UNLOCK_SOUND_LIST();