Add methods to convert xy to mapindex and vice versa