New aim mode for A_CustomRailgun that doesn't force pitch

Remember, just because you request it, that doesn't mean you'll get it.

Moderator: GZDoom Developers

User avatar
Jekyll Grim Payne
 
 
Posts: 948
Joined: Mon Jul 21, 2008 4:08 am
Graphics Processor: nVidia (Modern GZDoom)

New aim mode for A_CustomRailgun that doesn't force pitch

Post by Jekyll Grim Payne »

Currently A_CustomRailgun includes a pretty silly oversight where it *always* forces vertical aiming, even if the aim argument is 0:

Code: Select all

self->Angles.Pitch = P_AimLineAttack (self, self->Angles.Yaw, MISSILERANGE, &t, 60., 0, aim ? self->target : NULL);
Moreover, if you do target = null, A_CustomRailgun doesn't produce any rails at all.

That makes it impossible to actually use it as a utility function that simply performs a linear attack. Yes, I know that can be performed manually via LineTrace and such, but A_CustomRailGun can be convenient under some circumstances, and the way the aim currently works makes no sense.

Suggestion: add either aim 3, or a flag (something like RGF_IGNORETARGET or RGF_DONTFORCEAIM) that disables all kinds of aiming completely.

Return to “Feature Suggestions [GZDoom]”