summaryrefslogtreecommitdiff
path: root/src/sv_main.c
diff options
context:
space:
mode:
authorAndrey Nazarov <skuller@skuller.net>2011-05-26 13:25:08 +0400
committerAndrey Nazarov <skuller@skuller.net>2011-05-26 13:25:08 +0400
commitd7bcacd9fb01162c70f5f44ed9bea360c1ad4be4 (patch)
treea6b2de2fccbea7b703281bd5f61521c3cb1077ff /src/sv_main.c
parentf5624d2154c1aabc67a45c1e82cd25550df33a14 (diff)
Improve client event loop.
Execute command buffers directly inside CL_ProcessEvents. Break sub-msec spin loop when important event occurs.
Diffstat (limited to 'src/sv_main.c')
-rw-r--r--src/sv_main.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/sv_main.c b/src/sv_main.c
index 9ede239..2517779 100644
--- a/src/sv_main.c
+++ b/src/sv_main.c
@@ -1622,6 +1622,11 @@ unsigned SV_Frame( unsigned msec ) {
// advance local server time
svs.realtime += msec;
+ if( Com_IsDedicated() ) {
+ // process console commands if not running a client
+ Cbuf_Execute( &cmd_buffer );
+ }
+
#if USE_MVD_CLIENT
// run connections to MVD/GTV servers
MVD_Frame();