A GUNMAN terrified staff and pupils at a Huddersfield primary school by pointing an air rifle towards the school.

And after being allowed home by police, Russell Armitage, of Waterloo, did a similar thing the next day.

Concerned staff at Moldgreen Community Primary were forced to move children from their classrooms and clear a playground after convicted criminal Armitage was seen with an air rifle at the bathroom window of his nearby home.

Following his arrest last May police and counter terrorism officers recovered two air rifles from his former property, which was only about 30 yards from the school grounds.

Armitage had bought the guns using compensation money he received for previously spending too long in prison.

During the police inquiry, officers recovered film clips on the 40-year-olds computer, which showed him using the school building as target practice.

The Honorary Recorder of Bradford, Judge James Stewart QC, was yesterday shown the clips in which Armitage provided commentary on his shooting accuracy.

Prosecutor Joanna Butler-Savage said the footage related to Armitage shooting at a school window, a drainpipe and an alarm box prior to the day of his arrest.

Miss Butler-Savage said the hour-long drama began after a seven-year-old boy at the 366-pupil school told one of the staff that he had seen a man with a gun at one of the nearby houses.

The matter was reported to the deputy head who initially thought that the man was holding some kind of DIY glue-gun.

But when the weapon was pointed in the direction of the school she realised it was a real gun with a thin barrel and a sight fitted to it.

Staff moved all the children from classrooms on the side of the school closest to Armitages home.

Miss Butler-Savage said the lights were also turned out and the blinds on the windows shut.

After the police were alerted the deputy head kept watch on Armitage and described hearing a pop and seeing blue powder and smoke coming from the gun.

There was another shot about five minutes later and the court heard that some reception children had to be brought into the building from the playground.

Miss Butler-Savage said there were several more shots fired in all directions while Armitage was leaning out of his bathroom window.When officers arrested Armitage he admitted he had been shooting at targets on waste ground adjoining the school boundary wall. He also told police: "Im trying to keep out of trouble. I didnt know I was doing anything wrong. Cant you just give me a telling off." He claimed to have been cleaning the weapon.

Miss Butler-Savage added: "He told police he understood why the school had become concerned about his behaviour but it never dawned on him he was doing anything daft."

Bradford Crown Court heard that Armitage was jailed for six years in July 2000 for two offences of wounding with intent and was prohibited from possessing the air rifles a Webley Crosman Ratcatcher and a Gamal Cadet.

Although Armitage should not have possessed the air rifles because of his previous conviction, neither weapon required a firearms certificate.

He was allowed bail following his arrest, but the court heard there was a similar incident the next morning when he was again seen at his bathroom window by school staff.

Miss Butler-Savage said Armitage was described as being red in the face and shouting abuse towards the school.

At one point he was said to have shouted: Im going to load my ******* gun and get you.

Miss Butler-Savage said there were about a dozen children in the playground who had to be moved inside.

Armitage then turned up at the locked school gates insisting that he hadnt been firing his gun the previous day.

When police arrived he was too drunk to be properly cautioned and was arrested initially for a breach of the peace.

Last month Armitage, now of Wakefield Road, Waterloo, pleaded guilty to two charges of possessing a firearm when prohibited, an allegation of affray and an intimidation charge relating to the incident the next morning.

But his barrister Chloe Hudson told the court that since Armitage had entered his guilty pleas his mental health had deteriorated and a medical report was requested prior to his sentence.

Armitage is currently subject to an interim anti-social behaviour order which bans him from entering the Moldgreen area and Judge Stewart granted him bail until March 19.

The judge warned Armitage that he was likely to be sent to prison.