update map and location functions