mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-17 22:50:51 +00:00
get nq-server working properly
This commit is contained in:
parent
f55bac4c06
commit
589c3e4e49
4 changed files with 5 additions and 5 deletions
|
@ -448,6 +448,7 @@ C_ProcessInput (void)
|
|||
#endif
|
||||
while (1) {
|
||||
const char *cmd = Sys_ConsoleInput ();
|
||||
printf ("%s\n", cmd);
|
||||
if (!cmd)
|
||||
break;
|
||||
Cbuf_AddText (con_data.cbuf, cmd);
|
||||
|
|
|
@ -516,7 +516,7 @@ Sys_CheckInput (int idle, int net_socket)
|
|||
}
|
||||
|
||||
_timeout.tv_sec = 0;
|
||||
_timeout.tv_usec = 100;
|
||||
_timeout.tv_usec = net_socket < 0 ? 0 : 100;
|
||||
timeout = &_timeout;
|
||||
if (_kbhit ()) {
|
||||
stdin_ready = 1;
|
||||
|
@ -524,7 +524,7 @@ Sys_CheckInput (int idle, int net_socket)
|
|||
}
|
||||
#else
|
||||
_timeout.tv_sec = 0;
|
||||
_timeout.tv_usec = 10000;
|
||||
_timeout.tv_usec = net_socket < 0 ? 0 : 10000;
|
||||
#endif
|
||||
// select on the net socket and stdin
|
||||
// the only reason we have a timeout at all is so that if the last
|
||||
|
|
|
@ -108,8 +108,7 @@ main (int argc, const char **argv)
|
|||
|
||||
oldtime = Sys_DoubleTime () - 0.1;
|
||||
while (1) { // Main message loop
|
||||
if (!Sys_CheckInput (0, -1))
|
||||
continue;
|
||||
Sys_CheckInput (0, -1);
|
||||
|
||||
// find time spent rendering last frame
|
||||
newtime = Sys_DoubleTime ();
|
||||
|
|
Loading…
Reference in a new issue