A gunman who killed a student and a teacher at a Missouri high school was armed with an AR-15-style rifle and more than 600 rounds of ammunition.

Orlando Harris, 19, had magazines strapped to his chest, some in a bag, and other ammo police found dumped in stairwells around Central Visual and Performing Arts High School in St Louis.

Alexandria Bell, 15, a student, and Jean Kuczka, 61, a PE teacher, died and seven other students were injured in the shooting spree on Monday.

Harris, who graduated from the school last year, was eventually killed in a firefight with police.

He left behind a handwritten note explaining why he carried out the attack.

In the message he complained he had no friends, no family, no girlfriend and lived a life of isolation which he called the “perfect storm for a mass shooter”.

The attack forced students to barricade doors, huddle in classroom corners, jump from windows and run out of the building to seek safety.

Several people inside the school said they heard Harris shouting: “You are all going to die!”

Michael Sack, the police commissioner, urged people to come forward when someone who appears to suffer from mental illness or distress begins “speaking about purchasing firearms or causing harm to others”.

Andre Bell, the father of the student who died, described is daughter as his “everything”.

“She was joyful, wonderful and just a great person,” he said.

“She was the girl I loved to see and loved to hear from.

“No matter how I felt, I could always talk to her and it was all right. That was my baby.”

‘This could have been much worse’

Abbey Kuczka said her mother Jean was killed when the gunman burst into her classroom and she moved between him and her students.

“My mom loved kids,” Ms Kuczka said. “She loved her students. I know her students looked at her like she was their mom.”

The seven injured students are 15 or 16 and said to be in a stable condition.

Police said four suffered gunshot or graze wounds, two had bruises and one had a broken ankle – apparently from jumping out of the three-storey building.

Harris was armed with nearly a dozen 30-round high-capacity magazines, Mr Sack said.

“This could have been much worse,” he said.

The school shooting was the 40th this year resulting in injuries or death, according to Education Week – the most in any year since it began tracking shootings in 2018.

The deadly attacks include the shooting at Robb Elementary School in Uvalde, Texas, in May, when 19 children and two teachers died.