After some seven years on “Beverly Hills, 90210,” and a current Broadway stint in “The Rocky Horror Show,” Luke Perry has learned how to deal with all kinds of pests (Shannen Doherty, for one). Such training must have come in handy on his latest project, Fox’s summer paranormal-inspired anthology series “Night Visions,” reports PEOPLE. For his role as a psychiatrist who channels his patients’ afflictions in an episode set to air July 26, Perry, 34, imagines what it’s like for an anorexic to confront a big banquet — as a sumptuous food spread transforms itself into a disgusting, bug-infested vision. Still, imagining is one thing; shooting the scene is another. As about 50 members of the cast and crew looked on, Perry — seated at a table crawling with mealworms and maggots — bit into an insect-ridden ear of corn and started chewing . . . kernels and varmints alike. The room went silent as Perry chewed away, then erupted into groans the moment the director yelled cut more than 30 seconds later. Perry then repeated the scene four more times — rinsing his mouth out with whiskey between each take.