ending in 1479, multiple times defeating the mightiest power of the time led by Sultans Murad II and Mehmed II. Skanderbeg managed to gather several of the Albanian principals, amongst them the Arianitis, Dukagjinis, Zaharias and Thopias, and establish a centralised authority over most of the non-conquered territories and proclaiming himself the Lord of Albania (Dominus Albaniae in Latin). Skanderbeg consistently pursued the aim relentlessly but rather unsuccessfully to create a European coalition against the Ottomans. His unequal fight against them won the esteem of Europe and financial and military aid from the Papacy and Naples, Venice and Ragusa.Barletius, Marinus. De obsidione Scodrensi. Venice: Bernardino de Vitabilus, 1504. The Albanians, then predominantly Christian, were initially considered as an inferior class of people and as such were subjected to heavy taxes such as the Devshirme system that allowed the state to collect a requisite percentage of Christian adolescents from the Balkans and elsewhere to compose the Janissary. Since the Albanians were seen as strategically important, they made up a significant proportion of the Ottoman military and bureaucracy. They were therefore to be found within the imperial services as vital military and administrative retainers from Egypt to Algeria and the rest of the Maghreb. In the late 18th century, Ali Pasha Tepelena created the autonomous region of the Pashalik of Yanina within the Ottoman Empire which was never recognised as such by the High Porte. The territory he properly governed incorporated most of southern Albania, Epirus, Thessaly and southwestern Macedonia. During his rule, the town of Janina blossomed into a cultural, political and economic hub for both Albanians and Greeks. The ultimate goal of Ali Pasha Tepelena seems to have been the establishment of an independent rule in Albania and Epirus. Thus, he obtained control of Arta and took control over the ports of Butrint, Preveza and Vonitsa. He also gained control of the pashaliks of Elbasan, Delvina, Berat and Vlorë. His relations with the High Porte were always tense though he developed and maintained relations with the British, French and Russians and formed alliances with them at various times. In the 19th century, the Albanian wālī Muhammad Ali established a dynasty that ruled over Egypt and Sudan until the middle of the 20th century. After a brief French invasion led by Napoleon Bonaparte and the Ottomans and Mameluks competing for power there, he managed collectively with his Albanian troops to become