Andy Weir has second-book syndrome.

Specifically, the pressure of writing your sophomore novel after your first novel, “The Martian,” was turned into a blockbuster film starring Matt Damon.

“It’s stressful,” Weir says. “Of course, got the impostor complex. A success like ‘The Martian’ is something a writer will get once in their life, if they’re lucky. I got mine right out of the gate. So I have to set realistic expectations. There’s a good chance that I will never again write a book that does as well as ‘The Martian.’ I just have to accept that.”

His new book, “Artemis,” should please fans of his first book. While “The Martian” followed stranded astronaut Mark Watney as he struggled to survive on Mars, his new book is set on the moon, in the first — and only — city, Artemis. The lead here is Jazz Bashara, a 20-something woman, a porter and sometime smuggler who gets caught up in a big crime.

It’s a fun page-turner which should appeal to fans of sci-fi, not to mention anyone who digs a good caper.

“I made what I considered to be a very good story,” Weir says. “And so I’m confident that I’ve done my best. Now it remains to be seen if my best is good enough. So we’ll find out. And of course I’m nervous. I found that the northwest corner of my office is the best one to huddle up and cry in. But sometimes the southwest corner gets good light in the morning, so it’s a tossup.”

amNewYork spoke with Weir about the book.

What makes Jazz tick?

It’s interesting. Inevitably everyone will compare “Artemis” to “The Martian.” So Mark Watney is the idealized version of me. He’s based on me. He’s my snarky, smartass personality. He has all the qualities of myself that I admire and none of my many, many, many flaws. He’s what I wish I were. Jazz is a little bit more like what I actually am: A little shady at times, flawed, doesn’t always make the right decisions, has regrets. She’s a little bit more like the real me. And that’s what I kind of based her on. A lot of that stuff is just pulled from my past. Not the crime stuff, but the, you know, not the remotely living up to her potential and stuff like that. And when I was her age — when I was in my 20s — I was a complete [expletive] up. I mean, so is she. So she’s a very flawed character and this was part of a very deliberate scheme on my part.

How so?

I want to grow. So “The Martian” was very popular, but no one would accuse it of being literature. I mean, Mark Watney has no depth. The only thing that you really know about Mark is [he is] a guy who didn’t want to die. It’s like, “OK. Well, I think most of us have that trait.” Jazz is much more of a nuisance. She’s like I said, very flawed. She has regrets in her life. She’s made bad decisions. Most of the problems that happen in the book are a result of her bad decisions, as opposed to Mark who was just like set upon by bad luck, right? . . . So I’m trying to get more character depth, I guess, I’m trying to make more realistic characters.

How did you get into the mindset of Jazz, a Saudi woman living on the moon?

On the first half of that question, she’s basically the darker parts of me. As for getting into the mind of a female lead, well, there’s a lot of complexity of it. First off: massive insecurity about that as well. You might ask, “Well, why did you make a female, if you didn’t feel super comfortable with it?” And the answer is because the version of “Artemis” you’re reading right now was actually the third completely different story I came up with. So the sequence of events for “Artemis” was first I designed the city. I came up with all the science, the technology, even the economics of the city — all those details. And then I, like I had a whole city designed and everything before I made the first characters or plot ideas. I’m like, “OK. Here’s the city.” Now Artemis, to me in my mind, was like as real as Chicago.

So the first story I came up with, Jazz was in it, but she was this very, very tertiary character. . . . I just needed a likable smuggler type just for, like, three scenes. So I created Jazz out of whole cloth. I was like, “All right. What’s a country I haven’t used yet?” I’m like, “Saudi Arabia. All right, the smuggler is Saudi. And let’s make her a woman, just because.”

I realized that Jazz was a fairly interesting character. And I’m like, “Well, what about a caper takes place on the moon. I can see that working.” And that was the genesis of “Artemis.” And by that time, I had very much spent so much time kind of defining Jazz in little snippets and chunks here and there that she very much cemented in my mind as a Saudi woman. So I’m like, “All right! I’m going to write a first-person narration by a Saudi woman. Well.” First off, on the culture-front of things, like her Saudi culture. She doesn’t have much of that. She’s much more Artemis culture and I get to define what that is. So that itself wasn’t a problem. But, of course, I’m not a woman. However intellectually equal we may be, men and women still look at things differently and I, you know, I struggled with that. I also had no idea where I was going. Interplanetary orbital dynamics is really easy compared to understanding how women think. So what I did was I just tried to run it by as many women as I could.

You’re in California and have a fear of flying. How are you getting to New York?

Valium. Yeah. Big handfuls of Valium. Popping them like Pez. By the way, just for the record, prescribed by a doctor. Not from some guy on the corner. But yeah, no, I’m getting better at it. But I still definitely need the Valium for the flight itself.

What does it mean to you to know your event will be on the Intrepid?

It’s pretty awesome. That’s going to be really cool. I’m looking forward to being there. I’m not looking forward to going there, you know what I mean? And also it will be cool because I’ve literally never been to New York City before. I’m not going to have time to do anything fun. It’s just going to be event, event, event, leave. But I am going to finally get to meet a lot of the people at Random House who have been working tirelessly on my behalf and say thank you and shake their hands and stuff like that.

“Artemis” has already been optioned. What can you reveal about that?

Well, 20th Century Fox bought the movie rights. Not just optioned, but bought outright. So that’s cool. That shows a certain amount of commitment on their part. And they’ve attached Chris Miller and Phil Lord. . . . They are attached to direct. I assume that what they’re doing right now — I’m not an insider, right — but I assume what they’re doing right now is looking into screenplay writers to adapt the book into a screenplay. Also . . . I’m sure nobody at Fox would say this to me, my guess is they’re going to kick back and see how well the book is received. Because if you’re going to dump a huge pile of money into a movie production, you want to make sure people like the story first.

Rosario Dawson is doing the audio book. How does her voice fit into the voice in your head?

It works really well, I mean, because she’s, you know, an actress. So she’s good at her stuff. Yeah, no, it fit really well. Of course it’s kind of hard for me not to see Rosario Dawson when I hear her voice because I watch all the Marvel Netflix stuff. So I’m really familiar with her voice and what she looks like. But still even, if I’m imagining her as Jazz it works out pretty well.

What other projects are you working on?

Right now? Sure. I mean right now I’m kind of half-assedly working — I mean it’s just slowly — working on a story, a sequel to “Artemis.” But I’m trying not to get too deep into it until I find out how well “Artemis” is received. But it’s not a direct sequel. It’s a different character, same city. I really love a commonly shared setting among many different groups of characters because it really makes that setting feel tangible and believable.