Skip to content

Commit

Permalink
Client: Fixed HUD info updates
Browse files Browse the repository at this point in the history
Keycards, ammo, etc. were not updated in the client's status bar.
  • Loading branch information
skyjake committed Apr 19, 2011
1 parent cf2e72e commit 27484a2
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 19 deletions.
31 changes: 15 additions & 16 deletions doomsday/plugins/jdoom/src/st_stuff.c
Expand Up @@ -806,31 +806,30 @@ void ST_Ticker(void)
{
int i;

if(P_IsPaused()) return;

for(i = 0; i < MAXPLAYERS; ++i)
{
player_t* plr = &players[i];
hudstate_t* hud = &hudStates[i];

if(!(plr->plr->inGame && (plr->plr->flags & DDPF_LOCAL)))
if(!plr->plr->inGame) // && (plr->plr->flags & DDPF_LOCAL)))
continue;

if(!P_IsPaused())
if(cfg.hudTimer == 0)
{
if(cfg.hudTimer == 0)
{
hud->hideTics = hud->hideAmount = 0;
}
else
{
if(hud->hideTics > 0)
hud->hideTics--;
if(hud->hideTics == 0 && cfg.hudTimer > 0 && hud->hideAmount < 1)
hud->hideAmount += 0.1f;
}

ST_updateWidgets(i);
hud->oldHealth = plr->health;
hud->hideTics = hud->hideAmount = 0;
}
else
{
if(hud->hideTics > 0)
hud->hideTics--;
if(hud->hideTics == 0 && cfg.hudTimer > 0 && hud->hideAmount < 1)
hud->hideAmount += 0.1f;
}

ST_updateWidgets(i);
hud->oldHealth = plr->health;
}
}

Expand Down
2 changes: 1 addition & 1 deletion doomsday/plugins/jdoom64/src/st_stuff.c
Expand Up @@ -187,7 +187,7 @@ void ST_Ticker(void)
player_t* plr = &players[i];
hudstate_t* hud = &hudStates[i];

if(!(plr->plr->inGame && (plr->plr->flags & DDPF_LOCAL)))
if(!plr->plr->inGame) // && (plr->plr->flags & DDPF_LOCAL)))
continue;

if(!P_IsPaused())
Expand Down
2 changes: 1 addition & 1 deletion doomsday/plugins/jheretic/src/st_stuff.c
Expand Up @@ -519,7 +519,7 @@ void ST_Ticker(void)
player_t* plr = &players[i];
hudstate_t* hud = &hudStates[i];

if(!(plr->plr->inGame && (plr->plr->flags & DDPF_LOCAL)))
if(!plr->plr->inGame) // && (plr->plr->flags & DDPF_LOCAL)))
continue;

ST_updateWidgets(i);
Expand Down
2 changes: 1 addition & 1 deletion doomsday/plugins/jhexen/src/st_stuff.c
Expand Up @@ -1141,7 +1141,7 @@ void ST_Ticker(void)
player_t* plr = &players[i];
hudstate_t* hud = &hudStates[i];

if(!(plr->plr->inGame && (plr->plr->flags & DDPF_LOCAL)))
if(!plr->plr->inGame) //&& (plr->plr->flags & DDPF_LOCAL)))
continue;

ST_updateWidgets(i);
Expand Down

0 comments on commit 27484a2

Please sign in to comment.