The case of the 18th-century man of letters John Hawkesworth is not often invoked, perhaps because no one has heard of him. Books of notable Georgians in England go straight from Hawke to Haydon. In Boswell’s Life of Samuel Johnson he hardly appears, despite having been a great friend of Johnson’s in the 1740s, as well as his colleague at the Gentleman’s Magazine. Even his only biographer says that Hawkesworth “did not leave a mark visible across the centuries”. But you will notice I said “the case of” John Hawkesworth, the point being that his literary career closely resembles a cautionary tale. His story is one of ambition and pride; overreaching and disaster. Students of writing are doubtless told that a bad review won’t kill you. They are probably also taught that vindictive, envious trolling is a spanking new phenomenon. The extraordinary case of John Hawkesworth disproves both these little platitudes.

So what did he do? Most notably, he was commissioned by the Admiralty to write up James Cook’s 1769-1771 voyage aboard the Endeavour. The expedition had the scientific goal of observing the transit of Venus from Tahiti, but Cook also carried sealed orders to continue from Tahiti and search for the great southern continent. With astonishing skill, he mapped the entire coast of New Zealand, and then the eastward limit of New Holland (or Australia). On board the ship was the aristocratic botanist Joseph Banks, along with other scientists and artists, many of whom kept their own sea journals. On their return there was considerable public interest in Cook’s discoveries. What was needed was a collation of the journals, and as the nominated author of the proposed work (full title: An Account of the Voyages Undertaken by the Order of His Present Majesty for Making Discoveries in the Southern Hemisphere), Hawkesworth was fully aware he had hit pay dirt. He promptly sold the rights for £6,000 – an absolutely vast amount of money.

Hawkesworth’s rise in the world is fascinating. Starting out with no classical education, his great talent seems to have been in befriending Johnson and emulating him. Contemporaries would declare that they could not tell the two writers apart (oddly, this is always said as a compliment to Hawkesworth rather than the reverse). Not content with imitating Johnson’s style, Hawkesworth also had a bash at nearly every genre attempted by him – usually with more gainful results. He succeeded Johnson at the Gentleman’s Magazine as compiler of parliamentary debates; he wrote a well-received “Eastern Tale”; he wrote dramas for David Garrick. Everything went well for him; he was the man with all the luck. His periodical, The Adventurer (succeeding Johnson’s Rambler), was considered so morally edifying that the Archbishop of Canterbury conferred on him an honorary doctorate.

Detail of a portrait of Samuel Johnson by Joshua Reynolds. Photograph: World History Archive/Alamy

Why was he considered the right man for the Admiralty commission, though? This will always be a mystery. But one can imagine how popular it made him among his fellow hacks, and what a high opinion of his own talents Hawkesworth possessed. True, in the 18th century, a lack of specialist maritime knowledge (or travel experience of any kind) would be seen as no hindrance to writing up a world voyage as if you’d been there yourself. But Hawkesworth had form. Victoria Glendinning, in her 1998 biography of Jonathan Swift, tells us that when Hawkesworth edited Swift’s letters in 1755, he “did not publish them as they stood. He edited them heavily.” Any editor arrogant enough to think that Swift needed help to express himself would look at a bunch of crude sea journals and think “Field day!”.

And so we come to the great work. What Cook himself famously disliked in the finished product – in a conversation recorded by Boswell in 1776 – was Hawkesworth’s moralising; his habit of drawing “a general conclusion from a particular fact”. Boswell agreed: “He has used your narrative as a London tavern keeper does wine. He has brewed it.” In Hawkesworth’s defence, it was hard to find common ground between the journals of Cook and Banks. But this is where his hubris comes in, because his conceited editorial solution was sometimes not to choose between Cook and Banks, but to override both and insert his own stuff – which, after all, had been more than good enough for the Archbishop of Canterbury.

No one knows how proud Hawkesworth felt on publication day. We do know, however, how crushed he was by the reception of the Voyages in 1773. It was a spectacular downfall, and it actually killed him. As Hawkesworth’s Dictionary of National Biography entry tells us, “Fanny Burney’s conviction that his health was destroyed by the vilification he suffered seems well founded. He died at Lime Street, London, of a ‘slow fever’ on 17 November 1773”; “his £6,000 was dearly purchased at the price of his character and peace”.

If the work had been attacked only for inaccuracy, things might have been all right. But the three-volume work was variously condemned as lewd, boring, pompous, bad value (at three guineas), and above all, irreligious. This last accusation was the most serious, and on this count Hawkesworth had no one to blame but himself. He had chosen, in his preface, to challenge Cook on theological grounds for his naming a passage of water (off the coast of modern-day Queensland) “The Providential Channel”. He might as well have cut his own throat.

Hawkesworth’s argument about providence looks unobjectionable today. He basically says you can’t thank God for saving you from peril, because God was responsible for the peril as well. But this was heresy. Anonymous critics joined together in a vicious and universal condemnation that feels very much like trolling. “You are lawful game, and ought to be hunted by every friend of virtue,” writes someone in the Public Advertiser in July 1773, who calls himself “A Believer in the Particular as well as the General Providence of God”. He goes on: “You have verified the maxim that those who are destitute of the fundamental principles of religion and morality will grasp at gold with avidity, though it cannot be seized without injustice.”

In a few months Hawkesworth was not only defamed and diminished, but dead. Johnson had already said of his former friend, “Hawkesworth is grown a coxcomb, and I have done with him”. The literary canon dropped him in much the same fashion, and for the same reason. When he overreached himself, he plummeted not only into ignominy but profound and mystifying obscurity. Did his precious £6,000 have much to do with how rapidly he was inked out of history? I rather think it did.

• The Lunar Cats by Lynne Truss is published by Century. To order a copy for £8.49 (RRP £9.99) go to bookshop.theguardian.com or call 0330 333 6846. Free UK p&p over £10, online orders only. Phone orders min p&p of £1.99.