SHELTER COVE, Calif. – Fantasy often mixes with reality in the work life of Deputy Sheriff Robert Hamilton of Humboldt County, the center of California’s marijuana outback.

It happened again a few months ago in the isolated coastal resort of Shelter Cove, where Hamilton lives and patrols. The deputy came upon nine young men tending a marijuana plantation.

They said they’d come from Maryland, Pennsylvania, Oregon, Washington and Ohio. They’d rented a few apartments, then bought a half-acre of hillside. They clear-cut the land, put in “No Trespassing” signs and a couple of greenhouses, and terraced the rest of the property for farming.

They were raising 200 marijuana plants, each of which could produce 2 to 4 pounds of weed.

One of the men, Jake Berlingeri, said the pot was for their own medicinal use. He recited the ailments afflicting these strapping men in their 20s.

“Well, Matt, he’s got insomnia. I got shoulder problems, a torn rotator cuff,” Berlingeri said. “Those two, they’re not patients. But my boy Trav, he’s got “

Hamilton smiled wryly and looked at the plants, labeled for their varieties: Headband, Mr. Nice, L.A. Confidential, Blue Dream, Amnesia, Purple Diesel, Ice Queen, Grapefruit, Blueberry and Sour Diesel.

He spent 13 years as a cop in Fresno, Calif., where mere possession of marijuana could lead to a felony arrest. But on this day, he made no arrests. Instead, he accepted a root beer from the growers and told them to display their medical marijuana prescriptions where he could see them. That way they’d have no problems with him.

“I’m a realist,” Hamilton said as he drove away. “I know how this is working. It does no good to rip all these plants out or nitpick on fine details when nothing’s going to happen.”

In a region where marijuana is not merely tolerated but is a pillar of the economy, there isn’t much a deputy can do but play along with the fantasies that surround semi-legal weed: that unemployed 20-somethings who buy $50,000 trucks earned the money legally; that supply shops for marijuana farmers are innocent home-and-garden centers; that growers who flash medical marijuana cards are not producing for sale but solely for their own medical needs.

“Cheech and Chong cannot smoke that much dope,” Hamilton said.

To work in law enforcement in California pot country is to come face to face every day with the state’s conflicted attitudes toward cannabis.

Humboldt County District Attorney Paul Gallegos supports legalization of pot, and law enforcement officials say the office rarely prosecutes small-scale growers, who form a large and active political base here.

Nor can Hamilton or his fellow deputies do much about the thousands of unpermitted structures, essential to hiding indoor marijuana plants, that dot Humboldt County like buckshot.

A proposition on Tuesday’s ballot would make it legal for people 21 and older to grow and use small amounts of marijuana, and it would allow California cities and counties to regulate and tax commercial cultivation. The boundary between legal and illegal weed would depend to a large degree on policies set by local governments.

A promise by U.S. Attorney General Eric Holder to enforce federal laws against recreational marijuana, even if the proposition passes, further complicates the picture.

So most likely Hamilton, 48, will continue to work in a gray zone.

A year into his assignment as Shelter Cove’s live-in deputy, he is fed up with the ambiguity: “I wish they would totally ban it — zero tolerance — or just make it totally legal.”

The resort was established in 1964 as a place for vacationers and retirees to build second homes on breathtaking coastline accessible by a single, winding two-lane road.

Over the years, marijuana farming came to Humboldt, first as a countercultural statement, then as a business. Shelter Cove was isolated, with minimal police presence, which made it attractive to growers. the time Hamilton arrived in the fall of 2009, the place had become a concentrate of California’s weird weed world.

Pot growers occupied about half of the nearly 600 houses. Young growers drew the blinds and raised marijuana beneath 1,000-watt lights. Others put in greenhouses on denuded patches of hillside. Some installed sensors and hidden cameras to detect intruders.

When they raided large indoor operations, deputies often found photographs of the growers vacationing in places like Costa Rica and Bali.

“There’s this outlaw mentality,” Hamilton said. “They think they’re these drug lords and they’re going to take over southern Humboldt. You see them driving $40,000, $50,000 vehicles, and they have no jobs.”

Residents say indoor growing also brought a lawless feel to the cove: nighttime gunfire; planes landing and taking off in darkness from the resort’s airstrip; late-night parties; trashed rental housing; truck races along Upper and Lower Pacific drives.

“It was the wild, wild West,” said Roger Boedecker, a member of the Shelter Cove Resort Improvement District board of directors. “The DA’s office is reputed not to be inclined to prosecute small growers. You can grow with impunity.”

The indoor marijuana boom split Shelter Cove between younger growers, most of them renters, and older retirees, some of whom desperately hope for pot’s legalization, believing it will drain the profits from illegal cultivation.

This was the situation Hamilton found when he arrived. He began by ticketing people for dilapidated trailers, for growing pot on land where they didn’t live, which is against state law, or for living on land without a septic system. But Hamilton said the county’s building department objected, saying he was doing its job, one he wasn’t trained for.

Far from policy debates, Hamilton navigates the roads, armed with skepticism and a smile. Deputies in other counties may have broad citizen support. In marijuana country, he finds, it depends.

“You’ve got half the community that doesn’t want it, and the other half that does,” Hamilton said.