X-Git-Url: https://git.jsancho.org/?a=blobdiff_plain;f=Source%2FOpenGL_Windows.cpp;h=24fcd87d438d3178344cd36115804321db913e89;hb=82780a8852d09fa443add4565cebef4f6faefd4a;hp=1fa7ec4d39c734ee1ac358d822c8c8ce068e526a;hpb=bbf23bafff5fa21216ae4d182b77180a23d2b99f;p=lugaru.git diff --git a/Source/OpenGL_Windows.cpp b/Source/OpenGL_Windows.cpp index 1fa7ec4..24fcd87 100644 --- a/Source/OpenGL_Windows.cpp +++ b/Source/OpenGL_Windows.cpp @@ -227,7 +227,7 @@ Game * pgame = 0; static int _argc = 0; static char **_argv = NULL; -static bool cmdline(const char *cmd) +bool cmdline(const char *cmd) { for (int i = 1; i < _argc; i++) { @@ -525,7 +525,7 @@ static void sdlEventProc(const SDL_Event &e, Game &game) SDL_WM_ToggleFullScreen(SDL_GetVideoSurface()); } - else if (e.key.keysym.sym < SDLK_LAST) + if (e.key.keysym.sym < SDLK_LAST) { if (KeyTable[e.key.keysym.sym] != 0xffff) SetKey(KeyTable[e.key.keysym.sym]); @@ -1302,6 +1302,10 @@ void CleanUp (void) // the context is destroyed and libGL unloaded by SDL_Quit(). pglDeleteTextures = glDeleteTextures_doNothing; + #if PLATFORM_LINUX + _exit(0); // !!! FIXME: hack...crashes on exit! + #endif + #elif (defined WIN32) if (hRC) { @@ -2366,7 +2370,7 @@ int main(int argc, char **argv) extern int channels[100]; extern FSOUND_SAMPLE * samp[100]; - extern FSOUND_STREAM * strm[10]; + extern FSOUND_STREAM * strm[20]; extern "C" void PlaySoundEx(int chan, FSOUND_SAMPLE *sptr, FSOUND_DSPUNIT *dsp, signed char startpaused) {