"Life struck Mr Tukiri one of the harshest blows it could in May of last year when his partner of three years, Casey Nathan, died as a result of complications to do with giving birth to their son Kymani," Gurnick said.
"Mr Tukiri was then faced with the prospect, two days later, of having to decide at the young age that he is to discontinue life support for his 2-day-old son. His son then passed away in Mr Tukiri's arms."
Two weeks later Tukiri, 19, was caught drink-driving and a month after that he and another man robbed a superette in Huntly of $200.
In a second robbery weeks later, when Tukiri was on bail and due to appear in court on the first robbery charge, he went back to the same superette undisguised and took two chocolate bars.
"It would have been like a freight train hitting Mr Tukiri in May of last year, only he survived it," Gurnick said. The lawyer said the tragedy, together with other factors - including a learning disability, his parents separating when he was 4, heavy use of alcohol and drugs since the age of 13, and two earlier stints in a mental health facility - caused a young man to "effectively go off the rails in a monumental way".
However, Crown prosecutor Sheila Cameron said the impact on Tukiri's victims could not be ignored.
"In particular in this case, the harm was repeated and no doubt intensified by the fact that the same victims were subject to repeated robbery committed by Mr Tukiri and an associate."
She conceded Tukiri's history may have played a part in his offending.
"There is a psychiatric report that confirms that while Mr Tukiri is not suffering from mental illness, he is suffering from considerable unresolved grief issues."
Judge Ruth acknowledged the family support for Tukiri in the courtroom and a letter of support from Action to Improve Maternity founder Jenn Hooper, which played a crucial role in alerting the court to the distress Tukiri was suffering.
Hooper, who was in court to support Tukiri's mother and grandmother, and Nathan's mother and sister, said the family were relieved at the sentence.
"We're very grateful that the judge has shown compassion in this way," Hooper said.
"Hayden went through an incredibly traumatic time with the tragic death of his much-loved partner and baby. He then made some bad decisions and has since shown a great deal of regret for those actions."
Meanwhile, a date has not yet been set for the coronial inquiry into the deaths of 20-year-old Nathan and baby Kymani.