SPOILER ALERT: Do not read if you have not watched “Star Trek: Discovery” episode 13, “What’s Past is Prologue.”

Since his first appearance in the third episode of “Star Trek: Discovery,” Jason Isaacs’ Capt. Gabriel Lorca has been up to something. One doesn’t keep a menageries of deadly aliens, sleep with a superior officer then leave her captive on an enemy ship, and use all that Visine without some sort of nefarious endgame in mind.

In Sunday’s episode, “What’s Past is Prologue,” viewers saw that endgame play out and almost break in Lorca’s favor. But a sword through the back spoiled any chance that Lorca, revealed a week earlier to be a Mirror Universe doppelganger who secretly claimed the identity of his prime-universe counterpart, had of claiming the throne of the Terran Empire — and of continuing to live. Isaacs spoke to Variety about the dramatic demise of Discovery’s captain.

When did you first learn about Lorca’s true origin?

When I took the job. I knew everything before we started. There was some idea of him being from the mirror world, and I said, “Okay, what’s his plan?” And they said “We’re not exactly sure. And I said, “When we’re really sure what he wants to do and why he’s doing it, then I’m in.” And we all huddled together and came up with a plan and pretty much stuck to it, and then I had something to do all season. It was incredibly delicious for me to get to drop these little Easter eggs and hints.

Was Lorca always trying to get back to the Mirror Universe or did he ever think of carving out a place in the world he found himself in?

Not for a nanosecond. It was always about what could he do to get back. He didn’t know how he got there [to the prime universe]. It was an accident, an anomaly. He’s needed to find some sort of methodology [to return home], and that’s what the spore drive gave him, so that’s why he was pushing so hard for that. And he knew that even if he got back to that world, it was full of Georgiou and her troops, so he needed some way in. Burnham was going to be his in.

Was his interest in Burnham just to use her as a tool to get to Georgiou or was it that he was attracted to her?

It’s twofold. It was 99% “She is the tool by which I will pry open the locked doors and gain access to the Emperor.” Without Burnham, he would just be killed if he reappeared. So he needed Burnham. And not only did he need her, he needed to win her over and make her feel like he was her best friend in the world and her confessor and she could trust him and possibly have faith in him beyond any of her training. And at the same time, in the back of his head, less important, was the idea that if he could gain the throne, she might rule alongside him.

Lorca is revealed to be someone who is pretty racist …

That’s absolutely right. The Terran world, unlike the original incarnations of the Mirror Universe where they were just a kind of one-dimensional evil, this is a world that is not very far from our very own. We could all wake up and be mirror versions of ourselves any day. It’s a very Darwinian world, and a world that from Lorca’s point of view and for millions of people with his point of view, where assimilation is a bad thing and there’s a natural hierarchy of racists. To disrespect that is to sow chaos and anarchy, and lying is a perfectly reasonable technique to get what you want. Sadly, I don’t think we need to look very far to find those these reflected in our headlines every day.

Was it important to you that his thinking be rooted in something and that he not just be a mustache-twirling villain?

Yeah, I wouldn’t have taken the job. But luckily it was important to everyone. I had no interest in playing a mustache-twirling villain and they had no interest in creating one. When we got to the mirror world, it was very important to me that the dialogue feel like it was in many ways ripped from the headlines. It’s no coincidence that I’m exhorting my followers to make the Empire great again.

‘Star Trek’ has always had a socially progressive element to it. Were you surprised or pleased as the season played out to see just how much the the writers dug in on fairly complicated ideas about racism?

One of the great skills of the writers is that it’s never about those things. It’s about the plot. Incidentally you’re looking at a fully ethnically inclusive crew and gay couples and straight couples. It’s a future which is inclusive. But that’s never front and center in the story. What surprised me, given that I know the huge, incredibly welcoming reception that the show’s had from “Star Trek” fans, is the people who, online at least, pretended to be “Star Trek” fans to attack it on racist lines. People would be coming out from where they should be hiding in the shadows to say the most racist things, all sorts of white supremacists and haters, feigning the mask of “Star Trek” supporters, attacking it for the very things that “Star Trek” has always stood for — which makes them look, frankly, ridiculous.

Practically, for Lorca, who is someone who has presumably eaten Kelpians before and is now serving alongside one …

I have to tell you, they’re delicious. I like them raw.

… how uncomfortable does that make him?

The question I had is, ‘Am I getting affected by these people around me? At any point would I be sentimentally attached to them? He’s still human and he’s still forming real relationships. But he has these beliefs in a hierarchy, a strict kind of totem-pole, and he knows that, as far as he’s concerned, he’s higher up. He’s like those people who say “I’m not racist, I have a black friend,” or, “I’m not a homophobe, there’s that gay guy in accounts.” He has a view of the world that to me is repulsive but to him is consistent. He’s perfectly able to incorporate the complexity of, “You know, Saru’s a good officer, but when it comes to it, I’d grill him. Or maybe I’d fry him with some garlic.”

Did you have a favorite scene or favorite moment from shooting this season?

Any time you’re on the bridge, all my favorite people are there. There’s the audience’s experience and there’s the actor’s experience. My experience was that I made some very good friends, people I adored — people of all ages, people who had just left Juilliard and people who have been around forever. We all bonded in ways that I didn’t expect. So I liked it when we were all together, and we were all together on the bridge. And fighting Michelle Yeoh. Who wouldn’t want to fight one of the great martial arts legends of all time? I say “fighting,” but I mean trying desperately to keep up with a woman who can move a thousand times quicker than me as I’m slogging through like some drunken hippo.

This being “Star Trek,” there are any number of ways that we could see you return. Would you come back and do the show again if asked?

I said yes to a fantastic story. You never quite know with television because it’s written week by week. I thought the writers really delivered a fabulous, interesting story, and for me as an actor, I had just a banquet every scene. If they came up with a great story, I would be all ears.