 Complete the following phrase:  During the War of the Spanish Succession, the castle was again besieged by Bavarian troops under Elector Maximilian II Emanuel in 1703, nevertheless the Austrian domains were confirmed by the Treaty of Ilbersheim the next year. After the War of the Third Coalition, Kufstein once again was awarded to the newly established Kingdom of Bavaria in the 1805 Peace of Pressburg and the 