Now the distance assigning works!

Those pesky indices gotta go in the right order...
Added an aspect ratio cut to the object matching thing.
Wrote some of the Dame table and a function to convert it into my format.