Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

A man armed with a knife and a BB gun stabbed six people at a Pennsylvania mental health facility before he was shot by police, authorities said.

Those stabbed in the attack at Turtle Creek Valley Mental Health facility in Homestead were taken to four area hospitals, Allegheny County Police Superintendent Coleman McDonough said.

Police cars are seen outside the Turtle Creek Valley Mental Health facility in the Homestead-Munhall border after a man allegedly stabbed six people before being shot by police on Friday, Oct. 11, 2016. John Denis

The suspect, 38-year-old Dustin Johnson, was in surgery, McDonough said. Johnson had received treatment at the facility, a resident advisor told NBC affiliate WPXI.

Johnson was acting strangely, pulled out what looked like a handgun and was later heard saying “you ruined my life," resident advisor Cherrel Fulton, who hid under her desk during the attack, told the station.

Johnson used a kitchen knife to stab people at the mental health facility, McDonough said.

He was confronted by SWAT team members on the fifth floor of the facility and put the knife down but did not drop the BB gun, which police said looked like a firearm, WPXI reported.

Homestead is a borough of around 3,100 in Allegheny County southeast of Pittsburgh.