MANCHESTER, New Hampshire — A Maine man accused of firing a gun in a New Hampshire shopping plaza, saying he believed “zombies,” “droids” and “drones” were trying to get him, pleaded guilty and was sentenced to at least two years in prison Wednesday.

Gordon Falt, 27, of Mount Desert, Maine, pleaded guilty to 13 counts of reckless conduct with a deadly weapon, being a felon in possession of dangerous weapons and other charges, WMUR-TV reported.

The Lee Market Place plaza was busy with shoppers at the Market Basket and other stores in October when shots were heard. Shoppers were placed on lockdown in the grocery store and shops for about two hours during a standoff. No one was injured.

Falt surrendered after two hours. Police recovered several rifles, shotguns and handguns, along with ammunition that turned out to be stolen.

The judge accepted Falt’s guilty pleas on the charges.

“I would just like to be stable and really live up to my potential, clean and sober,” he told the judge.