You can find your answer in the chapter "The Egypt Girls." In this chapter, we learn that a book started the girls thinking about Egypt.
It was in the library in August that the seeds were planted that grew into the Egypt Game in September in the Professor’s deserted yard.
So, the girls started thinking about Egypt after April found a book about the life of an Egyptian Pharaoh and shared it with Melanie. This first book about Egypt piqued the interest of the girls. With the help of the librarian, the girls soon read everything in the library about Egypt. The girls didn't just read about Egypt in the library, however. They also took some of the books home: both girls read them in the evenings and in bed, when they were supposed to be sleeping. In the mornings, the two would discuss everything they had read the night before. They talked about tombs, pharaohs, mummies, and pyramids whenever they could.
Soon, the girls created their own set of hieroglyphics for writing secret messages to each other. In September, the Egypt Game was born after the girls (and Marshall, Melanie's brother) discovered the intriguing yard behind the Professor's antique shop.
So, the girls started thinking about Egypt after reading that first book about the life of a pharaoh.