Maximilian I Joseph was the Duke of Zweibrücken from 1769 to 1795. He was also the Prince-elector of Bavaria from 1792 to 1799, and the King of Bavaria from 1799 to 1825.
The Bavaria Chronicles: Testing Your Knowledge of Maximilian I Joseph, King of Bavaria