During the 11th century, the first Turks appeared around Anatolia, which was populated by Greeks, Armenians, Persians, Arabs, Kurds, and more. The Seljuk Empire was founded in 1037 in Central Asia, but by 1060, it had reached all the way to Anatolia. In 1045, the Bagratuni kingdom fell thanks to the Byzantine Empire; the gates of Ani were opened to the Byzantines by Armenian noblemen.
Two years later, in 1047, the Seljuk Turks invaded and captured it. They looted and massacred the locals and reached the city of Karin. However, they were unable to capture Kars. In 1071, the Battle of Manazikert took place; the Seljuk Turks fought against the Byzantines. It was a decisive battle, and the Byzantines lost, which allowed the inflow of Seljuk Turks from Central Asia.
When the Turks arrived, the Armenians and Greeks (who mainly fought with swords) were faced with armies of skilled archers, which ultimately lead to their defeat and the advancement of the Turks into Anatolia.