It is said that in war, truth is the first casualty. Something similar happens on our political battlegrounds as well, where truth, if it survives, is usually a heavy underdog.

So it was in the aftermath of the Florida high-school slaughter, where gun-control advocates mounted their hobby horses before the bodies were collected. They were sure that, this time, they would crush the NRA bogeyman and get what they wanted.

Leave aside that what many activists wanted — confiscation of tens of millions of existing, lawful guns — is practically and legally impossible. They nonetheless dominated early media coverage because they have honed their good-vs.-evil narrative and because most of the media live in gun control’s amen corner.

Yet an odd thing happened on the way to their triumph. After a late start, a greater truth of the Florida slaughter is now dominating the discussion and setting the agenda.

This greater truth is that there were many chances to stop gunman Nikolas Cruz long before he opened fire. Equally important, the claim from some in Florida law enforcement that they are legally handcuffed until someone commits an act of violence turns out to be false.

These emerging facts are wreaking havoc with the initial simplistic narratives and are changing how Americans view the shooting and what measures they think would be more successful in preventing other massacres. In effect, the Florida story is changing before our eyes.

One result is that an early star of the gun-control faction, Broward County Sheriff Scott Israel, is morphing into a villain. His department’s repeated failure to intervene in the violently downward spiral of the gunman was bad enough, but the refusal of his deputies to enter the school until the shooting stopped is a stain that Israel’s TV-ready bravado can never remove. There will be little lamenting when he loses his job.

As the nation has learned, Cruz was a well-known danger to neighbors, school officials, social workers and law enforcement. He threatened to kill classmates — in writing — and was expelled.

Yet even as his behavior grew more menacing and Broward cops visited his house dozens of times, officers believed there was nothing they could do. But as The Miami Herald detailed, they were wrong.

It cites former prosecutors who say Cruz’s threats to his classmates could be classified as aggravated cyberstalking, a felony. There is also a state law against making written threats to kill.

Moreover, being charged with aggravated cyberstalking could have cost Cruz the gun he used in the shooting. The Herald says that posting bond in Broward County on a felony charge would have required him to surrender all guns.

The FBI missed its chances to stop Cruz, too. Last September, he wrote, “I’m going to be a professional school shooter” on a YouTube channel, and it was reported to the FBI, which dropped the ball instead of treating the comment as a threat of terrorism, a felony.

Then in January, an unidentified woman warned the FBI that Cruz “would get into a school and just shoot the place up,” The Wall Street Journal reported.

“I know he’s — he’s going to explode,” the caller said, according to a transcript the Journal saw.

Again the agency did nothing, which prompted Director Christopher Wray to apologize to grieving families and promise an investigation.

The changing media coverage is changing public views. A Rasmussen survey released Tuesday reports that 54 percent of respondents believe the failure of government to respond to warnings about Cruz is more to blame for the murders than inadequate gun control, while just 33 percent view it the other way around.

Thankfully, New York already has exhibited a growing awareness of the danger. Last Friday, the NYPD arrested an employee from the Bryant Park skating rink who made social-media threats against the Midtown spot, The Post reports.

Emmanuel Nival, 17, boasted of an attack coming on March 4 on Instagram, and his boss alerted cops, who say the teen confessed to a charge of aggravated harassment.

Albany is getting in on the action, too, with supporters pushing a “red flag law.” It would allow police and family members to get an “extreme-risk protection order” in court against someone seen as a danger to others or themselves.

As state Attorney General Eric Schneiderman said in urging passage, “We have an opportunity to ensure that, when the next potential Nikolas Cruz exhibits clear red flags, that individual can be disarmed before another tragedy.”

Five states already have similar laws, and as many as 20 others are considering them. In general, the laws contain an appeals process for the targeted individual.

This strikes me as the right direction for the country. While some national gun-control measures are appealing, such as raising the legal age to 21 for certain guns, the most direct path to public safety is for local officials to take action against individuals who threaten violence and pose an immediate danger.

Had that happened in Florida, Nikolas Cruz would not have had a gun of any kind, and his 17 victims would be alive.

Related Video Video length 1 minute 8 seconds 1:08 Deputies respond to ‘active shooter’ at Florida high school Deputies respond to ‘active shooter’ at Florida high school

The Terry-ble truth

She’s baaack — or at least her stalking horse is. Terry McAuliffe, the former Virginia governor and longtime pal of Bill and Hillary Clinton, is lining up to challenge President Trump in 2020.

Months ago, an insider predicted to me that McAuliffe, a Democrat, would run and be “Hillary’s candidate,” meaning he’d drop out if she decides to run.

Don’t say you weren’t warned.

Bernie’s noncents

It’s hard times for socialists.

A Bernie Sanders’ fundraising pitch asks for a $3 donation — which the Vermont senator promises to split between a former aide’s campaign for Congress and his own travels to rally progressives.

“I would not ask if it wasn’t so important,” Sanders says

Geez, how important can $1.50 be?

Tax facts rebut Cuo-is-me whining

Gov. Cuomo’s incessant braying that the federal tax law is bad for New Yorkers is running up against inconvenient facts.

George Sweeting of the Independent Budget Office told the City Council that nearly all city taxpayers with adjusted gross incomes under $500,000 either will get tax cuts or face little or no changes.

As for the $10,000 limit on deducting state and local taxes, Sweeting said that would mostly affect just 56,000 city taxpayers who have adjusted gross incomes above $500,000. Those families, he said, make up only 2.6 percent of taxpayers, but account for 53 percent of city income-tax payments.

But even they might come out ahead because of other changes in the law, Sweeting said.

Corporations and small businesses based here also stand to get big tax cuts, which will leave them with more money to spend in the local economy. But Cuomo can’t celebrate any of this because the federal changes expose New York’s punishingly high taxes, and increase the incentives to move to lower-tax states.