Hi!
I’ve been struggling with this concept for months now and getting around it by using a more simple aiming system which only works half of the time.
In my game the player fires liquid projectiles (in the form of particles), thus naturally they arc unlike a bullet so I need the aiming system to compensate for this.
The below image illustrates what I’m trying to accomplish:
The white Debug Line is a raycast along the gun’s line of sight, and is where the player is aiming.
The 3 arcs show how the weapon would need to angle itself in order to shoot each target that the raycast hits. How would I go about calculating this angle?
Thanks in advance for any help/advice!