Mr Corner is also accused of causing grievous bodily harm to Sgt Kate Evans, who the court previously heard had suffered a fractured spine. He denies this charge.

Giving evidence earlier, he said the group’s only intention was to “break in, cause as much damage to the factory as possible, destroy weapons and prevent the factory from reopening”.

When asked by his barrister Tom Wainwright whether he was willing to injure a person or use violence during the break-in, he replied: “No, not at all”.

Mr Corner told the jury he believed the police were security guards when they arrived on the scene.

He repeatedly described feeling “panicked and out of his depth”.

When asked why he struck Sgt Evans with the sledgehammer, he replied: “It was me not really knowing what I was doing, I was trying to protect Leona, or Zoe. I couldn’t tell who was screaming.”

“My friends were in danger and they [the police] were getting quite hands-on.

“I remember just feeling like I had to help somehow. I would never think to do that to someone, I was just trying to help,” he said.

Sgt Evans previously told the court she was left in “severe pain” and was off work for three months.

The trial continues.