A 16-year-old shooter killed three children and a teacher at Silver Rail Elementary School in Bend, Oregon on Thursday afternoon before being shot dead by a bystander, police said.

The suspect forced his way into the school by shooting at locked doors around 12:59 p.m. local time, Bend Police Chief Mike Krantz said. The three children killed were aged five, eight and eleven. A seven-year-old and a 54-year-old teacher were hospitalized in critical condition, Krantz said.

Police received the first report at 12:59 p.m. from a person who said an unknown suspect was shooting into their car with a long gun. Photos from the scene showed a red truck with bullet holes. Minutes later, 911 calls reported the attacker had entered the school building.

A community member who witnessed the shooting pursue the attacker into the school and engaged him fatally. The bystander killed the suspect moments before local law enforcement arrived at the scene three minutes later, Krantz said.

Police have not released the names of the victims or further details about the attacker. It remains unclear whether the shooter had any connection to the school.

Steven Cook, the top administrative official of the local school district, said in a statement that the community was "stunned and heartbroken by this senseless tragedy."

Silver Rail Elementary School serves around 450 children and has more than 40 adult staff members. Schools in Bend remained closed Friday as officials said the community needed time to heal.

According to the K-12 School Shooting Database cited by police, there were 235 shooting incidents at American schools last year and at least 140 so far this year.