During the Age of Discovery, between the 15th and 17th century, sailing that had been mostly coastal became oceanic. Thus, the main focus was on long-haul routes. Countries of the Iberian Peninsula were pioneers in this process, seeking exclusive property and exploration rights over lands discovered and to be discovered. Given the amount of new lands and the resulting influx of wealth, the Kingdom of Portugal and the united kingdoms of Castile and Aragon began to compete openly. To avoid hostilities, they resorted to secrecy and diplomacy, marked by the signing of the Treaty of Alcáçovas in 1479 and the Treaty of Tordesillas in 1494.