In California, the score is now: Drought 1, Farmers 0.

After years of shockingly dry conditions, fallow fields, freeloading salmon, and forced livestock sales, the state’s legislature has finally taken action.

On Friday, California lawmakers approved a historic measure that would regulate groundwater for the first time in state history. California was the only Western state without controls on the amount of water taken from wells. Gov. Jerry Brown is expected to sign the legislation later this month.

The legislation, which is really three separate bills, intends to limit overpumping by directing local agencies to construct their own “groundwater sustainability plans,” with fines for violations. There are also provisions for the state to usurp local plans if they continue to result in groundwater depletions after 2025. A $7.5 billion water bond, another major effort at expanding the state’s already vast water storage and delivery infrastructure, was previously agreed upon and will be placed in front of voters on the November ballot.

The measures were passed hours before the legislative session came to a close, drawing the ire of state agricultural interests, which will likely be most affected by the new rules. The contentious final votes came not along Republican-Democratic lines but a rural-urban divide, with a bipartisan contingent from the agriculturally rich Central Valley staunchly opposed. In California, farmers use more than 80 percent of the state’s water. They’re also the most productive in the nation, leading the way in growing everything from asparagus to walnuts. Farmers there deserve to get the majority of the state’s water, a resource they’ve molded into a multibillion dollar industry that feeds each of us every day. The problem is, there’s currently no real incentive to save dwindling aquifers there, as huge subsidies continue to tempt big agriculture into water-intensive crop choices. Last week’s actions by the state legislature are an attempt to change that.

Despite what essentially amounts to an unjust loss of water rights for Central Valley landowners, the bill should be celebrated. Without a legislative step of this magnitude, it’s only a matter of time before agriculture in its current form becomes impossible in California. Farmers must adapt to a future with less water, and there’s no time like the present.

Earlier this year, I wrote extensively about California water issues in a Slate series called the Thirsty West. On my drought-themed road trip, I met rancher and Tulare County Deputy Agricultural Commissioner Gavin Iacono and Central Valley almond farmer Benina Montes. This week, I spoke with both of them again by phone to gauge their initial reaction to the new regulations.

Iacono says the Central Valley has turned into an arms race of drilling for water. “It’s amazing in just my commute each day, how many well rigs I see out and around. It’s a one- to two-year wait to get a well crew in. I know people that are on a waiting list for four or five different well companies.”

According to Montes, the new rules may help make things fairer. As it is currently, he says, “If you’ve got more money, you can go deeper. It’s like, ‘Great, you win.’ ”

The drought has hit Iacono hard. This year, he sold his cattle herd because there was no hay left to feed them. Friends are starting to talk about leaving. “More and more, we’ve thought of it, too,” he says.

He’s worried—with good reason—that the drought in California may just be getting started. New research led by Cornell University calculated up to a 50 percent chance of a 35-year megadrought later this century. Lead author Toby Ault told the university’s press office that “with ongoing climate change, [the current drought in the West] is a glimpse of things to come. It’s a preview of our future.”

Said Iacono, “If that’s true, none of us will survive out here.”

Still, Iacono says he has mixed feelings on the new rules. “If they limit how much [groundwater] you can use, that will dictate what crops you can grow. It’s going to lower your property value, and potentially your ability to use the land.” He continued, “When you’re legislated out of something that’s been in your family for generations, it’s hard to stomach when you have other people telling you what you can and can’t do.”

In the meantime, farmers like Montes are flying a bit blind. Montes pumps vast quantities of water each year for her family’s almond orchard, but has taken steps to try to be as efficient as possible, using drip irrigation and organic management methods. The new legislation should help encourage more farmers to adopt water-saving practices like these.

Montes repeated a groundwater analogy she overheard at a recent Farm Bureau meeting: “Right now we have a bank account, but you don’t really know how much is there. We can’t keep making withdrawals forever.” She continued, “It’s hard, because nobody likes being told what to do, but we gotta protect it.”