It is alleged that while Mr Greenslade was out of the room Herkt put some of the cans in his bag.
An argument progressed to a fist fight between the two men and Mr Kayes suggested the victim may have got the upper hand.
Ms Tito and Herkt - bleeding from his face - were locked out of the flat and the victim shouted at them to leave.
But the defendant was only interested in revenge, the Crown said.
Herkt allegedly persuaded a neighbour to give him a cricket bat and a kitchen knife before returning to Mr Greenslade's residence.
"The defendant was angry, armed himself with a potentially fatal weapon, kicked down the back door and launched himself at the deceased. He killed him and he meant to do so," Mr Kayes said.
"He ran straight to Mr Greenslade who was standing in the kitchen. He held the knife in his right hand and lunged at him, stabbing him in the head and neck."
The victim sustained stab wounds to the back of the head, base of the neck and a seven-centimetre cut along the scalp, among others.
But the fatal blow went through the upper left abdomen, cutting the liver and piercing the heart.
Two of Mr Greenslade's friends took him to Takanini accident and emergency but he collapsed and died in the car park out front.
Meanwhile, Herkt and Tito had allegedly made their escape, hiding a knife in a grass area by rail tracks and bloody items of clothing in various other locations.
They spent a night at a friend's house before being stopped in their car by police early the next day.
Mr Kayes told the jury Herkt's first police interview was peppered with lies about men storming the unit and him trying to stop a fight.
But he later allegedly changed his story when police informed him of eye-witness accounts.
"[Mr Grenslade] pretty much pummelled me and I didn't like it so I retaliated with a knife . . . my rage took over," Mr Kayes said he told police.
"He told police he didn't intend to kill Mr Grenslade but the Crown will say his actions suggest the opposite."
Herkt's lawyer Peter Kaye said his client's intent was "the real guts of this case" and he accepted he would have to be found guilty of murder or manslaughter.
He told the jury to focus on what the defendant was thinking at the time of the fatal blow.
"It's his actual state of mind, not what you may think it should have been," he said.
The trial, before Justice Simon Moore and a jury of seven women and five men, is scheduled to last three weeks.