I'm currently trying to create a trajectory effect (in UE 4.25.1) similar to one from the last of us:
I have created a beam with niagara, which lets me determine the starting point of the beam, endpoint and the tangents for both of them:
I am happy with the look of it, but I don't understand the math behind the tangent values. My goal is to make the line overlap the actual trajectory of the projectile (arrow), which is calculated in a BluePrint.
Most examples I found online either just use the Debug-Line from the
Predict Projectile Path by Trace Channel, which looks rather bad or they spawn some kind of mesh every x interval on the trajectory line, which is not the kind of indicator I want to create.
Right now, the arrow is being shot from a starting point (bow) with a given velocity and a direction (camera angle). Unreal then calculates the drop of the arrow according to gravity and velocity.
So, the starting position of the beam would be the same as the starting position of the arrow and the angle/rotation would be equal, as well. I can also determine the endpoint for the beam (endposition of the arrow).
However I don't understand how I could calculate the required tangents for the beam to represent the trajectory of the arrow (dropping)? I am new to UE and math is not my strongest point to say the least. Is this even possible with the way I set things up?