Edit the map reseting logic to make it look cleaner