Inkjet printers do not like being left sitting unused for extended periods. This is not a problem that is specific to this model, or even to HP inkjets. It is a feature of pretty much *all* inkjets. The ink eventually dries out in the print head, and clogs the nozzles.
Since this is an HP, replacing the ink cartridges will probably help. Unlike other vendors, HP integrates the nozzles into the cartridges, so you are effectively replacing the print head when you replace the cartridges. But if you leave it sit unused for 5 months after installing the new cartridges, chances are it will be messed up again.
Nostalgia isn't what it used to be.