El Paso’s Tigua Native American tribe suffered another major defeat this week in their quarter-century battle with Texas over casino-style gaming when a federal judge ruled that their bingo and machine games violated state law.

U.S. District Judge Philip Martinez of El Paso issued a summary judgment on Thursday in favor of the state, which has gone to court multiple times over the past two decades in attempts to close the tribe’s popular Speaking Rock Casino. Martinez’s ruling relied heavily on past court decisions, including one by the 5th Circuit Court of Appeals, that state law prohibits the Tiguas from offering casino-style games.

“The court is cognizant that an injunction will have a substantial impact on the pueblo community. Accordingly, the court joins the refrain of judges who have urged the tribes bound by the Restoration Act to petition Congress to modify or replace the Restoration Act if they would like to conduct gaming on the reservation,” Martinez wrote.

Leadership and lawyers for the Tiguas, who also are known as the Ysleta del Sur Pueblo, did not immediately respond to a request for comment. A spokesman for Texas Attorney General Ken Paxton, who led the lawsuit against the Tiguas, praised the ruling. “Our office’s investigation provided proof that the Tribe’s activities at Speaking Rock violate Texas gaming laws and regulations. The district court’s ruling upholds federal law, halts the Tribe’s illegal activity, and allows Texas to maintain the crucial ability to enforce its laws,” spokesman Marc Rylander said.

Speaking Rock Casino continued to operate on Friday, but it’s future is uncertain. Martinez said he would issue an injunction on gaming activity, but was still weighing its scope. “As the tribe has noted, an injunction may not simply command that a party ‘follow the law.’ Instead, an injunction must be specific and state its terms in reasonable detail. Thus, the court invites each party to submit a proposed permanent injunction for the court’s consideration by March 1, 2019. Thereafter, the court will consider the submissions, if any, and enter an injunction regarding the Tribe’s operations.”

Native American tribes across the country have long been able to offer casino gambling under a 1988 law called the Indian Gaming Regulatory Act. The Kickapoo tribe in Eagle Pass operates its Lucky Eagle Casino under that law. But courts have ruled that Texas’ two other Native American tribes, the Tiguas and the Alabama-Coushatta in East Texas, are not covered by the Indian Gaming and Regulatory Act. Instead, they’re covered by a 1987 law called the Restoration Act, which granted federal recognition to the tribes. The law prohibits the tribes from offering gaming that isn’t allowed by state law.

The Tiguas first filed suit in 1993, and the El Paso trial judge sided with the tribe. However, the 5th Circuit Court of Appeals overturned that ruling and said the Tiguas couldn’t legally offer casino games. The tribe continued to offer gaming at Speaking Rock and brought another lawsuit against the state in 1999, losing at both the trial court and appeals court. The casino closed in 2002, after raking in tens of millions of dollars that helped improve infrastructure and housing on the reservation but also caused divisions among tribal members.

After Speaking Rock closed, the Tiguas got fleeced for $4.2 million by lobbyist Jack Abramoff, who said he’d get Congress to approve casino gambling for the tribe. Federal court testimony later showed that he was also leading efforts at the same time to lobby Texas lawmakers in opposition to Tigua gaming. Abramoff spent several years in federal prison after being convicted of defrauding the Tiguas and other Native American tribes.

The injunction that led to the 2002 closure of Speaking Rock allowed the tribe to offer games that were legal in Texas, so the Tiguas soon re-opened the casino and offered a variety of slot-machine style games that they said were sweepstakes or bingo games that were compliant with state law. Paxton brought another lawsuit in 2017 that said those games, as well as big-stakes bingo games at Speaking Rock, violated state law.

A trial in the lawsuit had been set for next month, but Martinez issued a summary judgment in favor of the state on Thursday. “In sum, the Court determines that the State has shown irreparable harm because, in the absence of an injunction, the State is unable to enforce Texas’s gaming laws on the reservation as provided by the Restoration Act,” he wrote.