Added improved maps code