A hammer-wielding man wanted in connection with a series of attacks in Manhattan was shot by a New York police officer on Wednesday on a busy Midtown street in a confrontation captured on surveillance video, the authorities said. The man, whom two police officials identified as David Baril, 30, was takento Bellevue Hospital Center, where he was in critical condition. Speaking at a news conference at the scene, at 37th Street and Eighth Avenue, the police commissioner, William J. Bratton, said Mr. Baril fit the description of an attacker who struck four people with a hammer on Monday around Union Square and Midtown. On Wednesday, two uniformed officers, Geraldo Casaigne, 36, and Lauren O’Rourke, 27, were on patrol in Midtown when they saw the man and believed him to be the suspect in the earlier attacks, Mr. Bratton said. The officers followed him from 38th Street along Eighth Avenue. After a block, the man turned and stopped at the corner of 37th Street. “He’s almost waiting for them as they cross the street,” Deputy Chief William Aubry, the commander of Manhattan detectives, said at an afternoon news conference in Midtown in which video of the shooting was shown.