WASHINGTON (AP) — For a few moments anyway, there was a sense of what people once called "Beto-mania."

Former Texas Congressman Beto O'Rourke delivered a debate performance on Thursday in Houston that at times reminded a national audience why he became a Democratic star last year — even as he lost a Senate race.

Asked about a mandatory federal buyback of assault weapons that he has endorsed since a gunman opened fire at a Walmart in his native El Paso, killing 22 people, O'Rourke delivered one of the night's few memorable lines. "Hell yes, we're gonna take your AR-15, your AK-47, and we're not going to allow it to be used against your fellow Americans anymore," he said.

That allowed O'Rourke — who suspended his campaign for nearly two weeks to head home and attend vigils and visit victims who remained hospitalized after the mass shooting — to assert ownership of the issue of gun control in a way none of the other nine candidates onstage could.

On a night that was supposed to feature sniping between White House hopefuls with better polling numbers, those rivals instead took time to praise O'Rourke.

Joe Biden said O'Rourke's post-shooting effort in El Paso was "meaningful," and the former vice president created a lighthearted moment when he offered: "Excuse me for saying Beto. Congressman O'Rourke."

Even Sen. Cory Booker saluted O'Rourke while noting that, in communities of color, ordinary gun violence claims more lives than mass shootings that grab national headlines do. "We must awaken a more courageous empathy in this country," Booker said.

In the wake of the El Paso shooting, O'Rourke has remade his presidential bid. He has focused more on the urgent need to curb gun violence. He has decried what he calls racism on President Donald Trump's part. He is still frequently traveling to the states that kick off presidential primary voting: Iowa, New Hampshire, Nevada and South Carolina. But he has also visited an Arkansas gun show and said there's more bipartisan agreement on the need for federal firearm limits than many believe.

To be sure, praise from his presidential rivals may indicate that they no longer see O'Rourke as a serious threat. Fresh off nearly upsetting Republican Sen. Ted Cruz in the nation's largest red state last November, O'Rourke burst into the race for the White House in March only to see his once promising polling and fundraising decline sharply.

O'Rourke's supporters had looked to the first two Democratic debates in Miami and Detroit for strong performances that could lift their candidate back among the crowded field's top tier — but found his efforts lacking. This time, O'Rourke didn't schedule public events in the days leading up to the Houston debate, freeing up time to prepare.

That led to O'Rourke appearing more confident and poised than during previous debates, and answers that seemed unfocused in the past were far crisper Thursday.

To start the debate, O'Rourke said the gunman who drove 600-plus miles to El Paso, on the Texas-Mexico border, after posting an anti-immigrant screed online was "inspired to kill by our president."

Tim Murtaugh, a spokesman for President Donald Trump's reelection campaign, responded on Twitter that O'Rourke is "as desperate as he can be." The shooter had insisted his opinions "predate Trump and his campaign for president."

But after his "Hell yes" moment, O'Rourke looked anything but desperate. A short time later, his campaign riffed off fellow presidential hopeful and Massachusetts Sen. Elizabeth Warren's having a "plan" for everything with a fundraising tweet featuring an image of a military-style rifle over the caption, "Beto has a ban for that."