- Added Thomas's submissions for decal assignment to puffs and NOINFIGHTING flag.

SVN r847 (trunk)
This commit is contained in:
Christoph Oelckers 2008-03-24 22:06:26 +00:00
commit 1e81eb0fee
3 changed files with 22 additions and 4 deletions

View file

@ -2877,8 +2877,24 @@ AActor *P_LineAttack (AActor *t1, angle_t angle, fixed_t distance,
// [RH] Spawn a decal
if (trace.HitType == TRACE_HitWall && trace.Line->special != Line_Horizon)
{
SpawnShootDecal (t1, trace);
{
// [TN] If the actor or weapon has a decal defined, use that one.
if(t1->DecalGenerator != NULL ||
(t1->player != NULL && t1->player->ReadyWeapon != NULL && t1->player->ReadyWeapon->DecalGenerator != NULL))
{
SpawnShootDecal (t1, trace);
}
// Else, look if the bulletpuff has a decal defined.
else if(puff != NULL && puff->DecalGenerator)
{
SpawnShootDecal (puff, trace);
}
else
{
SpawnShootDecal (t1, trace);
}
}
else if (puff != NULL &&
trace.CrossedWater == NULL &&