Jirattikarn Nobthai was riding his bike to the Terminal 21 shopping mall when the shooting began. He got down and tried to help others, said his mother, Sasithorn Suthisook, and he was hit once in the arm and in his side.

“He was conscious even though he was shot. He called and told us ‘I was shot’ and then my husband rushed to the scene to take him to hospital,” she said. “Part of the area was declared off-limits, with traffic closed, but he couldn’t care less. It was a matter of life and death.”

The gunman, a soldier identified as Jakrapanth Thomma, had arrived at the mall in Nakhon Ratchasima at about 6pm on Saturday. Driving a Humvee-type military vehicle and carrying weapons and ammunition stolen from an army base, Jakrapanth fired at drivers and pedestrians in the area.

Inside the mall, shoppers took cover behind counters and inside bathrooms and stockrooms. Chanathip Somsakul and his family were among those who barricaded themselves in the women’s toilets on the fourth floor. The 33-year-old music teacher and his wife searched social media for information and rang friends and family as they waited with their three-year-old daughter.

“A friend who works at the mall was talking to a guy in the CCTV control room … he gave us updates on the location of the gunman,” Chanathip told Agence France-Press on Sunday.

Others muted their phones and waited in silence to avoid being detected. Aldrin Baliquing, a Filipino teacher in his 40s, meditated inside a H&M stockroom to stay calm. “I was so scared because the shop where we were trapped was just above the establishment where the gunman held his hostages,” he said, referring to unconfirmed reports that the gunman had taken human shields.

More than five hours after Jakrapanth entered the mall, security forces confirmed they had managed to secure the ground floor and several higher levels. Outside, motorbike taxis offered free rides to the crowds of panicked people who had been evacuated in groups. At local hospitals, people rushed to donate blood to help the injured.

Nobthai’s family received offers of financial help from wellwishers after they posted online that they were unable to find a loan big enough to cover medical bills at the private hospital in which the boy was being treated. He has since been transferred to a state hospital.

At least 29 people were killed in the attack. “I’m still in shock and disbelief that this happened in the town I grew up in,” said Kreangsak Suwanpantakul, 41, who is from the city but was not present at the time. “People would say [mass shootings are] an American thing, especially school shootings, but in Thailand and especially in Korat one could never imagine things like this would ever happen,” he said, using the common alternative for Nakhon Ratchasima.

Soontaree Channuan, who works at Parkviewplace Inn, a hotel near to Terminal 21, said he initially thought the sound of gunfire was a firecracker. Almost all of his guests work at the mall, he said. “There were only seven or eight guests yesterday. And they were inside the mall. Luckily, they were safe. They came back at night – some at 9pm and the others at 11pm,” he said, adding: “This kind of thing has never happened to us.”

On Sunday the city was visited by the prime minister and other officials, but Soontaree said the streets were quiet. Volunteers came to the area to give food to emergency responders who worked throughout the night on an operation that lasted 16 hours.

The final group of people to be rescued from the mall left just before 9am on Sunday. Some were reportedly injured. In the evening, crowds of people wearing black gathered at the city’s Thao Suranaree monument to pray.

Nobthai has undergone two operations, including surgery to remove his kidney, and remains in intensive care. “I haven’t eaten since yesterday. We just couldn’t eat anything and didn’t feel like it. We haven’t slept either,” his mother said. “We just hope for his recovery.”