The work of Scots author Christopher Brookmyre has inspired a new video game with a female lead character who the novelist hopes will help redress the gender imbalance in first-person shooter games.
In video game terminology a first-person shooter (FPS) is one in which the player experiences the action through the eyes of the protagonist.
Acclaimed Glaswegian novelist Christopher Brookmyre says there are as few as six female leads in existing FPS games, with Mirror's Edge being one of the rare examples.
He says the genre is dominated by male characters, which he describes as typically being "xenophobic, militaristic, macho and with simplistic ideologies".
"The average FPS protagonist is a testosterone-addled sociopath with all the endearing charm of a cornered honey badger," he says.
So Brookmyre has worked with Brighton-based games developer RedBedlam, to develop a game which is due to be released this summer.
Bedlam is based on the Brookmyre's 2013 novel of the same name.
Its lead character is a programmer called Heather Quinn.
Brookmyre says he hopes she will help in "redressing a longstanding gender imbalance" in the FPS genre.
Bedlam the book marked Brookmyre's second foray into science-fiction and his latest work to feature gaming, something the novelist has been interested in since playing Jet Set Willy on a ZX Spectrum as a boy in the 1980s.
The novel emerged from talks with the games developer RedBedlam who were aware of Brookmyre's writing and wondered if he fancied turning his hand to writing the story for an FPS.
Brookmyre says: "The team at Redbedlam had read my book A Big Boy Did It And Ran Away, which is a love poem to first-person shooters, and Pandaemonium, my first science-fiction and FPS-inspired story.
"They approached me about writing a game because they thought I was a familiar with the rules and tropes of video games," the author says.
There is one major difference between the book and the game.
In the book, the lead character is Ross Baker, an overworked and underpaid scientist developing medical technology for corporate giant Neurosphere.
He volunteers to test new brain scanning technology to escape the drudge of his office work and finds himself trapped in Starfire, a violent sci-fi game he played when he was a teenager.
Baker also discovers that he is not fighting with the good guy space marines, but as one of the game's "cannon fodder" baddie cyborgs.
Brookmyre says: "Normally in these kind of scenarios the lead character is the hero and the destiny.
"I thought it would be funny if he found himself to be a nobody, even better one of those who faces being gunned down in the early, training level of the game."
In the new FPS, Brookmyre says this alternative scenario will force players to explore the game's world and find a role in it.
Brookmyre says that, with hindsight, he should have made the novel's lead character a woman.
The lead character in the FPS, Heather Quinn is a colleague of Ross Baker.
She is a programmer at Neurosphere and a keen gamer who calls herself Athena in the virtual worlds of the games she plays.
The writer says women are often poorly portrayed in games.
He says they appear as "rescue fodder", in not much clothing or they have been 'fridged', a term coined following a storyline in a Green Lantern comic book where the villain leaves the corpse of the hero's girlfriend in a fridge for him to find.
"The purpose of a woman being fridged is to get the hero worked up into a rage and for him then to go off and kill more people," says Brookmyre.
He adds: "When we were playing around a wee bit with the character of Athena we thought she would be appalled to find herself in a cyborg, but then thinking that it was preferable to the usual horrendously sexist female gaming character look of hideous push-up bra and loin cloth."
By contrast to the usual stereotypes, the poster art for Bedlam, shows Athena dressed as Tom Baker's fourth Doctor Who to reinforce her "geek credentials".
RedBedlam's co-founder and marketing director, Nick Witcher said: "We think Athena really is a very unique character for a shooter.
"Unlike previous female protagonists she's just a normal geeky girl and a gamer. I have friends just like her.
"It also gives us the chance to delve even deeper into Christopher Brookmyre's oeuvre, which invariably features such female characters prominently."
Brookmyre, who is in Inverness this week to talk about the book and game at the goNorth creative industries festival, says there are hopes for further Bedlam books and games.
However, he says he is not finding the time to play FPSs as much as he used to.
"Now, I'm more likely to stand over the shoulder of my son Jack watching him play," he says.
"He was also involved in some ideas for the game and dialogue for some of the characters. He has a far better idea of how young people speak today than I do."
Brookmyre adds: "We used to play the game Quake III together and I would have to handicap myself to give him a chance. Now, it is the other way around."