A Kevlar vest and a helmet may have saved the lives of two city officers shot before dawn Wednesday by a man who then barricaded himself in a basement in Summerdale, police said.

The man is Nasuil "Nas" Martinez, who was wanted in the Dec. 10 shooting of an officer.

Martinez was in serious condition at Temple University Hospital Wednesday after apparently accidentally shooting himself in the neck during the standoff.

Sgt. Christopher Binns, a 21-year veteran of the department, was shot with a .45-caliber handgun on the left side of his helmet, a blow that made a dent. Another shot hit Officer Francis Whalen, a 12-year veteran, directly on the ceramic plate he wore inside his vest.

The protective gear deflected the bullets, and neither officer was injured - something Deputy Commissioner Richard Ross called "nothing short of miraculous."

Had patrol officers responded first, they would not have been wearing the protective gear that members of the SWAT team use, Ross said.

"Either one of these shots would have taken a life, without question," Ross said at a news conference Wednesday, standing beside the protective gear worn by the officers. "We are just so thankful."

Martinez, 20, is accused of shooting and wounding Officer Kevin Gorman during a foot chase after a traffic stop in North Philadelphia. Gorman, 33, was treated and released within a few hours of the incident.

A $10,000 reward was recently posted for the arrest of Martinez, of North Philadelphia, in connection with that shooting.

Martinez has been arrested for assault and drugs and weapons charges, but many of those charges were later withdrawn. A judge issued a bench warrant for Martinez's arrest in October after Martinez failed to appear at a bail hearing on drug charges, records show.

Around 3:30 a.m. Wednesday, police in the homicide unit and the Second District got tips that Martinez was in a house in the 800 block of East Sanger Street. Concerned about Martinez's alleged record of firing at police, a sergeant in the Second District contacted the SWAT team, which surrounded the house around 4:30 a.m.

After a woman let police into the house, Binns, 49, and Whalen, 36, saw a man run to the basement. As they followed, shots rang out, police said, and Martinez fired a .45 caliber handgun through the drywall of a back room.

Both officers returned fire and got out, police said. Whalen, who was hit in the chestplate, did not even drop to one knee from the impact, said Chief Inspector Joseph Sullivan.

Other members of the SWAT team began negotiations with Martinez, who had barricaded himself, Sullivan said. Nearby houses and Fels High School were evacuated as officers communicated with Martinez.

Around 7:30 a.m., as police said Martinez was preparing to surrender, police who were communicating with him heard a gunshot and Martinez saying, "Oh, it went off." According to Police Commissioner Charles H. Ramsey, who spoke with reporters at the scene, Martinez shot himself by accident.

Officers immediately brought Martinez out on a stretcher.

He was taken to Temple in critical condition.

Binns and Whalen were taken to Albert Einstein Medical Center. When they were cleared of injuries, they wanted to return to the standoff.

"We had to literally order them out of the scene," Ross said. "Despite the gunshot. I mean, that would traumatize any of us. That just underscores the bravery of the men and women in this unit."

Contact staff writer Allison Steele at 215-854-2641 or asteele@phillynews.com

.