So I am working on a game that is similar to Pokemon Go but I am having an issue with the map. First off, the map is based on the Google Maps api, and I am spawning items on the map at random locations. I am implementing a menu option to show inventory and such but when I return from the menu, the map regenerates all objects on the map like its recreating the activity.
My main question is how would I make it so that the map and all the data on it is saved when returning from the menu? Should I make the menu a fragment? Because currently it is an activity.