From 54822c29eb86e91670e6369eceb34eb6029a536e Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Sat, 24 Dec 2016 18:24:44 +0100 Subject: [PATCH] - changed pitch math in P_RailAttack to avoid having to deal with bogus math throughout the entire function. Effectively the only thing this changes is passing the correct pitch to P_DrawRailTrail. --- src/p_map.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/p_map.cpp b/src/p_map.cpp index f889069f18..81934ceb76 100644 --- a/src/p_map.cpp +++ b/src/p_map.cpp @@ -4920,10 +4920,10 @@ void P_RailAttack(FRailParams *p) } AActor *source = p->source; - DAngle pitch = -source->Angles.Pitch + p->pitchoffset; + DAngle pitch = source->Angles.Pitch + p->pitchoffset; DAngle angle = source->Angles.Yaw + p->angleoffset; - DVector3 vec(DRotator(pitch, angle, angle)); + DVector3 vec(DRotator(-pitch, angle, angle)); double shootz = source->Center() - source->FloatSpeed + p->offset_z; if (!(p->flags & RAF_CENTERZ))