Five months later, with the Austro-Hungarian Empire facing collapse and defeat in the war, the Empire decided to transfer most of its navy to the newly declared State of Slovenes, Croats and Serbs on 31 October, effectively bringing the k.u.k. Kriegsmarine to an end. Three days later, the Empire's military authorities signed the Armistice of Villa Giusti, pulling the rapidly disintegrating empire out of the war. With the signing of the Treaty of Saint-Germain-en-Laye and the Treaty of Trianon, the First Austrian Republic and the Kingdom of Hungary were treated as the successors to the Austro-Hungarian Empire, whereas the independence of the West Slavs and South Slavs of the Empire as the First Czechoslovak Republic, the Second Polish Republic and the Kingdom of Yugoslavia, respectively, and most of the territorial demands of the Kingdom of Romania, were also recognized by the victorious Allies in 1920. As a result, both Austria and Hungary were deprived of their coasts, and the former Empire's most important ports such as Trieste, Pola, Fiume and Ragusa, were annexed into Italy and Yugoslavia. The k.u.k. Kriegsmarine's main ships meanwhile were turned over to the Allies where most of them were scrapped throughout the 1920s, though some of its ships remained in use through the 1930s and beyond, such as the "Bodrog", which remained in the service of multiple countries until the 1960s and is presently being converted into a museum ship.