When the news first broke of a man shooting randomly at bystanders in a provincial shopping mall, it was greeted with disbelief by many in Thailand.
Thailand has more than its share of gun crime; gun ownership, and gunshot deaths, are among the highest in Asia. But no-one could remember a mass shooting like this before, every bit as bad as those in the United States.
By the time it was over, 30 people, including the gunman, were dead.
It began at a little after 3pm on a Saturday afternoon, at a house just outside the city of Nakhon Ratchasima, a sprawling commercial hub for Thailand's north-eastern region.
A 32-year-old sergeant-major shot dead his commanding officer and the colonel's mother-in-law. The three had been in business together buying and selling land, and the sergeant-major was apparently angry about not being paid for a deal he had brokered.
The gunman then went to the Surathampithak army base, a weapons and ammunition supply depot, where he worked. He shot at least one soldier, and was able to steal a truck, two assault rifles, a machine gun, and nearly 800 rounds of ammunition. He also had five guns of his own.
From there he went to a Buddhist temple, 15 minutes' drive away, where people were marking Makha Bucha, an important Buddhist holiday. He opened fire and killed nine people there, and moved into the city centre, and the upscale, airport-themed Terminal 21 shopping mall.
At times videoing himself and streaming it to his Facebook page, he fired his assault rifle at passing cars, killing drivers and passengers. Inside the mall shoppers fled as he entered; hundreds remained trapped for many hours, sending out desperate messages on their phones.
A special police squad went in late on Saturday night, but it was another 12 hours before they were able to kill him, with one police officer shot dead.
Anger at generals and government
At one level this is just another tragic instance of a man going on an inexplicable killing spree, which nobody could have foreseen. As a serving soldier he had access to lethal weapons, so the incident has not even prompted calls for tighter gun ownership regulations.
Yet there is plenty of public anger being directed at the government
The Twitter hashtags "Reform the Military" and "PrayuthRIP" - the latter referring to Prime Minister Prayuth Chan-ocha, who is commonly viewed as having responded clumsily and unsympathetically to the shooting.
At an annual football game between Thailand's two top universities students carried a banner with an acronym everyone there knew represented the phrase "With this stupid leader we will all die".
The military has played an outsized role in Thailand throughout its modern history. It has seized power a dozen times, most recently in 2014.
The generals who led that coup are still in charge, even after an election last year; they re-wrote the constitution to ensure they held onto power. They style themselves the essential defenders of Thailand's untouchable monarchy, deterring or crushing opposition with accusations of disloyalty.
The military is essentially unaccountable to civilian authority, with its own courts, and an expanding budget that remains largely beyond public scrutiny.
A militarised society
Thai society has absorbed many military customs and values; civilian security guards routinely give soldierly salutes, civil servants take part in military-style parades, and the police sport paramilitary paraphernalia; it is not uncommon to see an immigration officer at the airport wearing the silver parachute wings of an elite commando.
Every year in January, Thailand's celebrates a national Children's Day centred on army bases, where young children can play with guns and tanks.
Thais have grown accustomed to the military being in their lives. In return, they have always assumed the soldiers will keep them safe, even as they complain of the perennial corruption and incompetence of the police.
Last Saturday, the military could not do that, even from one of its own. The rogue soldier, it turned out, was a trained marksman, making him a difficult adversary in the cavernous interior of the mall.
The revelation that the gunman had been provoked by a business deal gone sour served as a reminder to Thais that moonlighting by serving army officers, exploiting the authority their status gives them, is commonplace, and that some senior officers have become very wealthy, despite their modest official salaries. Such business practises are particularly problematic between different ranks, as junior officers are unable to challenge seniors they believe are cheating them, a commonly-heard complaint.
The ease with which this soldier was able to steal substantial quantities of weapons and ammunition from an army base highlighted poor security procedures. It is not the first time lethal weaponry has gone astray in the military.
The army commander General Apirat Kongsompong has promised to improve base security, but such promises have been heard before, and it was only last month that General Apirat promised the army would never allow ill-intentioned people to steal its weapons.
The incident has compounded an impression in Thailand of incompetence by what is in effect still a military-led government. It has stumbled this year when responding to a serious air pollution problem, and more recently to the threat of the novel coronavirus. It has failed to revive an economy which has been stagnant since the 2014 coup, yet one in which the already yawning gap between rich and poor has widened.
Public sentiment is turning negative
Many Thais still back the military's predominant role, nervous of renewed political conflict or radical change. But when Thailand held its first post-coup election a year ago, a new political party, calling itself Future Forward did surprisingly well, winning the third largest share of the votes by promising sweeping change, including a diminished role for the military, an end to coups and mandatory military service for young men, and full accountability for the purchases of big-ticket items like tanks and submarines.
Younger Thais in particular responded positively to this platform.
Future Forward had pledged to use its substantial block of seats in parliament to push its reforms, but the party has had multiple legal cases filed against it, some of which could see it dissolved and its leaders jailed.
The military used its five years of authoritarian rule before the election to reshape many of the notionally independent institutions like the Constitutional Court and the Election Commission which will decide the party's future.
Few Thais expect it to survive the legal attrition it now faces. Its dissolution would end the main challenge to the military's position of privilege in Thailand.
But public sentiment is turning negative, perhaps more so than at any time in the past thirty years.
After the shooting in Nakhon Ratchasima, the fiery army commander Apirat Kongsompong issued a tearful apology, and pleaded with the public not to blame the military for what happened. Once the gunman began shooting, he said, he was no longer a soldier.
Whether Thais will accept this defence probably depends on how thorough an investigation the army is willing to allow, and how well it responds to the failures exposed by this rogue soldier. Past experience is not encouraging.
Scandals, like the unexplained deaths of conscripts, have routinely been investigated internally. No soldiers have been held to account for the dozens killed by army gunfire in the political upheavals of 2010.
Few will be betting that this time is different.