Results 1 to 10 of 34

Thread: New ideas for AI in games?

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #17
    Quote Originally Posted by Super Vegeta View Post
    I'd say that one of the problems in having an AI that reacts to a lot of factors is proritizing them and predicting all the exceptions. An AI that contains a clause "if you have less than X hp, flee, else attack" seems a good idea - but then, this is clearly absurd if the unit is totally surrounded - it will get killed anyway, and if it continued to attack, instead of trying to run away, it would have at least dealt some damage (maybe even killed someone).
    That's where that bit of randomness thrown in can really help in terms of ignoring triggers. The majority of people when it comes to fight or flight, pick flight -- to incorrectly quote Heraclitus (actual attribution unknown):

    "Out of every one-hundred men, ten shouldn't even be there, eighty are just targets, nine are the real fighters, and we are lucky to have them for they make the battle. Ah, but the one, one is a warrior, and he will bring the others back"

    Or the wisdom of Zathras:
    Ah, but for the one. No, not The One. Draal gave Zathras list of things not to say. This was one. No. Um, not good. Not supposed to mention One or The One. Oh. Uh, you never heard that. The One leads us. The One tells us to go, we go. We live for The One. We would die for The One.

    (you know it's bad when you can hear a character talking an uppercase The)

    Taking queues from NPC systems in RPG's can also help -- it's part of why CRPG's are popular. A 'fear' scale for example that's weighted/rolled against a characters willpower... a critical success being the equivalent to Patton's "Bravery is just fear holding on a second longer". Normal successes on willpower could add to a 'rage' scale that enhances the next roll... basically fail the roll, go into flee or 'cower' if cut off. Pass the roll, they hold. Hold until relieved... hold... until relieved..., critical success, they do a balls to the wall charge, no matter how stupid it is. Critical failure... well... Shell shock/Battle Fatigue/Operational Exhaustion/PTSD/Patton is gonna slap you silly back at the aid station. You do it on say a scale of... 2..12 via 2d6, so that critical success (12) and critical failure (2) are 1 in 36 apiece odds-wise, and you have a very simple system that turns a handful of behavioral states into a unpredictable but believable system.

    I think most anyone looking for inspiration on AI and player behaviors can learn a lot from a pen and paper RPG system, especially since a computer can make tracking all those numbers and 'rolling' for results simple -- often simpler than the convoluted systems I've seen in some folks code for handling what enemy units do. Studying statistics is also a great idea, as, well, take that quote above abnout 'out of every 100 men'... You could implement that quite easily; giving you 100 guys with the same basic stats, but varying behaviors.
    Last edited by deathshadow; 17-06-2012 at 11:13 PM.
    The accessibility of a website from time to time must be refreshed with the blood of designers and owners. It is its natural manure

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •