Wednesday, November 28, 2007

New location

I've moved my blog to a wordpress hosted location. You can find it here at:
Zeroth Code.

Monday, November 26, 2007

Why my university rules

I've never seen funny graffiti before (except on the internet), and I had to take a picture of this, and show how it compares to regular bathroom stall graffiti.


Yes, that is a mini-debate on Karl Marx. Complete with slashdot style moderation. In a bathroom stall.

Now, contrast that to the normal bathroom stall graffiti... which I cannot show you here. I'd probably get in trouble for posting hate speech. It was that bad.

Thursday, November 22, 2007

How to make great girl's games


The secret to making good girl's games is this: make good games.

Pretty simple. Thats the conclusion I've come to after talking with a few female gamers I know. I will paraphrase a bit of an interview I did with a close personal friend, whom goes by the pseudonym Ruby.

Ruby is an artist, in almost any medium. She wants to convey emotion, meaning, and depth in her work, and from what I've seen, she does a great job of it. She wants to date a J-Rocker, change the world, and look hot doing it.

She does work mainly in drawing, with paints, charcoals, sketches, on the computer. Soon, she'll learn how to do 3d models as well, and use her photoshop skills to great effect. She is also the lead artist of the game we're working on at the moment, and she'll likely end up being the lead writer as well.

She also plays video games, and had some interesting things to say about them. First off, "Girl's games suck." They're made easy, devoid of content and depth, and stereotype. Thats insulting to girls. They are just as smart, talented, and ambitious as men, and often, more so. So why would their game be simpler, easier, and stereotyped?

Yes, having little susie play Dress-up with a virtual barbie is very enjoyable. But as little susie gets not so little, we encounter a small issue: people don't think girls should play games.

According to Ruby, "There are no positive role models, and no encouragement from society." Theres nothing wrong with the games we have today, except for the culture surrounding them. Its as enjoyable for Ruby to snipe someone as it is for me to do so. So then why is it that we think girl's games need to be different?

Maybe it could be due to the over-lying themes in games focusing around masculine concepts, such as women with big boobs. That really does not help the cause any, and it just makes the men playing the games appear misogynistic and perverted.

Another culprit is games marketing. Name three games that used sex to sell the game, that actually had nothing to do with the game. I can: Everquest, Grand Theft Auto, and some random shooting game that had women in Vegas on it.

I'm sure there are a lot more examples out there, but Ruby's point has been made. She feels that the culture needs to change, and be more accepting. It needs to have a female role model, and Ruby is prepared to sacrifice to make that happen.

So, basically, what needs to be done is for game developers to realize how some of their choices are sexist and do not at all contribute to the self-esteem of women. And also, for their to be a push in the culture to be more welcoming. Look at all the articles about how women are treated with surprise and disdain in online games, because "women don't exist on the internet. And they most certainly don't play video games."(source)

So, if you have any comments, flames, threats, leave me a comment.

A few relevant resources:

Tuesday, November 20, 2007

Game story-telling

Storytelling is a difficult business, particularly in games. And good storytelling is the last great avenue of game design to be focused on, in this age ever-improving graphics and AI.

The reason why it has been largely ignored is mainly because it is hard. Faster processors, better algorithms will not ever improve stories in games. We are used to thinking primarily of one-way storytelling, of a storyteller, and an audience. In games, however, your audience is the story. Their actions are not controlled by a central storyteller. In a haunted house game, if you script the scene such that the background music swells ominously as you move closer to a locked door, what happens to the story if the player backs off?

In the old form of storytelling, whether the main character went through the door or not was up to the storyteller. Not so with games (unless you decide to force them through no matter what, but that itself is bad) .

It is easy to see why the old ways of telling stories do not work in games. However, there are some very good ways of establishing a story. Writers know that good storytelling needs three things: plot, characterization, and exposition. Lets look at each of these elements in the context of envisioning a new way of telling stories.

First up, is exposition. Some of the best ways are to show the player important facts, instead of telling them, as per the old adage, "It is better to show than to tell." Rather than have someone say everyone is scared, show their responses to the haunted house. When your character mentions the haunted house, subtle clues like facial expressions(if possible), movement away from the player, and a change in the tone of their dialog works well to convey this fact. A sample dialog:

Random NPC A: Ho there traveller! How goes this fine day?
Hero A: Can you tell me about that haunted house over there?
Random NPC A: Uhmm, hmm, yes, indeedy this day is fine, but I think it'll rain later. I think I shall go now.
Random NPC A walks off hurriedly.

If most of, or all of the dialog is at that level, of subtle personal clues, responses, it provides a better sense of what is being shown. In that dialog there, we saw friendliness, turn to avoidance of the issue, even running away.

Second, is characterization. If your game allows for dialog choices, then a good way to convey characterization is to colour the choices in the direction required. What that means is instead of offering a plain good or evil response, the responses offered should be more ambiguous. As an example:

Random NPC B(a girl): And here the heroes be! What brings you back here?
Hero A's choices:
  1. You, beautiful creature.
  2. Your sweet charms.
  3. Your bordello.
As you can see, the choices are all different, yet all convey a similar sense of who the character is. In this case, he's a lady's man. Maybe a good one. Or not. That would have to be shown by the responses. Or even, that would up to the player's choices.

However, this is still guiding the player, the old way of storytelling. It all depends on if you want the character to have character traits. For other such characters, providing a range is great. Recommended even! So, then for everyone else involved with the character, the above points about exposition work great for character development.

The last point is plot. And that is, quite simply the hardest. Some random blogger (IE, me) will not have a solution unless they're particularly brilliant. Which I am... except I don't have one yet. Some previous suggestions are storytelling by AI/heuristics, branching plots, or sandbox mode. By sandbox mode, I mean, GTA style gameplay.

And thats what I have today.

Sunday, November 18, 2007

NPC AI or are you talking to yourself?

And now for the promised RPG AI part II, a follow up of part I. The second arena of AI in an rpg, are the npcs, non-player characters.

That has been most of the focus for AI work in most rpg games. Consequently, the state of the art is much more advanced. The reasoning behind this, is to tell a story. To tell a good story. And people standing around repeating the same thing ruins the effect of the story. It takes the player out of the game, which is not a good thing. In fact, its exactly what the designer does not want. The player ends up noticing small things, tiny details, that did not bother them before. This serves to lower their enjoyment of the game. Again, a bad thing.

Good NPC AI is supposed to prevent this from happening, but I think there is something similar to the Uncanny Valley when it comes to NPC dialog. The closer to reality, the harder it is to believe, but if its sufficiently cartoon-like, its somehow easier to immerse yourself. (Of course, the opposite is also true, where the more ridiculously bad the dialog is, the harder it is to be immersed. And so you end up with kind of a bell curve, balanced between really unpredictable and random, to really really bad.)

One particularly effective example I have seen was used in the Golden Sun series. In that game, you could use psynergy, kind of like magic, and one of the moves was Telepathy. Using it next to an NPC, you could hear their thoughts. And by changing the thoughts based on any current events, it gave the npcs a hidden dimension, a personality.

The writing itself in those games was particularly brilliant, which also helps. However, in addition to good dialog writing there have been some interesting efforts to provide personality and unpredictability to npc AIs. The first is the "job system", where npcs go around do jobs, live their lives, go shopping, have needs and wants, and react accordingly when you disrupt them.

I see often on indie rpg games their breathless promise of a job system like that, where all the npcs have "real lives, real personalities!". What kind of benefit does this bring to the player? Well, for one, it does provide a kind of personality, as in, "Thats a blacksmith. He's in the blacksmith building for eight hours, then goes home, eats, and sleeps." Yep, thats a lot of personality.

Thats what happens often with job systems. You've just added a huge dimension of things to make and define for your designers, more than maps, items, doors, main plots, etc etc. And due to the sheer size, it becomes a copy+paste affair, where every blacksmith in the towns previous are identical to this town's blacksmith. Real personality, oh my!

Then there are the dialog trees. This works a bit better to tell the story, provide some personality, but there are still a few major issues. The first is simple, and horrific. Dialog trees end up almost being like those phone menus. Thats right, imagine those dialog trees as being read our loud, with your options each as numbers.

If you're like me, you shuddered at this image. Or rather sound recording or...okay, I've stretched the analogy too far. But back on point. The second issue is the representation. You get a bit of dialog, then have a bunch of dialog choices presented to you. Again, this commits the big story-teller no-no. You remove the player from the story, by showing them the different choices they could be, and maybe should be making. What if they think their character would do something different?

Also, lots of choices do not make people happy. When I'm faced with six or seven different dialog choices, I suddenly begin wondering, okay, okay, what if I pick the wrong one, and I don't hear more about the story like I'm supposed to? And I begin worrying. Then if you can start the dialog tree over again, you can try the other choices.

Oh wow, more personality! I can do all the dialog choices to find out all the information! Yeah, thats totally realistic. But the designers did decide to make that choice because of the sheer number of choices they gave the player, and it made the test group happier.

Therefore, to fix dialog trees, I have a few ideas. First is cut down the number of choices you give the player! Fewer choices means more happiness, and less "min-maxing". It also serves to tighten up your story-telling such that no npc should need more than three choices at any one time. If you find yourself needing more, then you need another npc.

By separating different parts of the plot to different npcs, you can focus more easily on developing them, or give it to someone else. It makes the writing more parallel. So, by making the user happier, and making it easier to make the game faster, this solution works pretty well.

The second idea is to not use real sentences, but a vague concept. After all, rpg stands for role-playing game. Make the player play a role. Make them pick a response that fits their character, and let the player know this! Have responses that fit that vague concept, like if the player expresses boredom, the npc becomes more insistent, maybe even angry based on the context.

And there we have it. More brilliance. Till next time.

Friday, November 16, 2007

Incomplete Minds aka politicians

My fellow blogger, The Recursion King, has made an interesting post over here, talking about an initial brainstorm for a model of AI.

I say initial, because its nowhere near complete. In fact, what he proposes has been done before.

