Fixed a bug with the previous fix, should accurately account for changed
coordinate systems now.