- fixed: Floor and ceiling hugger projectiles should not be spawned with ONFLOORZ or ONCEILINGZ

because that will make them ignore the actual floor height if it differs from the sector's floor.
- fixed: Floor and ceiling huggers spawned by a player did not get their vertical velocity set to 0.

git-svn-id: http://mancubus.net/svn/hosted/gzdoom/trunk@446 b0f79afe-0144-0410-b225-9a4edf0717df
This commit is contained in:
Christoph Oelckers 2009-09-06 21:20:07 +00:00
parent 44fcd47cdf
commit eecc5f0cfc

View file

@ -5102,14 +5102,6 @@ AActor *P_SpawnPlayerMissile (AActor *source, fixed_t x, fixed_t y, fixed_t z,
i = GetDefaultByType (type)->flags3;
if (i & MF3_FLOORHUGGER)
{
z = ONFLOORZ;
}
else if (i & MF3_CEILINGHUGGER)
{
z = ONCEILINGZ;
}
if (z != ONFLOORZ && z != ONCEILINGZ)
{
// Doom spawns missiles 4 units lower than hitscan attacks for players.
@ -5143,7 +5135,13 @@ AActor *P_SpawnPlayerMissile (AActor *source, fixed_t x, fixed_t y, fixed_t z,
MissileActor->velx = FixedMul (vx, speed);
MissileActor->vely = FixedMul (vy, speed);
MissileActor->velz = FixedMul (vz, speed);
if (th->flags3 & (MF3_FLOORHUGGER|MF3_CEILINGHUGGER))
{
MissileActor->velz = 0;
}
else
{
MissileActor->velz = FixedMul (vz, speed);
if (MissileActor->flags4 & MF4_SPECTRAL)
MissileActor->health = -1;