Update, 06.20 BST June 4th 2019: The current version of this article cites a higher number of civilians killed, in keeping with more recent reports.

WHERE JUST weeks ago the scent of freedom was in the air there is now the smell of smoke and cordite. The sounds of jubilant song have given way to those of automatic gunfire and the screams of the dying. In the early hours of June 3rd Sudan’s armed forces moved against pro-democracy protesters who had been holding a sit-in since April outside the army’s headquarters in Khartoum, the capital of Sudan. They shot and killed at least 35 civilians. All that remains of the carnival of democracy that had sprouted there are burnt tents and rubbish.

It was the worst violence since demonstrations toppled Sudan’s brutal dictator, Omar al-Bashir, in early April. The Sudanese Professionals Association (SPA), which has spearheaded the uprising since it began last December, called it a “bloody massacre” and announced a campaign of “total civil disobedience” to topple the junta that took power in Mr Bashir’s place.

Trouble had been brewing for some weeks amid a fraught stand-off between protesters and the generals over who would control the country’s transition to democracy. Negotiators for both sides had agreed on some issues, such as the establishment of a civilian-led parliament and cabinet, and a three-year transition before elections. Such was the optimism that on May 15th leaders of the protest movement announced that they would have a deal signed with the generals within 24 hours. But this was premature because they had not reached agreement on the most contentious issue of all: who would be in charge of the sovereign council, the highest decision-making body that would oversee the move towards democracy.

On May 16th, less than 24 hours after the supposed breakthrough, the TMC’s leader, Abdel Fattah al-Burhan, halted the talks and accused the protesters of undermining them by blocking roads in the capital. He claimed “armed infiltrators” had fired on soldiers. The opposition responded on May 28th by declaring a two-day strike.

Since the attack on June 3rd, trust between the two sides has all but evaporated. Protesters say that all the country’s previous transitions were led by the armed forces and that the generals are determined to control this one, too. People in the opposition accuse Muhammad Hamdan Dagalo (who is widely known as Hemedti), the powerful deputy head of the TMC, of foul play. They say that the paramilitary unit he heads, the Rapid Support Forces (RSF), carried out the lethal attack against the sit-in, as well as earlier killings of protesters. Observers, including some foreign diplomats, think that Mr Dagalo wants to become president and that he may undermine any transition that excludes him from power.

But he is not the only one with an incentive to act as a spoiler. Mr Bashir kept himself in power for 30 years by playing armed factions against one another and by allowing them to earn illicit incomes. Many in the TMC may lose out if Sudan moves towards democracy and establishes the rule of law. Many of them also fear justice for atrocities committed by government forces and its militias during Sudan’s long civil wars in Darfur and what is now South Sudan. “This is a game with huge stakes,” says Harry Verhoeven, the author of a book on Sudan. “Why would those who have guns give them up voluntarily?”

The latest violence means there is even less hope for compromise. On one side are the generals, who have won the support of powerful autocratic countries in the region including Egypt, Saudi Arabia and the United Arab Emirates. Emboldened, they are no longer bothering to disguise their reluctance to cede power to civilians. “The negotiations were never serious from the beginning,” says Rashid Abdi, an independent expert on Sudan based in Nairobi. “The army was just playing for time.” On the other side are the demonstrators, who are angry at the betrayal of their democratic revolution. “This is not going to stop,” says Reem Abbas, a Sudanese journalist in Khartoum. “The protests are going to continue.”