Its not the data access and storage that makes consciousness, its what happens with that information that we do not yet understand. I'll use the example of a friend of mine, whom we'll call Ruby. She's an artist, a great one in fact. We were discussing how creativity works, and this is what she told me about artists: "We need to be able to picture the way shadows fall, how materials look under light, partial light, two lights. We need to be able to picture how an object looks from different angles, and how to draw that possibly very strange and unique shape. We need, in short, a 3d engine in our minds."

Our brains are capable of some great, fantastic stuff, intuition being the best example. The true difficulty in AI comes from giving it the capability to expand its perceptions, and make intuitive guesses.

Data mining as it stands today is probably the most advanced method of analyzing disparate data, and finding connections. But even that pales in comparison to what the human mind can deduce if properly trained. Semantic linking is a good start, however, as far as I can see, its only 10% of the solution.

What true AI would be able to do is take small amounts of information, and infer more information from that, based on internal reasoning. Ever had a hunch? That is your subconscious working on information you may not be aware of, and synthesizing it together into a whole for your conscious mind to act upon.

Take for an example, an AI that could solve murders. It takes humans years and years of experience to solve some of the toughest cases, and even then, they can be foiled by proper planning.

An AI that could solve murders would need to be able to decipher body language, understand the difference between lies and reality, infer missing pieces of information, like motives or methods. And even then, a well-executed murder may not ever be solved. However, with intuition, the human would have a guess as to which course to follow, and have an advantage over the AI.

But I'm not being fair, solving murders is a hard problem, despite how easy Sherlock Holmes may make it appear. How about an easier one? Say, Starcraft? Its quite possible in this day and age to make an AI that can beat any human player most of the time, without needing semantically linked memories. In fact, an AI that was not constrained by game developers would always beat human players in FPS games(due to perfect reaction speed, perfect aiming).

My point however, in all of this, is that semantically linked concepts and memories do not an AI make. The Recursion King has some great points, and I look forward to see what more he comes up with. But true AI is in the class of problems that some computer scientists think are Hard, or NP-Complete. Semantics will not solve it for us, unfortunately.

Thursday, November 15, 2007

Design, or is all that shiny stuff important?

Design is a very big thing, for a lot of people. But I find its often misunderstood, or incorrectly applied. To start with, design does not mean the same thing to Interior decorators as it does to architects. But most people see design as more of the interior decorator kind, than the architect kind.

Interior decorators do what I call appearance level design. And the benefits of appearance level design are not all that important. They make people feel better, more at home. Its a more impressive room/house/office.

That is not real design, in my view. Real design is figuring the best placement of bathrooms and appliances in the kitchen for maximum comfort and productivity. Real design is invisible, unseen, uncredited.

Here's a little task for you, to see what design really is about. Walk into any room of your house/apartment/mud hut/palace, and choose a common household item. I'll take a knife block as an example. Now, spend five or ten minutes thinking about how you could improve a knife block, to A) make it easier to use or B) add new functionality that is not just combining two opposite functions (like a clock on a VHF antenna).

If you can come up with an improvement that is not just glitz, that actually makes the item better than it was before, then the item does not have good design. If however, you can come up with nothing, and you realize changing anything would be for the worst, the item has good design.

My example the knife block, works really well for its purpose: hold knives, keep them sharp, and keep them organized. Can there be an improvement, that would make using it easier, faster, more efficient at its purpose? After ten minutes, all I could come up with was improving the knives themselves. The actual knife block works great. Its easy to pull out a knife, you know by the size of the hole how big the knife is, and its easy to put back in. Some knife blocks have built-in sharpeners, and thats about the only improvement that could be made.

The fact is, it takes experience and introspection to see design around us all the time. In our games, in TV shows, in our world all around us.

Another excellent example is in Final Fantasy III for the DS. The actual interface is a hodge-podge of button-clicking and touch-screen use, not very good. However, in the item list, for each category of items, there is an 8x8 icon representing it. This sits beside each item in your inventory, allowing you at a glance to see what it is. Axes for viking weapons, a glove icon for accessories, a spear icon for dragoons. Its simple, effective, nearly invisible. I caught myself using the icons, and thats when I actually noticed them. Someone consciously decided to make icons for each kind of item, and displayed them. Why? To make it easier to deal with a large inventory!

Good design is all around us. And good design takes conscious effort. Any time you find yourself making a snap decision on the placement of an item, or icon, or graphic interface, ask yourself why it goes there, and is there any way I can improve this?

As a personal example of good design, I was tasked to make it so that users of an application would know that the file has not been saved yet. My first response was a dialog on exit(or any other context change, more on that in future posts) if the file was not saved. Then I thought, okay, the user, she's likely not going to want to have to click through a dialog all the time, so how else can I do this? I added an icon to the upper bar, that appears when the file is modified. Its red, shaped like a stop sign, and has the word stop on it. Its placed right by the exit button.

Nowhere else in the application is red used, so when you go to load a new file, exit, you see the icon if you did not already. It disappears when you save, and it appears when you modify a file. No dialogs, no clicks, simple information conveyed quickly and easily. That is good design. It makes the workflow faster, the user quickly and easily learns what the icon means, and it helps them!

Next time, ask yourself why you are making the decision this way. If you can improve it, do so!