For the passengers trapped in carriages 12 and 13 with nowhere to run, the terror must have been unimaginable.
It was just after 5.50pm on the high-speed Amsterdam to Paris train that the slightly-built young man emerged from a lavatory between the two carriages.
He was bare-chested and brandishing a Kalashnikov automatic rifle, some kind of knife and a handgun.
Then he took aim.
One passenger said he was reading a magazine. The train had just crossed the border from Belgium into France when he heard a "click, click, click".
"I thought it was a toy," said Damien, 35, a French passenger.
"The man stopped between two carriages, fired and it made a 'click-click-click' sound, not at all like in the films."
Christina Cathleen Coons, 28, an American tourist from New York, was sitting in carriage 12 when she heard shots.
"I heard gun shots, probably two, and a guy collapsed," she said.
"Blood was everywhere. Apparently he was hit in the neck. [I thought] Maybe I'm next. Is this train going to get shot up?"
Another American tourist - who gave her name only as Amy - had been sitting beneath the window in carriage 12 when the glass shattered around her.
"I saw the glass fall over my wife's shoulders," said her husband Joe.
The passengers were caught with nowhere to run and with no way of escaping.
The train was from this point non-stop to Paris.
The last stop had been Brussels, where the terrorist, wearing pale-coloured trousers and black t-shirt, had boarded the train unnoticed, his weapons hidden away in a holdall and backpack.
Accounts vary as to what precisely happened when the shooting started.
According to reports, a French passenger who left his seat to go to the lavatory then tried to disarm the gunman.
"[He] courageously tried to tackle him before the attacker fired several shots," said Bernard Cazeneuve, the French Interior Minister.
It is thought that passenger may have been shot through the neck or else slashed across the throat with a knife or box-cutter.
The gunman appeared to have the carriage at his mercy.
According to Jean-Hugues Anglade, a French actor, train staff ran for cover, locking themselves into their private office.
And then - as if by a miracle - the US cavalry arrived in the form of two off-duty US servicemen on holiday.
Their fortune was compounded when the AK47, the normally-reliable weapon of choice of terrorists, jammed.
Spencer Stone, a US airman, was beginning his holiday in France with two friends Alek Skarlatos, 22, a member of the US National Guard, from Oregon, and Anthony Sadler, a college student from Pittsburg, California.
The trio heard a gunshot and the sound of glass breaking and watched a train employee race past them with the gunman in pursuit, "cocking his gun to shoot".
Mr Skarlatos turned to his friend Mr Stone, a powerfully-built serviceman with close-cut hair, and uttered a simple command: "Go get him."
With that, Mr Stone leaped up from his seat, ran at least ten yards through the carriage and grabbed the gunman before he could fire any further shots.
Chris Norman, a British consultant, was sitting close to the trio and witnessed the events unfolding.
"I ducked down in my seat," said Mr Norman.
"Alek looked at what was happening, Spencer looked at what was happening, and Alek said to Spencer: 'Go get him'. Spencer jumped up and tackled him and actually started getting the terrorist under control."
Mr Skarlatos said: "Spencer ran a good 10 metres to get to the guy and we didn't know that his gun wasn't working or anything like that. Spencer just ran anyway and if anybody would have gotten shot it would have been Spencer for sure and we are very lucky that nobody got killed, especially Spencer."
Mr Stone was slashed with a knife a number of times and Mr Skarlatos, who had recently returned from a tour of duty in Afghanistan, smashed him about the head with the butt of the gunman's own weapon.
"At that point I showed up and grabbed the gun from him and basically started beating him in the head until he fell unconscious," said Mr Skarlatos.
As they tried to subdue him, the terrorist pleaded for his rifle back.
"He was just telling us to give back his gun," said Mr Skarlatos.
"But we just carried on beating him up and immobilised him and that was it."
Mr Skarlatos later told Sky News: "I grabbed the handgun, got the handgun away from the guy and threw it. Then I grabbed the AK [automatic rifle] which was at his feet and started muzzle-thumping him in the head with it.
"Everybody just started beating on the guy while Spencer held the choke hold, until he went unconscious at that point. People started to restrain him."
Mr Norman, 62, was one of those.
"We ended up by tying him up, then during the process the guy actually pulled out a cutter and starting cutting Spencer," said Mr Norman, "He cut Spencer behind the neck, he nearly cut his thumb off too. Spencer held him and we eventually got him under control. He went unconscious, I think."
Incredible video footage taken by Anthony Sadler and posted on CNN news channel shows the aftermath.
The gunman is lying on the floor.
He is face down, his hands tied behind his back with an item of clothing used as a makeshift rope.
The video shows another man bloodied and on the floor and blood on the nearby window.
Mr Stone had helped staunch the flow of blood of the other injured man before he became too weak himself.
Fifteen minutes later, the Thalys train 9364 pulled into Arras station in northern France; the ordeal over.
The gunman was later named as Ayoub El Khazzani, a 26-year-old Moroccan who had boarded the train at Brussels at just after 5.10pm.
Mr Stone and the other injured man were rushed to hospital.
Mr Stone, according to his friends, was "in good spirits" and "doing great"; the other man also out of danger.
The Americans had become heroes.
Just like in the movies, they had stopped the bad guy.
- The Sunday Telegraph