The man accused of shooting two New Hampshire police officers agreed to mental health counseling in 2012 after he was charged in an assault his father said was a "schizophrenic" episode, court records show.

Ian MacPherson, 32, pleaded not guilty Monday to two counts of attempted capital murder in the Friday shootings of Manchester police officers Ryan Hardy and Matthew O'Connor. A police affidavit released Monday says he went through a background check before purchasing the gun he allegedly used to shoot the two officers.

MacPherson didn't attend the arraignment, but his father said afterward that MacPherson has a history of mental illness. Russell MacPherson told police in 2012 that his son had been diagnosed with schizophrenia, according to records in Merrimack District Court.

"He's been suffering mental illness issues for a long, long time," Russell MacPherson said after Monday's arraignment, standing in front of several other family members. "Hopefully he's going to get help with that, and we're going to be there for him."

Hardy, 27, and O'Connor, 28, both appeared in court Monday. O'Connor, who was shot in the leg, entered the courtroom on crutches. Hardy had been shot in the face and torso; he wore bandages on his face. They were joined by dozens of fellow police officers.

"It's just important that each officer knows that they're supported by one another," Manchester Police Chief Nick Willard said after the arraignment. "The outpouring of support is just amazing, it's just one of those things that you wish you could capture it, bottle it, and keep it forever."

MacPherson is being held without bail; his next court hearing is May 27.

The police affidavit released Monday says MacPherson had to wait to purchase a gun in March while police conducted a background check. He returned to the store roughly two weeks later and bought the gun. Under federal law, someone who has been involuntarily committed to a mental health facility or declared mentally ill by a judge cannot legally buy a gun.

Russell MacPherson told WMUR-TV this weekend that his son didn't receive adequate mental health care and should not have been able to obtain a gun.

"I'm sorry to begin with that these officers were injured," the elder MacPherson told the TV station. "I know they have a very hard and thankless job often, but even more sorry if it was my son that did this."

MacPherson last faced criminal charges in 2012, when he went into his father's home and kicked, punched and slammed him on the ground, according to court records. Russell MacPherson told police at the time that Ian was diagnosed with schizophrenia and was having "an episode" during the attack, court records show.

MacPherson's sentence was suspended when he agreed to go through a court-approved mental health program, records show.

MacPherson's attorney at the time, Joseph Tessier, requested an evaluation of whether MacPherson was competent to stand trial, but it's unclear from court documents whether that evaluation was completed and what the results were. Tessier could not be reached for comment Monday.

Records show MacPherson's relatives worried in August 2012 that he was not complying with his mental health program. Court documents say MacPherson accused his mother of being a "shape shifter" during a drive that month and he left the car despite her protests. MacPherson was subject to monthly reviews by the court and a judge closed his case in April 2013, writing that MacPherson was complying with the counseling.

Hardy was pursuing MacPherson early Friday because he matched the description of a man who robbed a gas station at gunpoint the day earlier. MacPherson allegedly fled the scene after shooting Hardy and encountered O'Connor about 20 minutes later.

MacPherson allegedly said something like, "I am the guy you are looking for," before shooting O'Connor, the police affidavit shows.
Russell MacPherson did not return a call later Monday. An unidentified man who appeared to be representing MacPherson's family at the arraignment said they would not be commenting further.