TV

How George R.R. Martin got his ‘Game’ on

The scene is 1950s New York City — but the view is from the New Jersey side, in gritty, hardscrabble Bayonne, where a longshoreman’s young son gazes longingly from his bedroom window in a federal housing project and dreams of faraway places like China, Africa and Mars.

That boy is George Raymond Richard Martin, and he will grow up one day to create the blockbuster “Game of Thrones” franchise.

Mega-author George R.R. Martin’s fans are desperate — five novels and four HBO TV seasons into the series — to know how the upheaval in the land of the Seven Kingdoms will play out.

If they’re hoping for revelations in Martin’s lushly illustrated new book, “The World of Ice & Fire: The Untold History of Westeros and the Game of Thrones” (Bantam), out Oct. 28, they may be disappointed by the lack of spoilers.

However, in an interview with The Post, the 66-year-old author gets a little more personal.

View this post on Instagram

Peter and George R. R. Martin

A post shared by Peter Dinklage (@peterdinklage) on

For Martin, the real story of Westeros arguably begins not at the Narrow Sea, but back on that night in Hudson County, looking out over the Kill Van Kull separating New York and New Jersey.

“I would look at all these big freighters going by and I would see all the flags. I had an encyclopedia and I’d look up the flags from Sweden or Liberia or China … and I would dream about what it was like to visit those places,” says Martin, who adds that his life played out in “a five-block world” in Bayonne, between the Mary Jane Donohoe School on Avenue A and his home on East First Street in the LaTourette Gardens housing project.

George R.R. Martin studied journalism at Northwestern University.Courtesy of George R.R. Martin

While New York City — Staten Island, at least — was visible from the window, a visit to the Big Apple was a rare childhood treat for the author, whose family had little money and no car.

“I would get into New York maybe once a year. We would come in at Christmas and see the show at Radio City Music Hall, and once or twice my parents would maybe take me to see Santa Claus at Macy’s, which was always a thrill,” says Martin, on the phone from his Santa Fe, New Mexico, home. “We would eat at a Horn & Hardart automat.”

Martin lived in Bayonne for 18 years until he attended Northwestern University near Chicago, majoring in journalism.

As a conscientious objector during the Vietnam War, Martin did alternative service with the domestic Peace Corps.

When asked to reconcile his antiwar stance with the violence in “Game of Thrones,” he explains: “If by not writing about violence I could abolish violence, I would gladly do so, but I don’t think you make any progress toward a better world by turning your face away from it.”

“War is an important subject and it’s the center of all of the great fantasy epics — certainly ‘Lord of the Rings’ is all about war.”

After a stint teaching journalism in Iowa, Martin elected to move to Hollywood and pursue his dream of becoming a professional writer, working as a story editor for “The Twilight Zone” and then on “Beauty and the Beast” at CBS.

These days Martin is surrounded by babes, like “Thrones” stars Emilia Clarke (left) and Rose Leslie.Michael Buckner/Getty Images

It was 1996 when he published the first “Game of Thrones” novel, marrying his love for what he calls “the big stories in history” with his expertise in fantasy and sci-fi.

The novels and the series are very loosely based on England’s War of the Roses, but Martin advises his readers not to take that story too literally.

“I don’t want to just take a character from history and change his name. I take a bit of this character and a bit of that character and a bit of a third … and then I add some entirely imaginative elements and twist some things around,” he says.

Martin is currently at work on the sixth book, “Winds of Winter,” in the planned seven-book epic. But obsessive fans can’t wait to learn how the series concludes, and particularly about the details of hero Jon Snow’s mysterious parentage.

“I’ve not finished ‘The Winds of Winter’ yet, so maybe in that book, but if not then definitely in the next book,” he says of the Snow revelation.

https://twitter.com/GRRMspeaking/status/499211429179060224/photo/1

But it isn’t Jon Snow that’s exciting Martin right now. It’s his new history book.

“I grew up reading beautifully illustrated books like ‘The Tales of King Arthur’ that you could get in the 1950s and other ages,” Martin enthuses. “I’ve always loved illustrated books.”

Is he sure he doesn’t want to tell us Jon Snow’s secrets? “No, I really am not going to tell a reporter,” he laughs.

Like his most cunning characters on “Thrones,” Martin knows it’s best to trust no one.

George R.R. Martin will speak at the 92nd Street Y on Sunday at 8 p.m. The event will be streamed live; 92Y.org/livecast.