* Updated to ZDoom r3515:

- Check for overflows when giving inventory items.
- Fixed: A_Respawn also needs to use P_SpawnMapThing-like sector finding. Since it is exactly the same situation A_RestoreSpecialPosition, it now just calls that to do the moving. This also means it is no longer limited to respawning things on the floor.
- Make DF2_BARRELS_RESPAWN work in all game modes without the need for alwaysapplydmflags.
- Implement multitick viewpitch centering logic.
- Fixed: DEM_CENTERVIEW also needs to reset the LocalViewPitch if it's for the consoleplayer.
- Fixed: Monster respawning did not redo floorz/ceilingz for 3D floors after positioning the item.
- Fixed: Monster respawning used the newly spawned monster's SpawnPoint to determine what to shift the Z position by. This is, naturally, always 0.
- Fixed: Item respawning did not redo floorz/ceilingz for 3D floors after positioning the item.

git-svn-id: http://mancubus.net/svn/hosted/gzdoom/trunk@1340 b0f79afe-0144-0410-b225-9a4edf0717df
This commit is contained in:
gez 2012-04-03 12:57:18 +00:00
parent 8c0fa6d15a
commit e3a40a26fc
8 changed files with 57 additions and 26 deletions

View file

@ -2241,9 +2241,9 @@ void P_PlayerThink (player_t *player)
{
if (look == -32768 << 16)
{ // center view
player->mo->pitch = 0;
player->centering = true;
}
else
else if (!player->centering)
{
fixed_t oldpitch = player->mo->pitch;
player->mo->pitch -= look;
@ -2266,6 +2266,22 @@ void P_PlayerThink (player_t *player)
}
}
}
if (player->centering)
{
if (abs(player->mo->pitch) > 2*ANGLE_1)
{
player->mo->pitch = FixedMul(player->mo->pitch, FRACUNIT*2/3);
}
else
{
player->mo->pitch = 0;
player->centering = false;
if (player - players == consoleplayer)
{
LocalViewPitch = 0;
}
}
}
// [RH] Check for fast turn around
if (cmd->ucmd.buttons & BT_TURN180 && !(player->oldbuttons & BT_TURN180))