Discuss as:

DA: Mass. cop shoots police officer, returns to scene and kills self

BEVERLY, Mass. -- An off-duty police sergeant shot a police officer from a nearby town in Northeastern Massachusetts Friday night, then returned to the scene and killed himself as authorities closed in, the local district attorney said.

Authorities responded to a Starbucks in Beverly after a 911 call at about 5:45 p.m. ET Friday and found Beverly police Officer Jason Lantych shot multiple times, Essex District Attorney Jonathan Blodgett said. Lantych is in serious condition and undergoing surgery, he said.

Off-duty Hamilton police Sgt. Ken Nagy shot Lantych and fled, the district attorney's office said. A warrant was issued for Nagy's arrest on a charge of assault with intent to murder, and authorities said he was believed to be armed and dangerous.

The 43-year-old Nagy returned to the Starbucks at about 10:30 p.m. ET, and police there began to cordon off the scene. Nagy fatally shot himself in his car as officers approached him, Blodgett said.

"He has taken his life," Blodgett told Boston.com. "It is a tragic day."

Nagy and Lantych knew each other but the motive for the shooting is unclear, the district attorney's office said. Beverly and Hamilton are towns about 5 miles apart in northeastern Massachusetts.

Boston.com reported that the investigation was ongoing and that dozens of police officers and emergency medical personnel were gathered at the roped-off Starbucks parking lot Saturday morning.

Nagy was promoted to sergeant last summer after 19 years of service, according to a July 3 story from the Hamilton-Wenham Chronicle. His wife, Katie, smiled as she pinned a badge on Nagy's uniform, and their two young sons clapped, the newspaper reported.

When asked his feelings about the promotion, Nagy told the newspaper, "It feels great. I worked hard over the 19 years to get here."

More content from msnbc.com and NBC News

Msnbc.com staff and The Associated Press contributed to this report.