sailed out of gib in early may and on the 22nd we were in the gulf of lyons when , at two in the morning , we were hit by a sudden tempest and the vanguard took the brunt of the damage losing her topmasts and foremast while we fought like men possessed to keep her afloat .