 In 1780, on the invasion of the state by the British, he served in a cavalry regiment during the final siege of Charleston, and, being included in the capitulation of that place, was paroled on condition that he would not serve against the British while they held possession of the city.When in 1781 the fortunes of the British began to decline, he, with all the others who were paroled on the same terms, was required to join the royal army or be subjected to close confinement.Hayne would gladly have accepted imprisonment, but his wife and several of his children lay at the point of death from smallpox.