By early August 1643, a series of Royalist victories combined with the death of the popular John Hampden in June meant the Parliamentarian cause seemed close to collapse. At this crucial point, it was saved by Pym's leadership and determination, which led to a renewed commitment to win the war. He created the foundations of victory by ensuring Parliament had sufficient financial and military resources, one of his last acts being to negotiate the Solemn League and Covenant that secured Scottish support.