I assume this is in the right place.
In my project I'm using various different shot types, some of which I want to be able to home in on enemies should they get within a certain range.
I've tried many different ways to make this work and the best I can do only ever seems to check the shot against the most recently created enemy.
I need a way to compare the distance of each and every shot to each and every enemy, so that the shot doesn't just fly past every enemy to hit the last one and I need it to only start homing in if it is within range.
I already have a way to make the shot turn smoothly but right now I'm just trying to make it target the appropriate enemy.