In the Marvel movie universe, a straight white guy has played some part in saving the world 20 times in the past nine years. With The Amazing Spiderman 2 opening today, we're up to 21. On the pages of Marvel's comic books though, a different story is unfolding.

The company has, in the last few months, been aggressive in giving women and minority superheroes starring roles. That means solo books for heroes like Captain Marvel, She-Hulk, and Black Widow; the launch and re-imagining of the Ms. Marvel as a teenage Muslim-American girl; an all-female X-Men title; a new solo series for Storm; and perhaps most excitingly, the formation of The Ultimates, a superhero team comprised of women and minorities:

These writers are proving that there's more to the comics world than straight white dudes saving ladies (and the world too, for good measure). I talked to a couple of Marvel writers behind two of the company's more exciting projects about the company's turn to diversity, and how long before the movies can catch up to the books.

Why do superheroes' race and gender matter?

Comics, like journalism, politics, entertainment, tech, and a whole bunch of other industries, has a serious diversity problem. "There’s this pervasive notion that white male is the, like, the basic model human and anything NOT white male is a variant edition," Kelly Sue DeConnick, the writer behind Captain Marvel, told me. She says comics creators and people working in the creative field have had to to fight for their characters who don't fit into that "basic model human" mold:

The further people get from Basic Model Human, the easier it is to tread on their rights. The more "other," the more alien. Your tribe versus my tribe. And for the people in margins — Junot Diaz has articulated it far better than I ever will. "If you want to make a human being into a monster," he says, "deny them, at the cultural level, any reflection of themselves."

DeConnick has been one of Marvel's most vocal writers when it comes to gender and race in its comic books. She played a big part in the revamping of Carol Danvers, who was originally known as Ms. Marvel and notable mostly for her skimpy outfit (a high-cut bodysuit with a ribbon for a belt). Since DeConnick has taken over, Danvers is now Captain Marvel and traded in her outfit for a more modest space pilot uniform.

"When we deny women and girls representation, we put them in ever smaller boxes," she wrote. "And when we limit their potential, we limit the potential of our culture as a whole. When we limit the contributions of half our society, we cut our potential in two."

There’s this pervasive notion that white male is the, like, the basic model human and anything NOT white male is a variant edition

She added, "If superheroes are meant to reflect the best of us, they should reflect the best of all of us, especially as that message can become confusing, and we can internalize the idea that heterosexual white males are the best of us."

How the Ultimates are being written

The All-New Ultimates might be the most diverse group of heroes in the Marvel universe. They exist in an alternate universe in Marvel, but it is actually the same universe that the Avengers movies borrow heavily from. The comic is its nascent stage— the first issue came out April.

Four of six heroes in the Ultimates are women, making men the minority as opposed to the movie version of the Avengers. And they're racially diverse too. Cloak is black, Miles Morales is a half-black half-latino Spiderman, Kitty Pryde is Jewish, and Spiderwoman a.k.a. Black Widow is actually a clone of Peter Parker.

Michel Fiffe, who writes the comic, explained that the heroes' diversity was something readers were asking for. "Aside from coming closer to representing the world we actually live in, it's important that these 'types'- all types - are represented and treated with the same weight and nuance as the status quo," Fiffe wrote to me over e-mail. "Otherwise, you're left with dangerous and inaccurate uniformity."

Fiffe explained to me that the Ultimates roster was decided before he took the job. "This roster was more or less formed before it was presented to me, and I felt I could naturally write from these characters' point of view," Fiffe explained.

But he wanted to make clear that he's writing stories that he's looking beyond his roster's gender and skin color, and is trying to make his characters, not their skin color or gender the only part of the story. "I have to meet those expectations head on and go further by telling interesting stories with the characters, not solely because of them, if that makes any sense," he wrote, adding:

I'm not telling 'female' or 'minority' stories. I'm telling stories with people of different backgrounds in them. So while I'm aware of who the characters are and what they represent, that's not quite at the forefront of my creative process.

I also asked Fiffe how much fun he was having. He said:

I can write Miles all day; he's one of the most likable personalities at Marvel. Navigating Black Widow's emotional state has been super interesting and rewarding. Bombshell, for my money, has the most compelling character arc ahead of her. I find her struggle to become a superhero - as a young girl and despite her underclass background - very layered and rich with possibilities.

The idea that men don't like female heroes is nonsense.

Skeptics often claim that this kind of idealism fails in the marketplace, that men won't watch female superheroes and white people won't watch black, Latino, or Asian ones. It's nonsense. That kind of thinking sells readers short and it goes against the tradition of comics books, which have always embraced oppressed minorities (Superman is, well, an undocumented immigrant).

But it's also just wrong. Here's a look at some of 2013 blockbuster movies and you'll notice two of 2013's biggest hits have female leads:

And Walt Hickey at FiveThirtyEight crunched the numbers and found that movies which pass the Bechdel test — which tests if movies feature a conversation between two women that's not about a man — perform better at the box office. People — men and women — are more than fine with female protagonists, as long as the story is there. Yet, there are still higher-ups at places like comic companies, executives at studios, and everywhere in between, who believe that these stories won't sell.

But fatalism can be self-fulfilling

It then becomes a chicken-or-the-egg dilemma. If a studio or comic company is reluctant to push and promote a movie or comic book ,and only invests a small amount, then the movie or comic can't reach a broad audience.

That has DeConnick a bit worried even though she is seemingly swarmed Comic-con after Comic-con by fans known as the Carol Corps (I've seen it first hand).

"It’s great, I’m pleased to see [the demand for a bigger variety of characters]. And I’m nervous," she told me. "If these books don’t do well out of the gate there are people in the industry who will take that as evidence that the conventional wisdom about the market stands. I think most folks at Marvel are smarter than that, but I’m a worrier by nature."