z-sorting with point query. Closes #62