From the late fifteenth century the ideas of Renaissance humanism, critical of aspects of the established Catholic Church, began to reach Scotland, particularly through contacts between Scottish and continental scholars. In the earlier part of the sixteenth century, the teachings of Martin Luther began to influence Scotland. Particularly important was the work of the Lutheran Scot Patrick Hamilton, who was executed in 1528. Unlike his uncle Henry VIII in England, James V avoided major structural and theological changes to the church and used it as a source of income and for appointments for his illegitimate children and favourites. His death in 1542 left the infant Mary, Queen of Scots as his heir, allowing a series of English invasions later known as the Rough Wooing. The English supplied books and distributed Bibles and Protestant literature in the Lowlands when they invaded in 1547. The execution of the Zwingli-influenced George Wishart in 1546, who was burnt at the stake on the orders of Cardinal David Beaton, stimulated the growth of these ideas in reaction. Wishart's supporters, who included a number of Fife lairds, assassinated Beaton soon after and seized St. Andrews Castle, which they held for a year before they were defeated with the help of French forces. The survivors, including chaplain John Knox, were condemned to serve as galley slaves. Their martyrdom stirred resentment of the French and inspired additional martyrs for the Protestant cause. In 1549, the defeat of the English with French support led to the marriage of Mary to Francis II of France, the French dauphin, and a regency over Scotland for the queen's mother, Mary of Guise.