A Corrections officer repeatedly kicked a prisoner in the head while another broke his leg and dislocated his ankle while he was already restrained, the Crown says.
A third officer is accused of trying to protect his colleagues by turning a camera away from the incident inside the country's maximum security prison, Auckland Prison (Paremoremo) in May last year.
Corrections officer Desmond Fa'afoi had just been attacked by two prisoners armed with makeshift weapons, known as shanks, in May last year. He had cuts and stab wounds to his head and neck.
In her closing address, Crown prosecutor Jo Murdoch said Mr Fa'afoi lashed out against prisoner Mitai Angell as he lay on the ground surrounded by officers.
"Pumped up with anger and adrenalin, he lost control.
"He punched and kicked an inmate repeatedly, to the extent that he had to be restrained by his fellow Corrections officers. He then collapsed, due to exertion and physical injury, on the stairs."
Mr Fa'afoi's colleague, Viju Devassy, faces a charge of attempting to pervert the course of justice.
"The Crown says Mr Devassy had turned the camera away from the incident in order to prevent or obstruct the prosecution of Corrections officers which he must have contemplated would follow, as an acting senior Corrections officer, given what he had just witnessed Fa'afoi do to Angell."
A short time later the camera was moved back to the incident where Angell lay on his front with his legs stretched out.
Corrections officer Wiremu Paikea approached Angell's legs, bent down and applied a leg lock using the full weight of his body.
"The Crown says that Mr Paikea did not need to apply the figure four leg lock at this point, yet he does, and he does it so badly that he dislocates Angell's left ankle and fractures his right calf bone."
Ms Murdoch said Mr Paikea had been trained in how to control and restrain prisoners and had done several refresher courses since. He must have known there was a serious risk of harm.
The prosecutor also addressed what Mr Devassy and other officers later told the police - that they could not remember Mr Fa'afoi's kicks to Angell.
"The Crown says this is an extraordinary coincidence, given it was happening right in front of all of them.
"The Crown says that they are covering up for their close colleague and friend, Mr Fa'afoi, who was injured. That they knew how unacceptable his conduct was, even in the circumstances that Mr Fa'afoi found himself."
Ms Murdoch said Mr Fa'afoi was claiming to have suffered memory loss but there was no record of that on his hospital discharge papers.
"Corrections officers working in New Zealand's only maximum security prison, or any prison in New Zealand for that matter, must be held accountable for unacceptable conduct, contrary not only to the law but to their core training and responsibilities."
Mr Fa'afoi's lawyer Todd Simmons said his client and a colleague were suddenly attacked by the prisoners from behind.
"Those inmates were not just out to rough-up [Corrections officer] Fa'afoi that afternoon. We haven't seen the footage of the attack on him but you may well think those inmates were out to kill him."
He said several of Mr Fa'afoi's colleagues described him looking dazed with blood on his head and face. He passed out on the stairs and one senior officer described him as looking dead.
Mr Simmons said the atmosphere must have been mayhem. A short time later, Mr Fa'afoi kicked Angell in the head, as the prisoner lay on the ground but he has no memory of the event.
"There was no intent by him when those kicks were delivered to injure inmate Angell because he had no idea what he was doing at the time."
Mr Simmons said his client had stuck to the same story that he told the police straight after the incident and again in court.
Today, the jurors will hear lawyers for Mr Devassy and Mr Paikea close their case before Justice Gordon sums up the case and they retire to consider their verdicts.