The town became the principal burgh of the kingdom during the reign of James III ( 1460 ? ͠ 1488 ) , and in the following years it blossomed .
James III contributed immensely to the prosperity of the town .