Skip to content

Commit

Permalink
Dedicated Server|Performance: Skip unnecessary tasks
Browse files Browse the repository at this point in the history
The Materials ticker is fully capable of updating everything on clientside;
it serves no function on the dedicated server.
  • Loading branch information
skyjake committed Apr 10, 2012
1 parent 8a0bd72 commit 24df3f4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion doomsday/engine/portable/src/dd_input.c
Expand Up @@ -107,6 +107,7 @@ inputdev_t inputDevices[NUM_INPUT_DEVICES];

// PRIVATE DATA DEFINITIONS ------------------------------------------------

static boolean inputDisabledFully = false;
static boolean ignoreInput = false;

static byte shiftKeyMappings[NUMKKEYS], altKeyMappings[NUMKKEYS];
Expand Down Expand Up @@ -754,6 +755,8 @@ void DD_InitInput(void)
{
int i;

inputDisabledFully = ArgExists("-noinput");

for(i = 0; i < 256; ++i)
{
if(i >= 32 && i <= 127)
Expand Down Expand Up @@ -1050,7 +1053,7 @@ static void dispatchEvents(eventqueue_t* q, timespan_t ticLength)
*/
static void postEvents(timespan_t ticLength)
{
if(ArgExists("-noinput")) return;
if(inputDisabledFully) return;

DD_ReadKeyboard();

Expand Down
2 changes: 1 addition & 1 deletion doomsday/engine/portable/src/materials.c
Expand Up @@ -1075,7 +1075,7 @@ void Materials_Ticker(timespan_t time)
materiallist_node_t* node;

// The animation will only progress when the game is not paused.
if(clientPaused) return;
if(clientPaused || novideo) return;

node = materials;
while(node)
Expand Down

0 comments on commit 24df3f4

Please sign in to comment.