A cyclist had to grab a knife blade with both hands to avoid being stabbed by an attacker who pounced on him on a Scots bridge.
Francisco Moreno put up a desperate struggle after being set upon by 27-year-old Robert Dunn in an unprovoked ambush in Edinburgh.
Brave Francisco managed to disarm Dunn who then told a passing runner who came to assist: “I’m mental”.
Dunn later sent an email to police telling them he was suffering from “hallucinations” and believed he may have stabbed someone.
The email went on to say “it might get to the point where I go on a mass spree”.
Deputy prosecutor Jennifer McLaren said Francisco, 40, was on his bike and heading on a cycle path in the direction of Wester Hailes at 9.55am.
Ms McLaren said the victim approached a bridge over the Union Canal, near Murrayburn Road, when he spotted Dunn sitting against a wall.
She said Francisco reached the center of the bridge when Dunn “jumped up and lunged towards him” and he saw the attacker had a knife.
The prosecutor said: “Mr Dunn was holding the knife in both hands and trying to strike towards the middle of Mr Moreno’s stomach.
“But before the blade could strike him, Mr Moreno managed to grab the blade in the middle with both of his hands.”
Ms McLaren said Francisco “felt it was a serrated blade” and it cut his fingers and hands as he held it.
Both men were holding onto the knife, she added, and a struggle ensued for around a minute.
The court was told Dunn was “snapping his teeth as if he was making attempts to bite Mr Moreno on his face” while the victim shouted for help.
Ms McLaren said Francisco asked Dunn if he wanted cash or his bike, but got no response.
She said a woman on a morning run spotted the struggle and saw Dunn let go of the knife and fall back onto grass.
The woman spoke to Dunn and he replied: “I’m mental.”
Shocked Francisco, whose hands were bloody, kept repeating, “I was just biking, I was just biking”, the court was told.
Ms McLaren said the police’s online reporting service received an email at 2.40pm that day from Dunn.
The email said he suffered from mental health issues including “delusions, hallucinations, all that crap”.
It added: “I tried phoning 999 multiple times because I was afraid I actually hurt a real person and not a figment of delusion.”
Dunn wrote he was “cut off twice” and “ignored”.
The email said: “Your service is f***ing awful but it might get to the point where I go on a mass spree and you useless c***s will all be, like, who could have seen it coming?”
Ms McLaren said cops traced Dunn to the city’s Princes Street where he was “rambling” and telling officers: “I stabbed someone on the cycle path today.”
Dunn was found to be carrying a pair of scissors and he admitted a charge of possessing a blade article.
The court was told Francisco suffered minor lacerations to both hands and a 1.5cm cut to his right index finger.
Defense agent Gillian Koren said a psychiatric report on Dunn was available to the court.
Sheriff Alistair Noble deferred sentence on Dunn until next month for reports and remanded him in custody.
Don’t miss the latest news from around Scotland and beyond – Sign up to our daily newsletter here.