Added a distance sort

Signed-off-by: Tyler Janca <tejanca@ccwip.net>