- Fixed: EV_Teleport() did not set players to their idle state, so if they

were running when the teleported, they would still be running afterward
  even though they weren't moving anywhere. Normally, P_XYMovement() does
  this when they stop due to friction.
- Fixed: AActor::TakeSpecialDamage() completely bypassed the standard rules
  for target switching on actors with MF5_NODAMAGE set.
- Changed the return values of the ACS spawn, spawnspot, and spawnspotfacing
  commands to be the total count of things spawned, rather than a pretty
  much useless reference to the actor spawned at the last map spot.
- Fixed: DLevelScript::DoSpawn() takes a byte angle, but DoSpawnSpotFacing()
  passed it a full-length angle.
- Fixed: When MF_SKULLFLY is removed because an actor slams into something,
  it was set to a see or spawn state, resetting its tic count and bypassing
  the effectiveness of the MF2_DORMANT flag. While I was at it, I decided
  dormant skulls shouldn't do slamming damage, either.
- Fixed: P_Thing_Spawn() returned success only if all thing instances were
  successfully spawned. As long as at least one thing was spawned, it should
  be considered a success.
- Fixed: Flipped single rotation sprites were only flipped every other 22.5
  degree interval.


SVN r484 (trunk)
This commit is contained in:
Randy Heit 2007-02-14 22:47:01 +00:00
commit 01cd91fd9e
6 changed files with 58 additions and 19 deletions

View file

@ -1402,8 +1402,15 @@ void P_XYMovement (AActor *mo, fixed_t scrollx, fixed_t scrolly)
// the skull slammed into something
mo->flags &= ~MF_SKULLFLY;
mo->momx = mo->momy = mo->momz = 0;
mo->SetState (mo->SeeState != NULL ? mo->SeeState : mo->SpawnState);
if (!(mo->flags2 & MF2_DORMANT))
{
mo->SetState (mo->SeeState != NULL ? mo->SeeState : mo->SpawnState);
}
else
{
mo->SetState (mo->SpawnState);
mo->tics = -1;
}
}
return;
}
@ -2347,12 +2354,20 @@ void AActor::HitFloor ()
bool AActor::Slam (AActor *thing)
{
int dam = GetMissileDamage (7, 1);
P_DamageMobj (thing, this, this, dam, NAME_Melee);
P_TraceBleed (dam, thing, this);
flags &= ~MF_SKULLFLY;
momx = momy = momz = 0;
SetState (SeeState != NULL ? SeeState : SpawnState);
if (!(flags2 & MF2_DORMANT))
{
int dam = GetMissileDamage (7, 1);
P_DamageMobj (thing, this, this, dam, NAME_Melee);
P_TraceBleed (dam, thing, this);
SetState (SeeState != NULL ? SeeState : SpawnState);
}
else
{
SetState (SpawnState);
tics = -1;
}
return false; // stop moving
}
@ -4736,13 +4751,7 @@ int AActor::TakeSpecialDamage (AActor *inflictor, AActor *source, int damage, FN
if (flags5 & MF5_NODAMAGE)
{
target = source;
if (pr_takedamage() < PainChance)
{
FState * painstate = FindState(NAME_Pain, damagetype);
if (painstate != NULL) SetState (painstate);
}
return -1;
return 0;
}
// If the actor does not have a corresponding death state, then it does not take damage.