The Grand Theft Auto series redefined gaming, pioneering the go-anywhere, do-anything "sandbox" genre and touching off worldwide debates about sex and violence in videogames. Wired contributor David Kushner tells the riveting history of the series in a new book, available this week from Wiley, titled Jacked: The Outlaw Story of Grand Theft Auto.

Having already pushed the envelope with violent content in previous Grand Theft Auto games, Rockstar wanted to bump up the sex in its anticipated San Andreas. But the outlaw developer had a problem: The videogame ratings boards around the world all had vastly different standards for what was and was not acceptable. Including content that went beyond each country's line in the sand meant that the game could be banned by the government or, in the case of the United States, legal to sell but not carried by major retailers.

This excerpt from Jacked details how Rockstar had to remove much of its content – but it didn't remove it well enough, leading to the so-called "Hot Coffee" scandal.

Sex in San Andreas ——————

“We have to have retail tell us what games to make?,” Sam Houser wrote in an e-mail. “That’s nonsense. Freedom of speech? Isn’t that how the country is justifying the invasion of Iraq and other places? We must expose such flagrant hypocrisy. Boundaries need to be stretched. This is key. Ultimately it looks nothing like the real world, so if movies do it, which are obviously more realistic, it just doesn’t make sense if we can’t.”

Terry Donovan spent weeks researching Sam’s requests, going over the sex scenes in the game, and scouring the rules around the world for just what could and couldn’t make it in. Sam tried to reassure the developers in Scotland. “We’re definitely going to have to do a separate version for Wal-Mart,” he wrote in an e-mail to Rockstar North. “Therefore whatever content we do agree on needs to be easily removable.... We’ll do whatever we can to keep this stuff in. It’s going to be tough but we love a good battle.”

“Unfortunately, here is the situation,” Donovan wrote in an e-mail to Sam on Aug. 16, 2004, and proceeded to list the necessary changes.

“Hooker in car blow job – we need to show much less of the critical mouth to penis area.

“Hooker Stand Up Blow Job – this needs to be removed or implied.

“Sex with girlfriend – essentially this is all beyond the bounds of M and 18 ratings, and needs to be removed or implied.

“Sex shop workers need to have slightly more nipple coverage particularly for the States.

“Key to her heart spanking date scene needs to be removed, as it constitutes sexualized violence which is a huge problem.

“Blow job in back room of dealer’s house is cool however.

“I wish we could include all this incredible stuff, but it just isn’t feasible to get it out there at the moment. As discussed we are working on a couple different scenarios for a release of a version with this content included.”

Sam clicked the attachment – four excruciating pages of explication, country by country, over just what kind of sexual activity could and could not be shown, given their target rating. The list was beautifully absurd, hilarious and horrific, and inescapably real.

Spain and Italy were fine with nudity (including erections) and “lax,” as Donovan put it, with regard to sexualized violence. France was OK with male nudity (no erections) and female nudity (though, as Donovan explained, “as long as it can be considered ‘erotic’ and not pornographic”). While Australia didn’t permit male nudity, female breasts and buttocks were fine. Spanking was pretty much a no-no, with the exception of Spain and Italy, where it was okay if it was part of the story. Every country was cool with jacking off, as long as no penis appeared. No mentions, though, of female masturbation. Implied oral sex, no problem anywhere.

Of all of the territories, the United States was by far most restrictive – any male nudity had to be covered in shadows, and although female breasts could be shown, their genitalia were off limits, and nipples had to be covered with pasties. And an inexplicit scene of CJ having sex with his girlfriend? Though acceptable across the world, it would surely garner the deathly Adults Only rating in the U.S. “The sex scenes that are in San Andreas currently are going to be considered too graphic,” Donovan wrote. They had to go.

“This is WAY, WAY more than I expected,” Sam wrote to Donovan, pounding his keys. “Not only is it insane to edit comedy like this – look at movies and everything else – to do so is going to be a lot of work and will screw with things (eg: changing the spanking mission, which could not be more harmless/silly).”

The bureaucrats and the shopkeepers had won. Rockstar would cut back the sex from San Andreas. Some moderate content could remain, such as the two-ended purple dildo hidden in a police bathroom as a weapon, but little more.

With the game’s deadline just weeks away, the sex scenes had to be removed, and fast. Sometimes instead of deleting code, which can be problematic, game developers essentially hide the content from players so that it won’t be seen. It’s a common and acceptable process known as “wrapping,” sort of like wrapping an unwanted package in camouflage and burying it in the woods. There was nothing sneaky about it.

So one day at Rockstar, a programmer tapped a series of buttons on a keyboard and took care of the job. The San Andreas sex scene was wrapped and tucked away into the forest of code. Because the industry didn’t require game developers to disclose wrapped content, Rockstar had no reason to mention the sex scene when it submitted the new GTA for its rating.