"I didn't sleep properly last night," says Richard Madden, drinking a pint at his local. "I'm thinking it's because I knew I was going to have to talk about this."

"This" is an event that concerns Madden's character in the HBO series Game of Thrones. If you're not fully up to date with the show, scram. This is your spoiler alert. In an episode watched by half a million UK viewers on Sky Atlantic in June, Madden was killed off savagely and with so little warning that some (honestly, there's video proof) leapt off their sofas.

It's a question, really, for George RR Martin, the American author whose novels have been adapted by HBO. Martin's fiction takes place in a cruel, medieval-like world, where murder is commonplace. The author seems to revel in it, killing off popular, morally spotless characters knowing his readers (with their soppy, modern notions of fairness) won't see it coming.

What it all means for those cast in the TV version is that when new episodes are hacked out of Martin's long books, and scripts are distributed, "you get a lot of terrified actors," says Madden, "tearing through the pages going 'Do I die? Do I die?!'"

Madden, 27, who grew up in Elderslie, Renfrewshire, 15 miles from Glasgow, knew his character was doomed from the outset. He had worked in theatre (Romeo at the Globe) before being cast as Thrones' youthful lordling, Robb Stark, in 2009. Senior producers admitted to Madden, early, that they couldn't wait to get to the filming of his slaying. And on his first day on set, crew and cast approached, asking, "My God, do you know how you're going to die?"

He managed to stay ignorant of the details for a few years. "I made a deliberate effort not to read ahead." Madden's girlfriend is the Doctor Who actor Jenna Coleman, so theirs is a household well practised in spoiler containment. One night, though, Madden risked a Google search …

There have been some wild murders in Thrones to date. Characters portrayed by Sean Bean (executed on the orders of a pre-teen) and Harry Lloyd (scorched with molten gold) spring to mind. Neither carried quite the emotional whack of Madden's departure. In the company of Michelle Fairley (playing his mother) and Oona Chaplin (as his wife) Madden's Robb was waylaid during a marriage ceremony. The event is known to fans as "the Red Wedding" because – well, Robb's wife was knifed in the belly, his mother had her throat slit, and Robb was riddled with crossbow shafts. Then stabbed. Then beheaded.

It was a tense few days' filming, Madden says. "I've still got it in my chest, while we talk about it, the feeling that something terrible is going to happen." When he tells me about his final bit of dialogue with Fairley, he even gets a little emotional, and has to glare at his pint glass for a minute. Madden got close to the actors portraying his family. "I spent six months a year with these people. I saw my on-screen mother more than I saw my actual mother. So it was personal.

"The logical part of me says, it's just a job. But the emotional part of me is tied in. And, you know, in a lot of ways it was like a real death. It was a death of a younger part of me. It was a death of a character I've played for five years. It was a death, if not of friendships [with cast mates], of being able to see those friends regularly."

He'll watch Game of Thrones, from now on, as a cheerfully clueless fan, "with total surprise and joy", and meanwhile get on with other work. He has brought a thick, pink script to the pub to revise his lines for Cinderella, a new live-action Disney film in which he plays Prince Charming. Madden's hair has just been straightened, for extra charming-ness.

Before I leave him to his script, we discuss a curious brush he had with infamy, a couple of months ago, when MailOnline ran a story about him sitting with his legs too far apart on public transport. ("I did what?" he said to his agent, when told there was a negative story brewing.) To precis the inane affair, a picture of Madden on the tube had been posted to a blog called Men Taking Up Too Much Space on the Train, and when he was recognised as the guy off Game of Thrones, various newspapers (including this one) wrote it up. The Mail and the Sun were particularly unkind. "'Castrate him", I think, was the headline," says Madden, who still looks a bit baffled and hurt.

Poor guy. Crossbowed, stabbed, beheaded. Then he steps out of barbaric fantasy fiction to find a national newspaper calling for his bits.