A man fatally shot by Ventnor police Thursday had advanced on officers with a broken bottle after ignoring several commands to drop it, according to details released by the New Jersey Attorney General’s Office.

The man was “behaving erratically” at Wellington and West End Avenues around 4:15 p.m., walking in and out of a marshy area holding a broken glass bottle, the Attorney General’s Office said in a release issued just before midnight Friday.

The statement said officers offered the man assistance while directing him to drop the bottle. He instead kept walking up and down the roadway, where police had stopped traffic. At about 4:30 p.m. he approached officers with the broken bottle in his hand, and multiple officers fired at him, according to the Attorney General’s Office.

The man was taken by a waiting ambulance to AtlantiCare Regional Medical Center, Atlantic City Campus, where he was pronounced dead at 6 p.m.

Ventnor’s police chief has referred all questions to the Attorney General’s Office, which is required to investigate all civilian deaths related to an encounter with a law enforcement officer.

No other information was provided about the shooting, including the victim’s name and age.

Staff writer Julie Shaw contributed to this article.