During the American Revolutionary War Spain sided with the French and United States against the British and St. Maxent was placed in charge of the militia (but not Spanish regulars), which saw action in the Gulf Coast campaign, including the Capture of Fort Bute, the Battle of Baton Rouge (which resulted in the capture of both Fort New Richmond and Fort Panmure (future Natchez, Mississippi), the Battle of Fort Charlotte (1780), and ultimately the Siege of Pensacola (1781).