The Teutonic Order weakened greatly after the Battle of Grunwald against advancing Poles and Lithuanians. The town was burned by the Teutonic Knights in 1410 before the siege of the castle by Poles, however it remained under Teutonic control after the siege. In 1457, during the Thirteen Years' War, the castle was sold to Poland by Czech mercenaries of the Teutonic Knights, and the Teutonic Order transferred its seat to Königsberg (now Kaliningrad, Russia). The town of Marienburg, under Mayor Bartholomäus Blume and others, resisted the Poles for three further years. But when the Poles finally took control, Blume was hanged and quartered, and fourteen officers and three remaining Teutonic knights were thrown into dungeons, where they met a miserable end. A monument to Blume was erected in 1864.