A Jackson Township man who fired about 30 large-caliber bullets into the occupied home of his neighbor, then held police at bay for five hours, must spend at least seven years in prison.

Hours after the incident, William A. Marx Jr. expressed disappointment the neighbor escaped injury, according to Northern York County Regional Police.

But defense attorney Steve Rice maintains mental-health issues and alcoholism caused Marx to act out, and that he didn't intend to hurt anyone.

"This guy was suicidal and lost it," Rice has said.

Senior deputy prosecutor Jonathan Blake didn't agree.

"It sounded like he wanted to kill her," Blake said.

Falling apart: Marx had been fired from his job the night before because of his drinking.

"Everything was falling apart," Rice said. "This is a good man who did a bad thing."

On Wednesday, Marx pleaded no contest to one count of attempted homicide. In exchange, the lesser charges lodged against him were dismissed, including 30 counts of firing into an occupied structure.

He pleaded no contest rather than guilty because his level of intoxication at the time of the incident affected his memory of it, Rice said.

As part of his negotiated plea agreement, Marx was sentenced to seven to 14 years in state prison, with credit for the time he's already served. Marx has been in prison on $1 million bail since June 10, 2011, records state.

The background: Northern Regional Police rushed to Marx's home at 77 S. Alpine Drive about 9:45 a.m. June 9, 2011, after receiving a call from his sister, who reported Marx had been drinking and was armed and suicidal, according to court documents.

Police made contact with Marx, who told them he intended to shoot officers and himself, documents state. He forced a five-hour standoff that ended when he surrendered about 2:30 p.m.

During the standoff, Marx fired about 30 bullets from multiple guns through his wall and into Joan Mayhew's adjoining home, according to police. Mayhew was home at the time.

The guns: Those weapons included a .50-caliber revolver, a .40-caliber handgun, two .38-caliber handguns and a Tec-9 handgun, police said.

After arresting Marx, officers found electronic equipment he allegedly used to monitor Mayhew's telephone calls, and also found a small remote-controlled camera device that Marx allegedly used to monitor police during the standoff.

Marx apparently was angry with Mayhew because he'd twice been cited with disorderly conduct for loud noise after she complained to police about him, according to prosecutors.

-- Reach Liz Evans Scolforo at