- Fixed: Using the freeze command would make the Revenant missiles switch

their seekingness. The only sane way to deal with this seemed to be to
  sync the freeze changes with the timer check in A_Tracer(), so that's what
  I did: Freeze mode only changes every four tics now.


SVN r583 (trunk)
This commit is contained in:
Randy Heit 2007-12-06 23:17:38 +00:00
parent 7f52e6537b
commit 0adaaeb5d7
4 changed files with 21 additions and 7 deletions

View file

@ -1,4 +1,8 @@
December 6, 2007
- Fixed: Using the freeze command would make the Revenant missiles switch
their seekingness. The only sane way to deal with this seemed to be to
sync the freeze changes with the timer check in A_Tracer(), so that's what
I did: Freeze mode only changes every four tics now.
- Added IWAD-based [*.Autoload] ini support for games that have more than one
IWAD. They are:
* [Doom1.Autoload]

View file

@ -110,8 +110,9 @@ public:
bool IsDangerous (sector_t *sec);
DArgs *getspawned; //Array of bots (their names) which should be spawned when starting a game.
bool botingame[MAXPLAYERS];
bool freeze; //Game in freeze mode.
bool botingame[MAXPLAYERS];
BYTE freeze:1; //Game in freeze mode.
BYTE changefreeze:1; //Game wants to change freeze mode.
int botnum;
botinfo_t *botinfo;
int spawn_tries;

View file

@ -401,15 +401,14 @@ void cht_DoCheat (player_t *player, int cheat)
break;
case CHT_FREEZE:
if (bglobal.freeze)
bglobal.changefreeze ^= 1;
if (bglobal.freeze ^ bglobal.changefreeze)
{
bglobal.freeze = false;
msg = "Freeze mode off";
msg = "Freeze mode on";
}
else
{
bglobal.freeze = true;
msg = "Freeze mode on";
msg = "Freeze mode off";
}
break;
}

View file

@ -75,6 +75,16 @@ void P_Ticker (void)
if (paused || (playerswiping && !demoplayback) || P_CheckTickerPaused())
return;
// [RH] Frozen mode is only changed every 4 tics, to make it work with A_Tracer().
if ((level.time & 3) == 0)
{
if (bglobal.changefreeze)
{
bglobal.freeze ^= 1;
bglobal.changefreeze = 0;
}
}
// [BC] Do a quick check to see if anyone has the freeze time power. If they do,
// then don't resume the sound, since one of the effects of that power is to shut
// off the music.