In 1282 Skopje was captured by Serbian king Stefan Milutin. Under the political stability of the Nemanjić rule, settlement has spread outside the walls of the fortress, towards Gazi Baba hill. Churches, monasteries and markets were built and tradesmen from Venice and Dubrovnik opened shops. The town greatly benefited from its location near European, Middle Eastern, and African market. In the 14th century, Skopje became such an important city that king Stefan Dušan made it the capital of the Serbian Empire. In 1346, he was crowned "Emperor of the Serbs and Greeks" in Skopje. After his death the Serbian Empire collapsed into several principalities which were unable to defend themselves against the Turks. Skopje was first inherited by the Lordship of Prilep and finally taken by Vuk Branković in the wake of the Battle of Maritsa (1371) before becoming part of the Ottoman Empire in 1392.