ago Report post Posted April 4, 2008 No this is not a bug. This is because you're compiling with the skybox and because I've changed the way the near and far clip plane work. Put a value of 1.0 for near plane and 100.0 for far plane and it should be ok. Ok, that fixes the strange drawing I've seen after your SKY_FPV change Share this post Link to post Share on other sites
Roja Report post Posted April 4, 2008 Well this is somewhat of a CVS error I guess..not sure where else to post it. When you compile with DEBUG on and you close the client, it doesn't fully close. The window dissapears as if it closes, but the client is still running. So I have to press ctrl+alt+del and end the process that way. It really sucks if you forget to do this and run another client cause your computer slows down to below a snails pace So it would be helpful if fixed, but obviously it's not that important..just figured I'd post if someone can/wants to fix it. Share this post Link to post Share on other sites
Vegar Report post Posted April 4, 2008 (edited) When you compile with DEBUG on and you close the client, it doesn't fully close. The window dissapears as if it closes, but the client is still running. So I have to press ctrl+alt+del and end the process that way. It really sucks if you forget to do this and run another client cause your computer slows down to below a snails pace So it would be helpful if fixed, but obviously it's not that important..just figured I'd post if someone can/wants to fix it. I'm not able to reproduce this. Do you only have DEBUG enabled? no other debug options? How do you close the client? I tried with both ctrl+q and clicking the X in the top right corner. Edited April 4, 2008 by Vegar Share this post Link to post Share on other sites
Roja Report post Posted April 4, 2008 Aside from teh default options, I have debug and the sky enabled. I disabled debug and had the sky enabled and this did not happen, so it seems like it's because of debug. I closed the client by clicking the x in the corner and also using alt+x. ctrl+q doesn't do anything for me. Oh and obviously i'm using winXP Share this post Link to post Share on other sites
Vegar Report post Posted April 4, 2008 (edited) I'm still not able to reproduce it, even with sky enabled. Someone with windows have to look into it. Edited April 4, 2008 by Vegar Share this post Link to post Share on other sites
Alberich Report post Posted April 8, 2008 in my dev-c++ development environment I get these warnings: 351 C:\Dev-Cpp\elc\eye_candy\effect_targetmagic.cpp [Warning] passing `coord_t' for converting 1 of `int abs(int)' 457 C:\Dev-Cpp\elc\eye_candy\effect_targetmagic.cpp [Warning] passing `coord_t' for converting 1 of `int abs(int)' 469 C:\Dev-Cpp\elc\eye_candy\effect_targetmagic.cpp [Warning] passing `coord_t' for converting 1 of `int abs(int)' 534 C:\Dev-Cpp\elc\eye_candy\effect_targetmagic.cpp [Warning] passing `coord_t' for converting 1 of `int abs(int)' 546 C:\Dev-Cpp\elc\eye_candy\effect_targetmagic.cpp [Warning] passing `coord_t' for converting 1 of `int abs(int)' 614 C:\Dev-Cpp\elc\eye_candy\effect_glow.cpp [Warning] passing `coord_t' for converting 1 of `int abs(int)' 629 C:\Dev-Cpp\elc\eye_candy\effect_glow.cpp [Warning] passing `coord_t' for converting 1 of `int abs(int)' 644 C:\Dev-Cpp\elc\eye_candy\effect_glow.cpp [Warning] passing `coord_t' for converting 1 of `int abs(int)' 659 C:\Dev-Cpp\elc\eye_candy\effect_glow.cpp [Warning] passing `coord_t' for converting 1 of `int abs(int)' using fabs( ) instead of abs( ) fixed it, but I'm not sure if this function exists on every platform. Share this post Link to post Share on other sites
rauch Report post Posted May 13, 2008 (edited) an crash occurs on every magic level up (reproducable), when running in debugger, I can see the level up effect start, then it crashes. backtrace: Program received signal SIGSEGV, Segmentation fault. 0x000000000057026d in ec::MathCache::powf_0_1_rough_close (this=0x9ffe80, base=nan(0x400000), power=0.100000001) at eye_candy/math_cache.cpp:2178 2178 return (powf_map[index1][index2] * (1.0 - percent2)) + (powf_map[index1][index2 + 1] * percent2); Current language: auto; currently c++ (gdb) bt full #0 0x000000000057026d in ec::MathCache::powf_0_1_rough_close (this=0x9ffe80, base=nan(0x400000), power=0.100000001) at eye_candy/math_cache.cpp:2178 index1 = -2147483648 percent2 = 0.600000024 index2 = 28 #1 0x00000000005547ac in ec::Particle::flare (this=0x2aaab107a110) at eye_candy/eye_candy.cpp:837 offset = -24252 exp_base = nan(0x400000) exp = 0 flare_val = 0 __PRETTY_FUNCTION__ = "virtual coord_t ec::Particle::flare() const" #2 0x000000000055494e in ec::Particle::draw (this=0x2aaab107a110, usec=14299) at eye_candy/eye_candy.cpp:716 tempsize = -nan(0x400000) #3 0x00000000005debc7 in ec::GlowParticle::draw (this=0x2aaab107a110, usec=14299) at eye_candy/effect_glow.cpp:786 No locals. #4 0x000000000055317c in ec::EyeCandy::draw (this=0x9ff720) at eye_candy/eye_candy.cpp:1645 p = (class ec::Particle *) 0x2aaab107a110 iter2 = {_M_node = 0x2aaab107a1d0} e = (class ec::Effect *) 0x2aaab108c1c0 iter = {_M_current = 0x182ee3d0} #5 0x000000000053ce00 in ec_draw () at eye_candy_wrapper.cpp:525 cluster = 55 #6 0x000000000046af91 in display_game_handler (win=0x1779af0) at gamewin.c:1230 str = "XX�i�\177\000\000`X�i�\177\000\000\230��\027\000\000\000\000PX�i�\177\000\000pX�i\\\000\000\000���@t+\000\000�X�i�\177\000\000\000\000\000\000\000\000\000\000�Z�i�\177", '\0' <repeats 18 times>, "\016\002\000At+\000\000\000@\000@\000\000\000\000u\231F\000\000\000\000\000�Z�i�\177\000\000\000\000\000\000\000\000\000\000�\002\000\000/\002\000\000\000@\000@\000\000\000\000�X�i\000\000\000\000�\232w\001\000\000\000\000\000@\000@\000\000\000\000���=\000\000\000\000���>" i = 1 any_reflection = 0 mouse_rate = 5 main_count = 6992 times_FPS_below_3 = 0 fps = {92, 93, 93, 92, 92} shadows_were_disabled = 0 ---Type <return> to continue, or q <return> to quit--- eye_candy_was_disabled = 0 #7 0x0000000000459e0e in draw_window (win=0x1779af0) at elwindows.c:1193 ret_val = 0 W = (widget_list *) 0x0 #8 0x000000000045a698 in display_window (win_id=1) at elwindows.c:1364 No locals. #9 0x0000000000456dd5 in display_windows (level=1) at elwindows.c:76 id = -2 next_id = -9999 i = 1 #10 0x000000000044d898 in draw_scene () at draw_scene.c:144 No locals. #11 0x0000000000494050 in start_rendering () at main.c:191 event = {type = 24 '\030', active = {type = 24 '\030', gain = 36 '$', state = 0 '\0'}, key = {type = 24 '\030', which = 36 '$', state = 0 '\0', keysym = {scancode = 1 '\001', sym = 1090528510, mod = 11124, unicode = 52294}}, motion = {type = 24 '\030', which = 36 '$', state = 0 '\0', x = 1, y = 0, xrel = 9470, yrel = 16640}, button = {type = 24 '\030', which = 36 '$', button = 0 '\0', state = 65 'A', x = 1, y = 0}, jaxis = {type = 24 '\030', which = 36 '$', axis = 0 '\0', value = 1}, jball = {type = 24 '\030', which = 36 '$', ball = 0 '\0', xrel = 1, yrel = 0}, jhat = { type = 24 '\030', which = 36 '$', hat = 0 '\0', value = 65 'A'}, jbutton = {type = 24 '\030', which = 36 '$', button = 0 '\0', state = 65 'A'}, resize = {type = 24 '\030', w = 1, h = 1090528510}, expose = {type = 24 '\030'}, quit = {type = 24 '\030'}, user = {type = 24 '\030', code = 1, data1 = 0x2b74410024fe, data2 = 0x4829cc46}, syswm = {type = 24 '\030', msg = 0x2b74410024fe}} network_thread = (SDL_Thread *) 0x2ab0f40 message_queue = (queue_t *) 0x2a98420 done = 0 network_thread_data = {0x2a98420, 0x9f9250} last_frame_and_command_update = 90022 #12 0x0000000000494472 in main (argc=1, argv=0x7fff69d05ae8) at main.c:324 No locals. Edit: In Request from Florian new traceback with -DDEBUG_NANS ERROR: Invalid particle 0x2aaab01f54a0: pos=<nan, nan, nan>; velocity=<nan, nan, nan>; effect=0x2aaab01c13b0 Program received signal SIGSEGV, Segmentation fault. 0x0000000000577541 in ec::MathCache::powf_0_1_rough_close (this=0xa09060, base=nan(0x400000), power=0.100000001) at eye_candy/math_cache.cpp:2178 2178 return (powf_map[index1][index2] * (1.0 - percent2)) + (powf_map[index1][index2 + 1] * percent2); Current language: auto; currently c++ (gdb) bt full #0 0x0000000000577541 in ec::MathCache::powf_0_1_rough_close (this=0xa09060, base=nan(0x400000), power=0.100000001) at eye_candy/math_cache.cpp:2178 index1 = -2147483648 percent2 = 0.600000024 index2 = 28 #1 0x000000000055cb8d in ec::Particle::flare (this=0x2aaab01f54a0) at eye_candy/eye_candy.cpp:837 offset = 21716 exp_base = nan(0x400000) exp = 0.653237939 flare_val = -nan(0x400000) __PRETTY_FUNCTION__ = "virtual coord_t ec::Particle::flare() const" #2 0x000000000055b926 in ec::Particle::draw (this=0x2aaab01f54a0, usec=19897) at eye_candy/eye_candy.cpp:716 tempsize = -nan(0x400000) #3 0x00000000005e5e9b in ec::GlowParticle::draw (this=0x2aaab01f54a0, usec=19897) at eye_candy/effect_glow.cpp:786 No locals. #4 0x000000000055a2b0 in ec::EyeCandy::draw (this=0xa08900) at eye_candy/eye_candy.cpp:1645 p = (class ec::Particle *) 0x2aaab01f54a0 iter2 = {_M_node = 0x2aaab01f5560} e = (class ec::Effect *) 0x2aaab01c13b0 iter = {_M_current = 0x2aaab0172518} #5 0x0000000000543f34 in ec_draw () at eye_candy_wrapper.cpp:525 cluster = 1 #6 0x0000000000472089 in display_game_handler (win=0x1782af0) at gamewin.c:1230 str = "���\210�\177\000\000���\210�\177\000\000�:�\030\000\000\000\000���\210�\177\000\000���\210\214\000\000\000���\030\000\000\000\000���\210�\177\000\000\233�Q\000\000\000\000\000�:�\030\000\000\000\000\200|K�#\000\000\000���\030\000\000\000\000�\202�$4+\000\000\000@\000@", '\0' <repeats 12 times>, "`��\210�\177\000\000\000\000\000\000\000\000\000\000w\000\000\000\212\000\000\000\000@\000@\000\000\000\000p��\210\000\000\000\000�*x\001\000\000\000\000\000@\000@\000\000\000\000���=\000\000\000\000���>" i = 3 any_reflection = 2 mouse_rate = 5 main_count = 172 times_FPS_below_3 = 0 fps = {50, 48, 48, 0, 0} shadows_were_disabled = 0 ---Type <return> to continue, or q <return> to quit--- eye_candy_was_disabled = 0 #7 0x0000000000460f06 in draw_window (win=0x1782af0) at elwindows.c:1193 ret_val = 0 W = (widget_list *) 0x0 #8 0x0000000000461790 in display_window (win_id=1) at elwindows.c:1364 No locals. #9 0x000000000045decd in display_windows (level=1) at elwindows.c:76 id = -2 next_id = -9999 i = 1 #10 0x000000000044d8e8 in draw_scene () at draw_scene.c:144 No locals. #11 0x000000000049b184 in start_rendering () at main.c:191 event = {type = 5 '\005', active = {type = 5 '\005', gain = 0 '\0', state = 1 '\001'}, key = {type = 5 '\005', which = 0 '\0', state = 1 '\001', keysym = {scancode = 138 '\212', sym = SDLK_UNKNOWN, mod = KMOD_NONE, unicode = 0}}, motion = {type = 5 '\005', which = 0 '\0', state = 1 '\001', x = 138, y = 119, xrel = 0, yrel = 0}, button = {type = 5 '\005', which = 0 '\0', button = 1 '\001', state = 1 '\001', x = 138, y = 119}, jaxis = {type = 5 '\005', which = 0 '\0', axis = 1 '\001', value = 138}, jball = {type = 5 '\005', which = 0 '\0', ball = 1 '\001', xrel = 138, yrel = 119}, jhat = { type = 5 '\005', which = 0 '\0', hat = 1 '\001', value = 1 '\001'}, jbutton = {type = 5 '\005', which = 0 '\0', button = 1 '\001', state = 1 '\001'}, resize = {type = 5 '\005', w = 7798922, h = 0}, expose = {type = 5 '\005'}, quit = {type = 5 '\005'}, user = {type = 5 '\005', code = 7798922, data1 = 0x0, data2 = 0x0}, syswm = {type = 5 '\005', msg = 0x0}} network_thread = (SDL_Thread *) 0x17301390 message_queue = (queue_t *) 0x2a98580 done = 0 network_thread_data = {0x2a98580, 0xa02430} last_frame_and_command_update = 14449 #12 0x000000000049b5a6 in main (argc=1, argv=0x7fff88f8ed68) at main.c:324 No locals. Edited May 13, 2008 by rauch Share this post Link to post Share on other sites
Florian Report post Posted May 13, 2008 NEW_WEATHER causes this is NRM: I/O warning : failed to load external entity "./weather.xml" setting area 0 at 96.000000,96.000000 with radius 10000.000000 setting area 0 at 96.000000,96.000000 with radius 10000.000000 Program received signal EXC_ARITHMETIC, Arithmetic exception. 0x00121025 in weather_add_thunder (type=2, x=186.75, y=163.75) at weather.c:600 600 thunder_type = rand()%thunders_defs_count; (gdb) bt full #0 0x00121025 in weather_add_thunder (type=2, x=186.75, y=163.75) at weather.c:600 type = 2 x = 186.75 y = 163.75 Share this post Link to post Share on other sites
Ermabwed Report post Posted May 14, 2008 Checked out just now and get hud.c: In Funktion »context_hud_handler«: hud.c:1032: Warnung: Implizite Deklaration der Funktion »toggle_sounds« hud.c:1032: Fehler: »sound_on« nicht deklariert (erste Benutzung in dieser Funktion) hud.c:1032: Fehler: (Jeder nicht deklarierte Bezeichner wird nur einmal aufgeführt hud.c:1032: Fehler: für jede Funktion in der er auftritt.) hud.c:1034: Warnung: Implizite Deklaration der Funktion »toggle_music« hud.c:1034: Fehler: »music_on« nicht deklariert (erste Benutzung in dieser Funktion) hud.c: In Funktion »context_hud_pre_show_handler«: hud.c:1056: Fehler: »sound_on« nicht deklariert (erste Benutzung in dieser Funktion) hud.c:1058: Fehler: »music_on« nicht deklariert (erste Benutzung in dieser Funktion) make: *** [hud.o] Fehler 1 when compiling without NEW_SOUND. Basically saying implicit declaration of toggle_sounds, sound_on, toggle_music, music_on not declared and implicit declaration of toggle_music in function context_hud_handler, then sound_on, music_on not declared in function context_hud_pre_show_handler. Hints on making gcc complain in English? Share this post Link to post Share on other sites
Florian Report post Posted May 14, 2008 setenv LC_ALL en_US Share this post Link to post Share on other sites
bluap Report post Posted May 14, 2008 when compiling without NEW_SOUND. Basically saying implicit declaration of.... Oops, my bad. Fixed in CVS now; just need the sound.h header, it was conditional on NEW_SOUND before. Share this post Link to post Share on other sites
Florian Report post Posted May 14, 2008 an crash occurs on every magic level up (reproducable), when running in debugger, I can see the level up effect start, then it crashes.backtrace: Program received signal SIGSEGV, Segmentation fault. 0x000000000057026d in ec::MathCache::powf_0_1_rough_close (this=0x9ffe80, base=nan(0x400000), power=0.100000001) at eye_candy/math_cache.cpp:2178 2178 return (powf_map[index1][index2] * (1.0 - percent2)) + (powf_map[index1][index2 + 1] * percent2); Current language: auto; currently c++ (gdb) bt full #0 0x000000000057026d in ec::MathCache::powf_0_1_rough_close (this=0x9ffe80, base=nan(0x400000), power=0.100000001) at eye_candy/math_cache.cpp:2178 index1 = -2147483648 percent2 = 0.600000024 index2 = 28 #1 0x00000000005547ac in ec::Particle::flare (this=0x2aaab107a110) at eye_candy/eye_candy.cpp:837 offset = -24252 exp_base = nan(0x400000) exp = 0 flare_val = 0 __PRETTY_FUNCTION__ = "virtual coord_t ec::Particle::flare() const" #2 0x000000000055494e in ec::Particle::draw (this=0x2aaab107a110, usec=14299) at eye_candy/eye_candy.cpp:716 tempsize = -nan(0x400000) #3 0x00000000005debc7 in ec::GlowParticle::draw (this=0x2aaab107a110, usec=14299) at eye_candy/effect_glow.cpp:786 No locals. #4 0x000000000055317c in ec::EyeCandy::draw (this=0x9ff720) at eye_candy/eye_candy.cpp:1645 p = (class ec::Particle *) 0x2aaab107a110 iter2 = {_M_node = 0x2aaab107a1d0} e = (class ec::Effect *) 0x2aaab108c1c0 iter = {_M_current = 0x182ee3d0} #5 0x000000000053ce00 in ec_draw () at eye_candy_wrapper.cpp:525 cluster = 55 #6 0x000000000046af91 in display_game_handler (win=0x1779af0) at gamewin.c:1230 str = "XX�i�\177\000\000`X�i�\177\000\000\230��\027\000\000\000\000PX�i�\177\000\000pX�i\\\000\000\000���@t+\000\000�X�i�\177\000\000\000\000\000\000\000\000\000\000�Z�i�\177", '\0' <repeats 18 times>, "\016\002\000At+\000\000\000@\000@\000\000\000\000u\231F\000\000\000\000\000�Z�i�\177\000\000\000\000\000\000\000\000\000\000�\002\000\000/\002\000\000\000@\000@\000\000\000\000�X�i\000\000\000\000�\232w\001\000\000\000\000\000@\000@\000\000\000\000���=\000\000\000\000���>" i = 1 any_reflection = 0 mouse_rate = 5 main_count = 6992 times_FPS_below_3 = 0 fps = {92, 93, 93, 92, 92} shadows_were_disabled = 0 ---Type <return> to continue, or q <return> to quit--- eye_candy_was_disabled = 0 #7 0x0000000000459e0e in draw_window (win=0x1779af0) at elwindows.c:1193 ret_val = 0 W = (widget_list *) 0x0 #8 0x000000000045a698 in display_window (win_id=1) at elwindows.c:1364 No locals. #9 0x0000000000456dd5 in display_windows (level=1) at elwindows.c:76 id = -2 next_id = -9999 i = 1 #10 0x000000000044d898 in draw_scene () at draw_scene.c:144 No locals. #11 0x0000000000494050 in start_rendering () at main.c:191 event = {type = 24 '\030', active = {type = 24 '\030', gain = 36 '$', state = 0 '\0'}, key = {type = 24 '\030', which = 36 '$', state = 0 '\0', keysym = {scancode = 1 '\001', sym = 1090528510, mod = 11124, unicode = 52294}}, motion = {type = 24 '\030', which = 36 '$', state = 0 '\0', x = 1, y = 0, xrel = 9470, yrel = 16640}, button = {type = 24 '\030', which = 36 '$', button = 0 '\0', state = 65 'A', x = 1, y = 0}, jaxis = {type = 24 '\030', which = 36 '$', axis = 0 '\0', value = 1}, jball = {type = 24 '\030', which = 36 '$', ball = 0 '\0', xrel = 1, yrel = 0}, jhat = { type = 24 '\030', which = 36 '$', hat = 0 '\0', value = 65 'A'}, jbutton = {type = 24 '\030', which = 36 '$', button = 0 '\0', state = 65 'A'}, resize = {type = 24 '\030', w = 1, h = 1090528510}, expose = {type = 24 '\030'}, quit = {type = 24 '\030'}, user = {type = 24 '\030', code = 1, data1 = 0x2b74410024fe, data2 = 0x4829cc46}, syswm = {type = 24 '\030', msg = 0x2b74410024fe}} network_thread = (SDL_Thread *) 0x2ab0f40 message_queue = (queue_t *) 0x2a98420 done = 0 network_thread_data = {0x2a98420, 0x9f9250} last_frame_and_command_update = 90022 #12 0x0000000000494472 in main (argc=1, argv=0x7fff69d05ae8) at main.c:324 No locals. Edit: In Request from Florian new traceback with -DDEBUG_NANS ERROR: Invalid particle 0x2aaab01f54a0: pos=<nan, nan, nan>; velocity=<nan, nan, nan>; effect=0x2aaab01c13b0 Program received signal SIGSEGV, Segmentation fault. 0x0000000000577541 in ec::MathCache::powf_0_1_rough_close (this=0xa09060, base=nan(0x400000), power=0.100000001) at eye_candy/math_cache.cpp:2178 2178 return (powf_map[index1][index2] * (1.0 - percent2)) + (powf_map[index1][index2 + 1] * percent2); Current language: auto; currently c++ (gdb) bt full #0 0x0000000000577541 in ec::MathCache::powf_0_1_rough_close (this=0xa09060, base=nan(0x400000), power=0.100000001) at eye_candy/math_cache.cpp:2178 index1 = -2147483648 percent2 = 0.600000024 index2 = 28 #1 0x000000000055cb8d in ec::Particle::flare (this=0x2aaab01f54a0) at eye_candy/eye_candy.cpp:837 offset = 21716 exp_base = nan(0x400000) exp = 0.653237939 flare_val = -nan(0x400000) __PRETTY_FUNCTION__ = "virtual coord_t ec::Particle::flare() const" #2 0x000000000055b926 in ec::Particle::draw (this=0x2aaab01f54a0, usec=19897) at eye_candy/eye_candy.cpp:716 tempsize = -nan(0x400000) #3 0x00000000005e5e9b in ec::GlowParticle::draw (this=0x2aaab01f54a0, usec=19897) at eye_candy/effect_glow.cpp:786 No locals. #4 0x000000000055a2b0 in ec::EyeCandy::draw (this=0xa08900) at eye_candy/eye_candy.cpp:1645 p = (class ec::Particle *) 0x2aaab01f54a0 iter2 = {_M_node = 0x2aaab01f5560} e = (class ec::Effect *) 0x2aaab01c13b0 iter = {_M_current = 0x2aaab0172518} #5 0x0000000000543f34 in ec_draw () at eye_candy_wrapper.cpp:525 cluster = 1 #6 0x0000000000472089 in display_game_handler (win=0x1782af0) at gamewin.c:1230 str = "���\210�\177\000\000���\210�\177\000\000�:�\030\000\000\000\000���\210�\177\000\000���\210\214\000\000\000���\030\000\000\000\000���\210�\177\000\000\233�Q\000\000\000\000\000�:�\030\000\000\000\000\200|K�#\000\000\000���\030\000\000\000\000�\202�$4+\000\000\000@\000@", '\0' <repeats 12 times>, "`��\210�\177\000\000\000\000\000\000\000\000\000\000w\000\000\000\212\000\000\000\000@\000@\000\000\000\000p��\210\000\000\000\000�*x\001\000\000\000\000\000@\000@\000\000\000\000���=\000\000\000\000���>" i = 3 any_reflection = 2 mouse_rate = 5 main_count = 172 times_FPS_below_3 = 0 fps = {50, 48, 48, 0, 0} shadows_were_disabled = 0 ---Type <return> to continue, or q <return> to quit--- eye_candy_was_disabled = 0 #7 0x0000000000460f06 in draw_window (win=0x1782af0) at elwindows.c:1193 ret_val = 0 W = (widget_list *) 0x0 #8 0x0000000000461790 in display_window (win_id=1) at elwindows.c:1364 No locals. #9 0x000000000045decd in display_windows (level=1) at elwindows.c:76 id = -2 next_id = -9999 i = 1 #10 0x000000000044d8e8 in draw_scene () at draw_scene.c:144 No locals. #11 0x000000000049b184 in start_rendering () at main.c:191 event = {type = 5 '\005', active = {type = 5 '\005', gain = 0 '\0', state = 1 '\001'}, key = {type = 5 '\005', which = 0 '\0', state = 1 '\001', keysym = {scancode = 138 '\212', sym = SDLK_UNKNOWN, mod = KMOD_NONE, unicode = 0}}, motion = {type = 5 '\005', which = 0 '\0', state = 1 '\001', x = 138, y = 119, xrel = 0, yrel = 0}, button = {type = 5 '\005', which = 0 '\0', button = 1 '\001', state = 1 '\001', x = 138, y = 119}, jaxis = {type = 5 '\005', which = 0 '\0', axis = 1 '\001', value = 138}, jball = {type = 5 '\005', which = 0 '\0', ball = 1 '\001', xrel = 138, yrel = 119}, jhat = { type = 5 '\005', which = 0 '\0', hat = 1 '\001', value = 1 '\001'}, jbutton = {type = 5 '\005', which = 0 '\0', button = 1 '\001', state = 1 '\001'}, resize = {type = 5 '\005', w = 7798922, h = 0}, expose = {type = 5 '\005'}, quit = {type = 5 '\005'}, user = {type = 5 '\005', code = 7798922, data1 = 0x0, data2 = 0x0}, syswm = {type = 5 '\005', msg = 0x0}} network_thread = (SDL_Thread *) 0x17301390 message_queue = (queue_t *) 0x2a98580 done = 0 network_thread_data = {0x2a98580, 0xa02430} last_frame_and_command_update = 14449 #12 0x000000000049b5a6 in main (argc=1, argv=0x7fff88f8ed68) at main.c:324 No locals. fixed in CVS with the help of Greypal Share this post Link to post Share on other sites
ago Report post Posted May 16, 2008 NEW_WEATHER causes this is NRM: I/O warning : failed to load external entity "./weather.xml" setting area 0 at 96.000000,96.000000 with radius 10000.000000 setting area 0 at 96.000000,96.000000 with radius 10000.000000 Program received signal EXC_ARITHMETIC, Arithmetic exception. 0x00121025 in weather_add_thunder (type=2, x=186.75, y=163.75) at weather.c:600 600 thunder_type = rand()%thunders_defs_count; (gdb) bt full #0 0x00121025 in weather_add_thunder (type=2, x=186.75, y=163.75) at weather.c:600 type = 2 x = 186.75 y = 163.75 no weather.xml means no thunder defintions are loaded therefore thunders_defs_count == 0 --> divison by zero Guarding the whole block with thunder_defs_count > 0 should help Share this post Link to post Share on other sites
Schmurk Report post Posted May 16, 2008 Yep, I'll fix it at my next commit. Share this post Link to post Share on other sites
kibora Report post Posted May 17, 2008 (edited) A couple fixes needed to compile with VC 1. All the functions in dbuffer.h should be __inline__, not inline 2. In text_aliases.c #define TADEBUG(x...) should be #define TADEBUG(x,...) 3. The std::max calls don't compile in effect_missile.cpp and effect_ongoing.cpp 4. pow(age_f, 2.0) in effect_ongoing.cpp should be pow(age_f, 2.0f) Also i see some awful flickering in the top right angle with the latest CVS (something with the new weather?). The flickering stopped when a rain started and didn't start again after the rain. Cannot reproduce it Edited May 17, 2008 by kibora Share this post Link to post Share on other sites
Florian Report post Posted May 17, 2008 1. All the functions in dbuffer.h should be __inline__, not inline fixed2. In text_aliases.c #define TADEBUG(x...) should be #define TADEBUG(x,...) fixed 3. The std::max calls don't compile in effect_missile.cpp and effect_ongoing.cpp fixed, hopefully 4. pow(age_f, 2.0) in effect_ongoing.cpp should be pow(age_f, 2.0f) fixed Share this post Link to post Share on other sites
kibora Report post Posted May 17, 2008 std::max is not fixed but i figured out how to fix it. effect_missile.cpp and effect_ongoing.cpp need #include "platform.h" Share this post Link to post Share on other sites
Florian Report post Posted May 17, 2008 (edited) OMG I just loooooooooove Microsoft ... http://www.devx.com/tips/Tip/14540 platform.h in the EC framework is not a good idea, I think I'll #ifdef the function calls to check for MSVC++ /EDIT fixed in CVS Edited May 17, 2008 by Florian Share this post Link to post Share on other sites
ago Report post Posted May 18, 2008 (edited) fix for crash in weather.c diff -u -r1.94 weather.c --- weather.c 16 May 2008 22:00:19 -0000 1.94 +++ weather.c 18 May 2008 13:24:09 -0000 @@ -588,7 +588,7 @@ void weather_add_thunder(int type, float x, float y) { - if (thunders_count < MAX_THUNDERS) + if (thunders_count < MAX_THUNDERS && thunders_defs_count > 0) { // store the thunder for the sound thunders[thunders_count].type = type; fixes for various crashes regarding unsupported OpenGL extensions Index: 3d_objects.c =================================================================== RCS file: /cvsroot/elc/elc/3d_objects.c,v retrieving revision 1.179 diff -u -r1.179 3d_objects.c --- 3d_objects.c 29 Apr 2008 14:47:14 -0000 1.179 +++ 3d_objects.c 16 May 2008 13:15:14 -0000 @@ -241,9 +241,15 @@ #endif - ELglDrawRangeElementsEXT(GL_TRIANGLES, + if (ELglDrawRangeElementsEXT) + ELglDrawRangeElementsEXT(GL_TRIANGLES, object_id->e3d_data->materials[material_index].triangles_indicies_min, object_id->e3d_data->materials[material_index].triangles_indicies_max, + object_id->e3d_data->materials[material_index].triangles_indicies_count, + object_id->e3d_data->index_type, + object_id->e3d_data->materials[material_index].triangles_indicies_index); + else + glDrawElements(GL_TRIANGLES, object_id->e3d_data->materials[material_index].triangles_indicies_count, object_id->e3d_data->index_type, object_id->e3d_data->materials[material_index].triangles_indicies_index); Index: reflection.c =================================================================== RCS file: /cvsroot/elc/elc/reflection.c,v retrieving revision 1.157 diff -u -r1.157 reflection.c --- reflection.c 15 May 2008 23:24:08 -0000 1.157 +++ reflection.c 18 May 2008 13:24:09 -0000 @@ -315,7 +315,8 @@ } glDrawArrays(GL_QUADS, water_buffer_reflectiv_index * 4, (water_buffer_usage - water_buffer_reflectiv_index) * 4); - ELglBindBufferARB(GL_ARRAY_BUFFER_ARB, 0); + if (use_vertex_buffers) + ELglBindBufferARB(GL_ARRAY_BUFFER_ARB, 0); glDisableClientState(GL_VERTEX_ARRAY); /* Re-enable update of color and depth. */ This is a fix for a rare and strange crash. OpenGL failed to init even to software rendering Index: gl_init.c =================================================================== RCS file: /cvsroot/elc/elc/gl_init.c,v retrieving revision 1.162 diff -u -r1.162 gl_init.c --- gl_init.c 15 May 2008 00:10:33 -0000 1.162 +++ gl_init.c 18 May 2008 13:24:08 -0000 @@ -436,9 +436,15 @@ GLubyte *my_string; int have_hardware; - my_string=(GLubyte *)glGetString(GL_RENDERER); - len=strlen(my_string); - have_hardware=get_string_occurance("gdi generic",my_string,len,0); + my_string=(GLubyte *)glGetString(GL_RENDERER); + if (my_string == NULL) { + len = 0; + have_hardware = 0; + LOG_TO_CONSOLE(c_red1,"glGetString(GL_RENDERER) failed"); + } else { + len=strlen(my_string); + have_hardware=get_string_occurance("gdi generic",my_string,len,0); + } if(have_hardware != -1) { //let the user know there is a problem LOG_TO_CONSOLE(c_red1,stencil_falls_back_on_software_accel); @@ -455,8 +461,14 @@ have_stencil=0; my_string=(GLubyte *)glGetString(GL_RENDERER); - len=strlen(my_string); - have_hardware=get_string_occurance("gdi generic",my_string,len,0); + if (my_string == NULL) { + len = 0; + have_hardware = 0; + LOG_TO_CONSOLE(c_red1,"glGetString(GL_RENDERER) failed"); + } else { + len=strlen(my_string); + have_hardware=get_string_occurance("gdi generic",my_string,len,0); + } if(have_hardware != -1) { //wtf, this really shouldn't happen.... //let's try a default mode, maybe Quake 2's mode, and pray it works @@ -477,8 +489,14 @@ SDL_SetVideoMode(window_width, window_height, bpp, flags); //see if it worked... my_string=(GLubyte *)glGetString(GL_RENDERER); - len=strlen(my_string); - have_hardware=get_string_occurance("gdi generic",my_string,len,0); + if (my_string == NULL) { + len = 0; + have_hardware = 0; + LOG_TO_CONSOLE(c_red1,"glGetString(GL_RENDERER) failed"); + } else { + len=strlen(my_string); + have_hardware=get_string_occurance("gdi generic",my_string,len,0); + } if(have_hardware != -1) { //wtf, this really shouldn't happen.... //let's try a default mode, maybe Quake 2's mode, and pray it works Another issue: There are about 100 locations where ELglActiveTextureARB() is not checked for MultiTexture availability but this can be worked around by setting poor man (actually disabling all the shadows) fixes for VC problems isalpha takes int argument. for example the character 0xff is converted to -1 instead of 255 which leads to assertation failure in VC Index: asc.c =================================================================== RCS file: /cvsroot/elc/elc/asc.c,v retrieving revision 1.79 diff -u -r1.79 asc.c --- asc.c 13 Apr 2008 00:17:27 -0000 1.79 +++ asc.c 13 May 2008 11:08:22 -0000 @@ -280,8 +280,8 @@ if(!src || !src[0] || !src[1] || !src[2] || len == 0) return 0; while(*src && len > 0) { - if(isalpha(*src)) alpha++; - if((isdigit(*src)&&alpha<len/2) || *src != toupper(*src)) return 0; //at least one lower + if(isalpha((unsigned char)*src)) alpha++; + if((isdigit((unsigned char)*src)&&alpha<len/2) || *src != toupper(*src)) return 0; //at least one lower src++; len--; } Index: text.c =================================================================== RCS file: /cvsroot/elc/elc/text.c,v retrieving revision 1.186 diff -u -r1.186 text.c --- text.c 9 May 2008 20:05:37 -0000 1.186 +++ text.c 13 May 2008 11:08:37 -0000 @@ -340,7 +340,7 @@ const char * const month_names[] = { "Aluwia", "Seedar", "Akbar", "Zartia", "Elandra", "Viasia", "Fruitfall", "Mortia", "Carnelar", "Nimlos", "Chimar", "Vespia" }; const char * const day_names[] = { "1st", "2nd", "3rd", "4th", "5th", "6th", "7th", "8th", "9th", "10th", "11th", "12th", "13th", "14th", "15th", "16th", "17th", "18th", "19th", "20th", "21st", "22nd", "23rd", "24th", "25th", "26th", "27th", "28th", "29th", "30th" }; char new_str[100]; - const char *ptr=text_to_add; + const unsigned char *ptr=text_to_add; short unsigned int day=1, month=1, year=0; int offset = 0; Another assertation failure in VC Index: keys.c =================================================================== RCS file: /cvsroot/elc/elc/keys.c,v retrieving revision 1.49 diff -u -r1.49 keys.c --- keys.c 14 May 2008 21:43:54 -0000 1.49 +++ keys.c 18 May 2008 13:24:08 -0000 @@ -354,7 +354,8 @@ #else f=my_fopen("key.ini","rb"); - fstat (fileno (f), &key_file); + if (f) + fstat (fileno (f), &key_file); #endif if(!f) Edited May 18, 2008 by ago Share this post Link to post Share on other sites
Florian Report post Posted May 18, 2008 changes to text.c cause warnings: text.c: In function 'filter_or_ignore_text': text.c:343: warning: pointer targets in initialization differ in signedness text.c:359: warning: pointer targets in passing argument 1 of 'sscanf' differ in signedness I applied all other patches to CVS. Share this post Link to post Share on other sites
Alberich Report post Posted May 19, 2008 spells.c: In function `display_spells_we_have': spells.c:344: error: `bool' undeclared (first use in this function) spells.c:344: error: (Each undeclared identifier is reported only once spells.c:344: error: for each function it appears in.) spells.c:344: error: syntax error before "destroy_shield" spells.c:396: error: `destroy_shield' undeclared (first use in this function) spells.c:407: error: `destroy_magic_protection' undeclared (first use in this function) spells.c:418: error: `destroy_poison' undeclared (first use in this function) spells.c:429: error: `destroy_magic_immunity' undeclared (first use in this function) There is no bool in C, #include <stdbool.h> fixed it for me in my dev-c++ environment. Share this post Link to post Share on other sites
Florian Report post Posted May 19, 2008 There is no bool in C OMG RLY? I'm so n00b fixed in CVS Share this post Link to post Share on other sites
ago Report post Posted May 19, 2008 (edited) Workaround for the distorted geometry bug and a crash on ATI Mobility Radeon M6. patch It simply allows to disable glDrawRangeElements and fallback to glDrawElements. Disabling DrawRangeElements will hit FPS hard, but at least it looks good again and does not crash anymore. Before: After: Edited May 19, 2008 by ago Share this post Link to post Share on other sites
Florian Report post Posted May 19, 2008 Applied, builds cleanly. Impact on FPS is zero, at least on my system. Commited. Share this post Link to post Share on other sites
Guest BloodyMary Report post Posted June 8, 2008 Hi, I've found 2 small bugs in lights.c and textures.c, while compiling from CVS. Here is my make.conf: # set this to "no" if you don't want this file to be overwritten UPDATE_CONF=yes # tune these for your setup & compile options # IMPORTANT: if you are using a linker that needs libraries in correct order, make sure you list EYE_CANDY before PNG_SCREENSHOT if you use both FEATURES += ANTI_ALIAS # allows to enable/disable anti-aliasing in el.ini FEATURES += CLUSTER_INSIDES # Group objects into separate clusters for clipping on inside maps FEATURES += CONTEXT_MENUS # Enable context menus #FEATURES += CONTEXT_MENUS_TEST # Enable "#cmwin" command to help test/demo the context menu code FEATURES += CUSTOM_LOOK # allows you to customize your look. FEATURES += CUSTOM_UPDATE # allows autoupdating of custom look information #FEATURES += DEBUG # (undocumented) #FEATURES += DEBUG_XML # Enables missing (optional) XML string property messages #FEATURES += DEBUG_POINT_PARTICLES # (undocumented) #FEATURES += DEBUG_TIME # Fakes the acceleration of time for use in debugging shadows and the like. FEATURES += DYNAMIC_ANIMATIONS # Synchronizes animation to FPS instead of a fixed timer #FEATURES += ECDEBUGWIN # press ctrl-alt-c to open the Eye Candy debug window: trigger most effects without casting spells or server side events #FEATURES += EL_BIG_ENDIAN # (undocumented) FIXME: Should be removed and set in the code (as is done for OSX. Is it needed on any other platform?) #FEATURES += EXTRA_DEBUG # (undocumented) #FEATURES += FUZZY_PATHS # Makes Tab Map walking not always follow exaclty the same path #FEATURES += MEMORY_DEBUG # gather information about memory allocation and freeing FEATURES += MINIMAP2 # Disables the rectangular minimap and enables the rotating minimap #FEATURES += MISSILES_DEBUG # Enables debug for missiles feature. It will create a file missiles_log.txt file in your settings directory. #FEATURES += MUTEX_DEBUG # (undocumented) FEATURES += NEW_ALPHA # (undocumented) FEATURES += NEW_CAMERA_MOTION # Changes the behaviour of the camera by replacing the rotation duration by a constant deceleration. This gives a better control on the positionning of the camera. #FEATURES += NEW_CURSOR # New coloured cursors made by Emajekral (Experimental) Extract [url="http://users.on.net/~gingerman/sky_cursor-textures.zip"]http://users.on.net/~gingerman/sky_cursor-textures.zip[/url] into datadir/textures/ FEATURES += NEW_LIGHTING # (undocumented) #FEATURES += NEW_MAP_FORMAT # (undocumented) FEATURES += NEW_SELECTION # Enables new selection system. Needs OpenGL 1.3 or GL_ARB_texture_env_combine FEATURES += NEW_SOUND # Enables extended sound effects system - almost pointless without OGG_VORBIS FEATURES += NEW_TEX # use new texture coordinates for enhanced actors FEATURES += NEW_WEATHER # new weather effects FEATURES += NIGHT_TEXTURES # enable night textures. changes textures at night to cooler colors #FEATURES += NO_PF_MACRO # (undocumented) #FEATURES += OPENGL_TRACE # make far more frequent checks for OpenGL errors (requires -DDEBUG to be of any use). Will make error_log.txt a lot larger. #FEATURES += PARANOID_CAMERA # (undocumented) #FEATURES += PAWN # Experimental, not for release, will need server support to function properly. This *will* eat your cat. You've been warned. Enables the Pawn abstract machine. FEATURES += PNG_SCREENSHOT # make screenshots in W3C's PNG format in game, requires libpng #FEATURES += SIMPLE_LOD # enable a simplistic distance culling to improve performance FEATURES += SKY_FPV # Use skybox with clouds/stars/etc, enable first person view, and other misc changes from Emajekral (Experimental) Extract [url="http://users.on.net/~gingerman/sky_cursor-textures.zip"]http://users.on.net/~gingerman/sky_cursor-textures.zip[/url] into datadir/textures/ FEATURES += TEXT_ALIASES # Text aliases #FEATURES += TIMER_CHECK # (undocumented) #FEATURES += UID # use unique ID sent from server for custom looks. (INCOMPLETE) #FEATURES += UNROLL4 # (undocumented) #FEATURES += USE_ACTORS_OPTIMIZER # Enables actor optimizations #FEATURES += USE_BOOST FEATURES += USE_INLINE # enable some optimizations to use inline functions instead of pure function calls FEATURES += USE_SHADER # Using shaders for water rendering. Needs NEW_FILE_IO #FEATURES += USE_TR1 # Needs tr1 version of c++ stl, used for NEW_FILE_IO #FEATURES += WRITE_XML # dangerous to use, will wipe out some XML files that are part of the main game download FEATURES += ZLIB # Enables being able to read gzip compressed files, requires -lzlib/-lz #FEATURES += ZLIBW # Enables being able to write gzip compressed files, requires -lzlib/-lz needed for map_editor PLATFORM=-march=i686 XDIR=-L/usr/X11R6/lib CWARN=-Wall -Wdeclaration-after-statement # -Wno-pointer-sign -Wno-sign-compare -Werror CXXWARN=-Wall # -Wno-sign-compare -Werror ## These needed to be adjusted on a per system basis based on compile options & library versions ## These 2 lines should be uncommented if you used Emajekral's Windows compilation how-to (adjust them if required) #EXTRA_LIBS=-lstdc++ #EXTRA_INCLUDES=-IC:\\Dev-Cpp\\Include\\AL -IC:\\Dev-Cpp\\Include\\SDL ## These are the originally listed settings, uncomment them if you need them #EXTRA_INCLUDES=-IC:\\Programme\\Dev-Cpp\\Include #EXTRA_LIBS=-lalut -lz #EXTRA_STATICLIBS=libs/libalut.a libs/zlib.a CC=gcc CXX=g++ LINK=gcc I got an error while compiling, if d is not declared. lights.c(about line 830) void build_sun_pos_table() { #ifndef SKY_FPV float d = 400; #endif // SKY_FPV int i; #ifdef NEW_LIGHTING if (use_new_lighting) { float d = 400; for(i=0;i<360;i++) { sun_pos[i].x=d*cos((float)(i-30)*M_PI/180.0f); sun_pos[i].y=0.0f; sun_pos[i].z=d*(sin((float)(i-30)*M_PI/180.0f) + 0.6); if (sun_pos[i].z < 50) sun_pos[i].z = 100 - sun_pos[i].z; sun_pos[i].w=0.0f; } } else { #endif // NEW_LIGHTING I have added "loat d = 400" to "if (use_new_lighting)", it works... The next error was in "textures.c"(about line 1690) #ifdef MINIMAP2 GLuint load_bmp8_fixed_alpha_with_transparent_color(texture_cache_struct * tex_cache_entry, Uint8 a,Uint8 tr,Uint8 tg,Uint8 tb) { int x_size, y_size,i; #ifdef NEW_LIGHTING #endif "i" was declared a second time after the "#ifdef NEW_LIGHTING" comment, ive removed it. I hope I could help you a bit. I am sorry for my bad english. Share this post Link to post Share on other sites