Kevin Neal, 43, was armed with a semiautomatic weapon and two handguns when he began firing — apparently at random — shortly before 8 a.m. in Tehama County, the Sacramento Bee reported.

Neal, of Rancho Tehama, was being prosecuted for assault with a deadly weapon and a stabbing that involved two of his neighbors earlier this year, Tehama District Attorney Gregg Cohen told the newspaper.

The prosecutor said it wasn’t clear if Neal had shot one of his neighbors Tuesday. Cohen added that he sometimes used the last name “Smith,” according to the paper.

The shooter killed four and wounded 10 others before he was gunned down by cops Tuesday.

Rancho Tehama Reserve resident Brian Flint said he got a call in the morning from someone who told him his roommate was injured and that his truck had been stolen. His neighbor was the shooter, Flint said.

“The crazy thing is that the neighbor has been shooting a lot of bullets lately, hundreds of rounds, large magazines,” he told the Record Searchlight. “We made it aware that this guy is crazy and he’s been threatening us.”

Authorities said the shooter was armed with a semiautomatic weapon and two handguns.

(ELIJAH NOUVELAGE/AFP/Getty Images)

Flint said the man was a known felon, who often harassed him and his neighbors.

Neal’s shooting spree wounded two children — including one shot at a school and another riding in a pickup truck with a woman who was also struck by gunfire, authorities said.

Police officers later shot and killed Neal. A motive for the shooting is unknown.