Proper match ending points + sorting