Gary Gunion terrorised his former partner by repeatedly making phone calls and sending text messages on May 9 last year.
He demanded entry to her address which he attended uninvited, striking the door and causing windows to smash by throwing bricks at the windows.
The 37-year-old, from the town, appeared at Kilmarnock Sheriff Court from custody on January 3 for sentencing on five charges – three of which involved breaching bail conditions – spanning four months last year.
His second offence took place two days later, with Gunion found hiding in a wardrobe in the woman’s bedroom by police officers despite being told not to approach or contact her.
Procurator fiscal depute Decla O’Connor told the court that at 10pm on July 22, electronic monitoring company G4S was alerted that Gunion had left his address in Abbeygreen during the hours of his curfew.
Police were notified and attended two hours later, but he was found back home when they arrived.
He claimed he left during his curfew as his friend was unwell and was checking on his welfare, but when asked for further details by the officers he was unable to answer and was not coherent.
And at 4pm on October 2 Gunion’s ex asked him to leave her home address as he was drunk, which he refused to do.
She contacted family members to come round and he left when they arrived. She became worried he would return so she stayed overnight with her parents.
An hour later Gunion was spotted by neighbours trying her door handle and kicking her door.
He then tried to remove wood from a boarded-up window and climb up the drain pipe.
When she returned on October 3, she noticed that her internet box had been ripped off the wall, the letterbox had been broken on the front door, and both doors had damage to the PVC panels.
He was later arrested by police and he responded whilst under caution: “I was only chapping the door.”
Gunion pleaded guilty to refusing to leave his former partner’s home when requested and thereafter attended the property while uninvited.
He also repeatedly kicked the front and back doors of the house whilst unoccupied causing the damage.
He also admitted to breaking his bail conditions twice, having been ordered to remain in his Abbeygreen home between 7pm and 6am, on July 22 and the following day.
His defence lawyer said: “I spoke with him and I think there are problems with alcohol. To his credit he has completed nearly 130 hours of his unpaid work which is positive.
“He obviously regrets he is back in custody.”
It was also told in the hearing that Gunion was currently serving a sentence and was due to be released later this month.
Sheriff Morag Fraser revoked a previous community payback order and jailed Gunion for 104 days.