Made exportMap() more dynamic.
W.I.P Still works.