A Maplewood man who terrorized his parents and savagely beat his mother with a hammer earlier this year faces up to 20 years in prison after pleading guilty to attempted first-degree murder.

David Edward Williams Jr., 22, took his mother hostage in her Woodbury house the evening of Jan. 21 and struck her several times before taping her to a chair.

He then texted his father with her phone, luring him to the house, before threatening both parents with a loaded 12-gauge shotgun.

Williams, who has a bipolar condition, had stopped taking his medications and was drinking alcohol and taking drugs when the attack occurred, according to the complaint filed in Washington County District Court.

As his mother pleaded "Please don't hurt me," Williams closed all the blinds and opened a large black bag that contained a shotgun, baseball bat, knife and hatchet.

After hitting his mother with the hammer, he continued to menace his parents with various weapons and told them he planned to smoke marijuana before killing himself.

He finally allowed his parents to flee. His father drove his mother to Woodwinds Hospital in Woodbury, where it was discovered she had an open skull fracture and a traumatic brain injury among other wounds.

A law enforcement SWAT team, meanwhile, surrounded the house. Williams surrendered after several hours of negotiations.

Police recovered the weapons, including several knives, and a journal-type document in which Williams had written after the attack:

"Last day. Decided to show mercy. I didn't think I could spare them but I guess I can. Good bye. I'm sorry I hit you. I've lost my mind."

The complaint said Williams was angry at his parents for having medicated him as a child. The family had changed locks on their house after he threatened his mother and another family member about a month before the attack, the complaint said.

Williams had demanded a list of everyone involved in putting him on medications, "but would not disclose what he intended to do with the list," the complaint said.

His mother now suffers from constant headaches, nausea and dizziness, according to the complaint. She's had surgery and goes to as many as 15 medical appointments a week.

With his guilty plea entered Thursday, Williams faces up to 20 years in prison, said Washington County Attorney Pete Orput. Sentencing will be Nov. 22 in Stillwater before District Judge Mary Hannon.