diff options
author | /dev/humancontroller <devhc@example.com> | 2014-07-12 23:07:02 +0200 |
---|---|---|
committer | /dev/humancontroller <devhc@example.com> | 2017-03-09 13:51:07 +0100 |
commit | 0dfd0b1df9633d0f6378cc5096b7e8114d009a28 (patch) | |
tree | fa734d7adcf06c4cef91936b2b9f4cc98bdc903d /src/client/cl_cgame.c | |
parent | 3c08da6086d5c2431dd929543ed89afb79956423 (diff) |
do not close the console "from time to time"
alter a bunch of cases where Key_SetCatcher() turns off the KEYCATCH_CONSOLE flag. remove all uses of Con_Close() and the function itself altogether. the console is now only togglable by a console key or with the toggleconsole command.
Diffstat (limited to 'src/client/cl_cgame.c')
-rw-r--r-- | src/client/cl_cgame.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/client/cl_cgame.c b/src/client/cl_cgame.c index 23f3010c..9ce67455 100644 --- a/src/client/cl_cgame.c +++ b/src/client/cl_cgame.c @@ -619,10 +619,10 @@ intptr_t CL_CgameSystemCalls( intptr_t *args ) { return Key_IsDown( args[1] ); case CG_KEY_GETCATCHER: return Key_GetCatcher(); - case CG_KEY_SETCATCHER: - // Don't allow the cgame module to close the console - Key_SetCatcher( args[1] | ( Key_GetCatcher( ) & KEYCATCH_CONSOLE ) ); - return 0; + case CG_KEY_SETCATCHER: + // don't allow the cgame module to toggle the console + Key_SetCatcher( ( args[1] & ~KEYCATCH_CONSOLE ) | ( Key_GetCatcher() & KEYCATCH_CONSOLE ) ); + return 0; case CG_KEY_GETKEY: return Key_GetKey( VMA(1) ); @@ -755,9 +755,6 @@ void CL_InitCGame( void ) { t1 = Sys_Milliseconds(); - // put away the console - Con_Close(); - // find the current mapname info = cl.gameState.stringData + cl.gameState.stringOffsets[ CS_SERVERINFO ]; mapname = Info_ValueForKey( info, "mapname" ); |