Terrance Dicks, who beginning in 1964 edited, wrote or co-wrote scores of episodes of the long-running British science-fiction series “Doctor Who” and helped establish some of its core elements, died on Aug. 29 in London. He was 84 .

The BBC, which broadcasts the current incarnation of the show, posted news of his death on its website. The cause was not given.

Mr. Dicks came to “Doctor Who,” which involves the time- and space-traveling adventures of an extraterrestrial being called the Doctor , about five years after it began.

He was freelancing after writing briefly for the British soap opera “Crossroads” when he was recruited as a script editor by Derrick Sherwin , whom he had met on “Crossroads” and who was a script editor on “Doctor Who.”