sentences:  1369 ended the peace of Schärding the dispute between Austria and Bavaria to the Tyrol, which fell to the Habsburgs who pawned the town back to Bavaria.From 1429 to 1436 the fortifications of the city were built by Duke Ludwig the Gebarteten.Among others, the outer castle gate, the moat, Linz and Passau Gate and the Water Gate were built during this time.