Screenwriter Terence Winter, who last week was nominated for an Academy Award for Best Adapted Screenplay for his work on Martin Scorsese's "The Wolf of Wall Street," was just as confused by some of the reactions to his film as Leonardo DiCaprio was toward the end of the year. The hedonistic depiction of Wall Street excess had led some to question its moral standing, surmising that it seemed to take far too much delight in its depictions.

But that thin line is also partly the point. It's a film that shows you a good time and dares you to have fun with it, because it's a display of antics that appeal to base, primal desires in many ways. That having been said, the idea that anyone would take away from it the idea that it was meant to be a glorification was "sort of a head-scratcher" for Winter, he says. "You'd think it would go without saying, but anyone who would watch that behavior and want to emulate what's going on on screen has got a screw loose as far as I'm concerned."

But as Scorsese himself has noted in his rounds with the press, the devil often comes with a smile. And it was therefore very much by design that the viewer was to be fished in by these antics. "We talked about the idea that we never, ever see the people on the other end of the telephone," Winter says. "You never see the people who are being duped by this stuff, so you as the audience are sort of taking the place of those people. You're going along for the ride and you're sort of seduced by the fun and the bad behavior, and then when it turns dark toward the end, you go, 'Oh my God. I've been actually cheering this guy on this whole time.' You're kind of taking the place of the people on the other end of the phone, in a way. We wanted to let Jordan [Belfort] sell you his story."

Belfort's novel was a vast tome. At 528 pages, if Winter was going to give you the whole thing, "it would have been an 18-hour movie" (though it certainly isn't a swift affair as is). Whenever Winter — who is the showrunner of HBO's "Boardwalk Empire" — sits down to adapt something, he tends to circle the things he's interested in. By the time he had finished "The Wolf of Wall Street," however, he had virtually circled the entire book. "It was like, 'Okay, great, now what,'" he says. "But like any crime story, it's sort of the rise and fall, so you had to find that throughline. The rise and fall of Jordan Belfort."

Winter met with Scorsese and DiCaprio every day for six weeks in the lead-up to production before he went off to work on the third season of "Boardwalk Empire." So he wasn't on set much at all. There was, however, a lot of improvisation going on, which is a huge reason for the film's extended post-production schedule, as Scorsese and his editor, Thelma Schoonmaker, shaved the material down.

"Hours and hours of the improvisation didn't get into the movie," Winter says. "But all of the improvs came from scenes that were written. So it was all kind of riffing on what was already there. For me, that's where the magic is sometimes. You can't be that precious about your words that you can't be willing to explore an alternative or an addition, especially when you get actors like that, Leo and Jonah, who are so good at improv. Those guys are really great at this. And Jonah is also a really talented writer in his own right. You're going to get some great stuff."

Indeed, and the result was five nominations for the film. Pity that Schoonmaker's task in the editing suite didn't gain recognition, but Winter is truly delighted to have received his first-ever Oscar notice from his fellow writers.

"It's really the highest praise one can ask for in any business, to think that people who do the same thing that you do think you did a great job," he says. "And the films that were out this year, it was such an incredible year for film, so it's even more meaningful."

"The Wolf of Wall Street" is now playing at a theater near you.