When Robert Xie allegedly murdered his five family members, their injuries showed a crime motivated by “intense bitterness and hatred”, the crown says.

Robert Xie was driven by “intense bitterness and hatred” when he crept into his brother-in-law’s home and used one weapon to batter five family members to death, a NSW court has heard.

Lian Bin “Robert” Xie, 50, is accused of murdering his brother-in-law Min “Norman” Lin, 45, Mr Lin’s wife, Yun “Lily” Li Lin, 44, and their sons Henry, 12, and Terry, 9, in the early hours of July 18, 2009 in their home in Sydney’s northwest.

He is also alleged to have killed Lily’s sister, Yun Bin “Irene” Lin, 39.

Xie, who has pleaded not guilty, is facing a retrial after his trial earlier this year was cut short.

Opening the crown case in the Supreme Court on Tuesday, prosecutor Mark Tedeschi QC said Xie went into Min and Lily’s bedroom first that night and murdered them in their beds, before going into Irene’s room and killing her.

The assault on the trio occurred either while they were asleep or just waking up, with all three suffering “very substantial deformation of their faces”, Mr Tedeschi told the jury.

Having killed those who represented the largest “threat”, the crown says Xie then went into the bedroom shared by Henry and Terry.

But here, the boys stirred. “The boys were not in their beds … from the way the room was found there had been a furious struggle,” Mr Tedeschi said.

Both showed signs of defensive wounds, with Terry having moved during the attack.

Henry survived for at least half an hour after the attack, while Terry appeared to have been alive for up to two hours, Mr Tedeschi said.

Mr Tedeschi said the evidence would establish there was “one primary weapon used to subdue and cause the most horrendous injuries to the five victims”.

This weapon, he alleged, was “hammer-like” and involved a rope being tied around the wrist of the assailant.

There was no sign of theft or sexual assault, he said.

The degree of damage done to the faces of the three adults showed this was a crime “motivated by intense bitterness and hatred”, Mr Tedeschi said.

After slaying the family, the crown alleged Xie walked back to his home just 300 metres away.

While getting cleaned up, Xie placed something on his garage floor and unknown to him left a small area of blood smear that had a mixture of three, four or five of the victims, Mr Tedeschi told the jury.

Although Xie cleaned his garage floor the following morning, this spot remained, he said.

The trial before Justice Peter Johnson continues.