The castle was converted many times during the Renaissance & Baroque periods. In the 18th century, it acquired its final Baroque-Classicist style, in which it was rebuilt from World War II destruction. The castle was the royal residence and also the seat of the lower and upper houses of parliament. It was here that the Four-Year Sejm passed the Constitution of May 3rd, 1791. Burned down during World War II, it was rebuilt in 1974.