MINNEAPOLIS — The man charged with killing one Minnesota lawmaker and wounding another meticulously planned the shootings and intended to inflict more carnage against those on his hit list, driving to the homes of two other legislators on the night of the attacks, a federal prosecutor said Monday.

But one of those state lawmakers was on vacation and the suspect left the other house after police arrived early Saturday, acting U.S. Attorney Joseph Thompson said.

Investigators say Vance Boelter appeared to spend months preparing for the shootings — the latest in a string of political attacks across the U.S.

Boelter carried out surveillance missions, took notes on the homes and people he targeted and disguised himself as a police officer just before the shootings, Thompson said.

“It is no exaggeration to say that his crimes are the stuff of nightmares,” he said.

Boelter surrendered to police Sunday night after they found him in the woods near his home following a massive search that stretched over two days. He is accused of fatally shooting former Democratic House Speaker Melissa Hortman and her husband, Mark, in their home early Saturday in the northern Minneapolis suburbs.

Authorities say he also shot and wounded Sen. John Hoffman, a Democrat, and his wife, Yvette, who lived just a few miles away.

Federal prosecutors charged Boelter, 57, with murder and stalking, which could result in a death sentence if convicted. He already faces state charges, including murder and attempted murder. At a federal court hearing Monday in St. Paul, Boelter said he could not afford an attorney. A federal public defender was appointed to represent him, and he was being held without bail pending a court appearance next week. Manny Atwal, his lead attorney, declined to comment, saying the office just got the case.

Boelter had many notebooks full of plans, Thompson said. Underscoring what law enforcement officials said was the premeditated nature of the attacks, one notebook contained a list of internet-based people search engines, according to court records.

But authorities have not found any writings that would “clearly identify what motivated him,” Thompson said. Though the targets were Democrats and elected officials, Thompson said it was too soon to speculate on any sort of political ideology.

All of the politicians named in his writing were Democrats, including more than 45 state and federal officials in Minnesota, Thompson said. Elected leaders in other Midwest states said they, too, were mentioned in his writings.

Authorities declined to reveal the names of the other two lawmakers whose homes were targeted but escaped harm. Democratic Sen. Ann Rest said she was told the suspect parked near her home early Saturday. She said in a statement that the “quick action” of law enforcement officers saved her life.