The True Talisman incident, the Fire Crow incident, the cave beneath the Wilderness... even the matter of buying a house in Chonggang Town.
In each event in the Tianyuan Realm, An Jing had connections, however faint, with the ancient immortal ruins beneath Xuanye City.
Whether it was An Jing's choice to 'explore downward' in the cave initially, or his decision to 'hunt Fire Crows' upon learning they were being hunted in the Wilderness, he would come to know about it from other angles and relate it to the ancient immortal ruins.
Not to mention the time when An Jing had to rely on the Black Market to escape the pursuit of the Heaven's Will Demon Sect and the Heavenly Demon, suppose he had missed the cleanup at the Xuanye City Black Market and not got involved in the True Talisman incident, he would most likely have chosen to buy property in Chonggang Town anyway in the Tianyuan Realm.
Because that was where the houses were cheapest.