By Laura Haefeli

VALLEY SPRINGS (CBS13) — Detectives are investigating after an intruder was shot and killed after he broke into a Valley Springs home and started attacking people inside.

The Calaveras County Sheriff’s Office says Sunday’s deadly incident appears to stem from the suspect, 28-year-old Lennin Elizalde, wrongfully believing that he owned the home.

READ MORE: VIDEO: Yosemite Falls Flows Again After Bomb Cyclone-Fueled Atmospheric River

Deputies say the rightful homeowners had bought the 7000 block of Gabor Street property from a real estate company recently. However, during the moving process, the owners came home one day and found that someone had broken in through a side door – and Elizalde was inside.

Elizalde was the son of the previous owner of the home. He was ordered to leave after the new owners found him inside, but he refused until 911 was called.

The new owners say Elizalde threatened to return. Deputies later found and arrested Elizalde, who didn’t deny that he went into the home but claimed someone else had broken the door.

A deputy says Elizalde also told him that he believed he still owned the home and he intended to come back. This statement prompted the deputy to ask for a bail enhancement that would keep him in custody, but the sheriff’s office says the judge denied that enhancement.

The judge denied deputies request to keep Elizade behind bars and released the suspect Saturday evening on misdemeanor charges.

Only six hours later, Elizade was breaking down the door to the same residence.

“Suspect kicks in the front door, starts assaulting the male in the front room,” Lt. Greg Stark said.

During the chaos, deputies say one of the rightful occupants then shot Elizalde in self-defense.

Elizalde was pronounced dead at the scene by medics.

READ MORE: 1 Person Killed In Apparent High-Speed Crash On Elverta Road Near Gibson Ranch

The two homeowners were taken to a local hospital and treated for injuries. They are expected to recover. Neither is facing charges.

The big city crime in the small community of Valley Springs had neighbors reeling.

“Typically, we don’t have much crime out here,” said Lonny Bubak, who lives on Gabor Street.

Now, Bubak is locking his doors after the brazen break-in.

The sheriff’s office says the home was vacant when it was legally bought by the new owners, with Elizalde not having any personal items inside or any other legal reason to return.

None of the rightful occupants have been arrested or cited, deputies say.

We asked Law Professor John Myers about the judge’s role in the home invasion and the shooting.

“A judge who is deciding a case has absolute immunity from any kind of civil liability,” Myers said.

Absolute immunity means no matter what decision a judge makes while performing judicial acts, they are protected from lawsuits.

MORE NEWS: 'When I Finally Got To Be Elvira, That's When My Life Calmed Down': Mistress Of The Dark Peels Back The Curtain

“If the sheriff is doing all the deputies can to keep someone who’s a danger in confinement and the judge overrules them, there’s nothing they can do about that,” Myers said.