Sunday, March 3, 2013

Game AI Behavior

I'm just going to list out things I think will improve game AI from a behavior standpoint.  I'm going to ignore all the nitty gritty details.  For example I don't think it matters how your AI decides what to do.  I think some  mechanisms are more powerful than others and will help empower you as the developer to make the AI better but ultimately it matters what the AI decides to do and not how it makes that decision. 

AI's should always be purposeful.
  • Don't use random 
  • Don't use wander
  • Don't use idle
Start your model as close to reality as possible
  • If you want an airplane to look like an airplane it helps to start with the basic mechanics of airplane flight. 
Don't model bullshit
  • Bullshit doesn't scale.  Trying to tune a bunch of AI's to look natural by giving them some half assed model of human intentions is never going to work.  You are far better off just telling them to do what you want to achieve your desired effect rather than tuning some goofy model. 
Respond to everything
  • Car wrecks, gun shots, staring, you name it and your AI should respond.
Foreshadow everthing
  • Everything the AI does should be signaled. The AI is leaving cover to get a better vantage point. Don't just fucking do it. Signal the player that your doing it and why. It should be clear at all times why an AI is doing something
Execution is king
  • Doesn't matter how smart your decision maker is if the AI looks like shit doing it then don't bother
Flicker is the devil
  • Once your AI decides to do something it's better to continue doing it long after whatever reasonable reason for doing it has passed then it is to stop doing it then decide to start again in a short period of time.
Spatial hacks are good.
  • Allow the world to be annotated to tune specific behavior
Global hacks are bad
  • Don't let the AI's be universally tuned
Don't randomly select behaviors
  • Don't 50% of the time attack and 50% retreat.  See the first point.  Be purposeful!
Ok I'm out of pearls of wisdom/bs on AI behavior design.  As more come to me I might come back and update this post or repost it etc.  Not sure what works better from a blog perspective. 

No comments:

Post a Comment