 At the Restoration the Privy Council established a force of an unknown number of infantry regiments and a few troops of horse. The Commonwealth fortresses were abandoned, but garrisons were placed in Edinburgh, Stirling, Dumbarton and Blackness castles. There were attempts to found a national militia on the English model. The standing army was mainly employed in the suppression of Covenanter rebellions and the guerilla war undertaken by the Cameronians in the East. Units included a regiment of foot guards, later known as the Scots Guards and Le Regiment of Douglas, formed and serving in France since 1633, it returned, eventually became the Royal Regiment of Foot. Pikemen became less important in the late seventeenth century and after the introduction of the socket bayonet, a process complete by 1702, disappeared altogether, while matchlock muskets were replaced by the more reliable flintlock. Three troops of Scots Dragoons were raised in 1678 and another three were added to make The Royal Regiment of Scots Dragoons in 1681. On the eve of the Glorious Revolution the standing army in Scotland was about 3,000 men in various regiments and another 268 veterans in the major garrison towns, at an annual cost of about £ 80,000. After the Glorious Revolution the Scots were drawn into King William II's continental wars, beginning with the Nine Years' War in Flanders (1689 – 97).
