- applied Xaser's A_RailAttack duration fix.

SVN r3557 (trunk)
This commit is contained in:
Christoph Oelckers 2012-04-13 08:15:57 +00:00
parent 1529c91b80
commit 37f4ee53b9
2 changed files with 6 additions and 4 deletions

View file

@ -685,9 +685,11 @@ void P_DrawRailTrail (AActor *source, const FVector3 &start, const FVector3 &end
if (!p)
return;
int spiralduration = (duration == 0) ? 35 : duration;
p->trans = 255;
p->ttl = duration;
p->fade = FADEFROMTTL(duration);
p->fade = FADEFROMTTL(spiralduration);
p->size = 3;
p->bright = fullbright;
@ -734,7 +736,9 @@ void P_DrawRailTrail (AActor *source, const FVector3 &start, const FVector3 &end
pos = start;
for (i = trail_steps; i; i--)
{
particle_t *p = JitterParticle (33);
// [XA] inner trail uses a different default duration (33).
int innerduration = (duration == 0) ? 33 : duration;
particle_t *p = JitterParticle (innerduration, drift);
if (!p)
return;

View file

@ -1401,7 +1401,6 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_RailAttack)
ACTION_PARAM_CLASS(SpawnClass, 14);
if(Range==0) Range=8192*FRACUNIT;
if(Duration==0) Duration=35;
if(Sparsity==0) Sparsity=1.0;
if (!self->player) return;
@ -1464,7 +1463,6 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_CustomRailgun)
ACTION_PARAM_CLASS(SpawnClass, 14);
if(Range==0) Range=8192*FRACUNIT;
if(Duration==0) Duration=35;
if(Sparsity==0) Sparsity=1.0;
AActor *linetarget;