When the Teutonic Knights were originally based in Acre in Outremer, the grand masters spent much of their time at the papal and imperial courts. The grand masters were most powerful after the order's 13th century conquest of Prussia during the Northern Crusades and the creation of the militarized State of the Teutonic Order, which lasted until 1525 (from 1466 to 1525 as part of the Kingdom of Poland as a fief). After the order's capital moved from Venice to Malbork (Marienburg) in 1309, the grand master's power was at its height. He had ultimate control over Prussia, which gave him command over the Prussian commanders. When the general chapter would meet in Elbląg (Elbing), he was able to use this influence to ratify administrative measures he proposed. The grand master also served as the castellan of Marienburg and was aided by the order's treasurer. He was also a member of the Hanseatic League, allowing him to receive some of the league's custom dues.