fixed so that alignment percentage ID is used for distance calculation