Skip to content

Commit

Permalink
Fixed: If the automap is open when a map change occurs, the map would…
Browse files Browse the repository at this point in the history
… be visible momentarily when the new map begins.
  • Loading branch information
danij committed Mar 12, 2009
1 parent 522eff9 commit 533495d
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions doomsday/plugins/common/src/p_automap.c
Expand Up @@ -147,12 +147,17 @@ void Automap_Open(automap_t* map, int yes, int fast)
if(yes == map->active)
return; // No change.

map->oldAlpha = map->alpha;
map->targetAlpha = (yes? 1.f : 0.f);
if(fast)
map->alpha = map->targetAlpha;
// Reset the timer.
map->alphaTimer = 0.f;
{
map->alpha = map->oldAlpha = map->targetAlpha;
}
else
{
// Reset the timer.
map->oldAlpha = map->alpha;
map->alphaTimer = 0.f;
}

map->active = (yes? true : false);
}
Expand Down

0 comments on commit 533495d

Please sign in to comment.