A prisoner from Irvine attacked a fellow inmate with a crutch amid bullying claims.
Derrick Gallagher, also known as Derrick Allmark, 34, pounced on Gary McGuinness at HMP Low Moss on August 4 2019.
Gallagher smacked McGuinness with his walking aid before punching and kicking him.
Gallagher recently pleaded guilty at Glasgow Sheriff Court to assaulting McGuiness to his injury.
The court heard that McGuinness was pushed out of a cell by Gallagher and dropped his metal crutch.
Prosecutor Lauren Sangray said: "Gallagher retrieved the metal crutch from the ground and struck McGuinness several times to the body with it.
"He thereafter began to punch and kick McGuinness to the head and body."
McGuinness was taken to hospital as he had suffered a wound to his head and hip.
Gallagher's lawyer told the court: "This was four years ago - his life is different now.
"This related to McGuinness' behaviour towards others in prison with Mr Gallagher's position of it being bullying."
Sentence was deferred pending background reports until next month by Sheriff Gerard Bonnar.
Gallagher was granted bail meantime.
Comments: Our rules
We want our comments to be a lively and valuable part of our community - a place where readers can debate and engage with the most important local issues. The ability to comment on our stories is a privilege, not a right, however, and that privilege may be withdrawn if it is abused or misused.
Please report any comments that break our rules.
Read the rules here