Seth MacFarlane might have the darkest sense of humor on network television. After 188 episodes (and counting) of his animated stalwart, Family Guy, viewers have become accustomed to savage beatings, shaken-baby syndrome, and sex trafficking, among other unpleasantries—all played for laughs.

We shouldn’t be surprised, then, that Ted, MacFarlane’s big-screen debut out on June 29, involves a weed-smoking, feel-copping, talking teddy bear. (Nor should we be surprised that MacFarlane, who performs five regular roles on Family Guy, voices Ted.) But he’s not stopping there; next year he’s bringing back Carl Sagan’s classic PBS science series Cosmos, hosted by Neil deGrasse Tyson. Thankfully, the writer/voice actor/director/producer/teddy bear was all too happy to show us his dark side.

Wired: Ted stars Mark Wahlberg and Mila Kunis are no strangers to off-color material, but you can’t just turn them into human versions of the Griffins. How did you give your usually R-rated comedy a real-life core?

Seth MacFarlane: There are episodes of Family Guy—notoriously—that exist completely to service the comedy, and story be damned. Ted was an instance where the story came first. We constructed it as a romantic comedy and tried to ignore the fact that one of the characters was a teddy bear. We have an early version that was a little heavy on raunchy jokes, but by the end of test screenings we were able to find a balance.

Wired: You donned the motion-capture suit to “play” Ted. Why not animate the bear?

MacFarlane: Even the best animator in the world isn’t going to capture the subtlety of human movements. The stiffness drives me nuts.

Wired: Ted is a pretty physical role. There’s even a fight scene with Wahlberg.

MacFarlane: The fight scene was not motion-capture, actually. It was animated fairly traditionally.

Wired: How about when Ted rips bong hits?

MacFarlane: That was motion-capture. I got high on set.

Wired: How did the production of Ted affect Family Guy?

MacFarlane: On American Dad, I’ve been distant from writing it for years. I had to do this with Family Guy as well. Luckily, by this point in the series—more than 10 years in—if I can’t do that, something’s wrong.

Wired: How has Family Guy’s battle with censors evolved over those 10 years?

MacFarlane: The Janet Jackson incident at the Super Bowl created fallout that we’re still experiencing, and the day-to-day manifestation of that is we can’t do as many shit jokes.

Wired: And now you’re updating Cosmos, to be hosted by Neil deGrasse Tyson—that’s pretty much a 180 from shit jokes.

MacFarlane: I’m dismayed at the rejection of science that’s reemerging in America. There’s nothing out there that glamorizes science the way Cosmos did.

Wired: Science has become politicized.

MacFarlane: It’s absurd. Neil made a great comment on Bill Maher’s show: “The good thing about science is it’s true whether or not you believe in it.” Science doesn’t care if you’re a Democrat or a Republican. It just is.