A federal appeals court ordered a district court to reexamine a case in which a West Virginia prison inmate accused state prison officials of invading his privacy by surgically removing marbles he had implanted in his penis.

The 4th U.S. Circuit Court of Appeals, which is based in Richmond, Va., ruled Tuesday that Adrian King could continue to pursue claims that officials at Huttonsville Correctional Center illegally threatened him into consenting to the surgery to remove the marbles. King risked being segregated from other inmates and could have lost his eligibility for parole if he denied the surgery, according to King.

King had the marbles implanted in November 2008. In 2013, another inmate reported the marbles. Prison officials then determined the marbles qualified as contraband and would need to be removed, because they were a security threat.

In January 2013, King saw a doctor at Ruby Memorial Hospital, who would not remove the marbles without King’s permission. King went back to prison with the marbles still in his penis, where he claims Deputy Warden Grover Rosencrance said, “Get comfortable you stupid son of a b****, you’ll be placed in administrative segregation until you do as I say and have those marbles removed.”

On June 19, 2013, King consented to the surgery due to “threats of continued segregation and other adverse actions.” King said since the surgery, he has experienced tingling, numbness, and pain when his penis is touched or when it rains, snows, or gets cold. He also said prison officials now call him “Marble Man” and ask while searching him where his marbles are, which has resulted in mental and emotional anguish, according to court documents.

The appellate court’s decision allows King to continue with claims that his Fourth Amendment right against illegal searches and seizure, Eighth Amendment protection against cruel and unusual punishment, and 14th Amendment guarantee of equal protection were violated. In February 2015, Chief Judge Gina Groh of the federal court in Martinsburg ruled that those rights were not violated, but the appellate court returned the case to her for further proceedings.

King is seeking compensatory and punitive damages.