Hello, I will first begin by saying This is not a perfect example, it uses some pretty crude methods to achieve its purpose. I built this last night and today, so that’s some excuse(?). Honestly someone like JR, thebrickcentric, maybe Drafty, maybe Galactian, will probably release a better example for this, but for now, you can have my weak version using a cosine wave (sine wave would probably have been better because a sine starts at the lowest point (could be middle I forgot) compared to a cosine which starts at the peak, forcing me to make some manual adjustment).
How It’s made.
So I made a cosine wave before and I didn’t want to go through the process of learning how to make an actual parabolic prediction method so I wanted to use this.
A cosine wave is a wave that moves up and down in a constant pattern, I remembered that with a cosine wave I was able to adjust many variables like the amplitude, repeat length, time, and speed.
I ripped out the equation to just be amplitude and repeat length because those were the most important variables. With that, I made a predefined arc (it didn’t work great an adjustable one) which was now my “parabolic” curve.
Dots are then evenly set along the curve and boom, you now have a target trail. I then added a projectile and tried to make it properly line up with velocity but decided it was impossible with how I was doing it (the amplitude never changes, but the projectile would need to travel at a steeper angle. Maybe adjusting velocity could fix it). So instead I just search for the nearest dot (Has its own problems when dots are close together), rotate towards it, then move forward via velocity.
And that’s basically it. You now have a “predictable” path for a projectile