Terry Gilliam was surprised that Sir Sean Connery agreed to star in 'Time Bandits'.

The late 'James Bond' star appeared as Agamemnon in Terry's 1981 fantasy adventure movie but the filmmaker confessed that he and co-writer Sir Michael Palin never expected him to board the project.

He recalled to SFX magazine: "We put in into the script, 'And the Greek warrior removes his helmet, revealing himself to be Sean Connery or an actor of equal – but cheaper! – stature. Neither me or Michael imagined that he'd want to be in it."

The 80-year-old filmmaker continued: "We caught Sean when he was in an interesting mood. He liked the idea of Agamemnon being a surrogate father to Kevin (Craig Warnock).

"I got the sense that he maybe had a bit of guilt about sidelining his own children when he was off being James Bond and roaming the world."

Terry recalled how Sean – who passed away last year aged 90 – helped the crew complete filming in unbearable heat in Morocco.

He said: "During the first day, we were on top of this plateau above Ait Benhaddou and it was 135 degrees (57 degrees C).

"It was unbearable and horrible. Our stomachs were all a bit wobbly too. We got through it – and in no small part due to Sean. He was the experienced one in the bunch."

Terry revealed that he is grateful that people still talk to him about 'Time Bandits', four decades after it was released.

He said: "Fairy tales have always been central to the way I look at the world. They are all moral tales, in one form or another. That's really what I wanted to create here.

"I love the fact that people who are 40 or 50 years old tell me that the film had an effect on them. That's all I've ever wanted, really."