Create a region arround the turret.When an enemy enters the region, add that enemy to a list, and when you want to shoot just pick one enemy from that list. Remember to remove the enemy from the list when it gets killed or leaves the region.