War returned to the Ludwigshafen area with the armies of the French Revolution. The palace at Oggersheim was burned down, Mannheim besieged several times, and all the area west of the Rhine annexed by France from 1798 to 1813. The Electorate of the Palatinate was split up. The eastern bank of the Rhine with Mannheim and Heidelberg was given to Baden, while the western bank (including the Ludwigshafen area) was granted to the Kingdom of Bavaria, following the Wars of Liberation (1813-1815), in which the French were expelled. The Rhine had become a frontier and the Rheinschanze, cut off politically from Mannheim, lost its function as the neighbouring city's military bulwark.