I'm developing an AI "mind" engine, which allows NPCs (non playable characters) to think and make decisions, based on their view on the game world, and their own inner states (in the future I may add the NPCs' memory - long or short term - if necessary).
Given those inputs, they can give a list of possible actions, with possibilities, for example with a rabbit:
- World view: a wolf (enemy) is 100m away, the carrot is 40m away.
- Inner state: it is hungry, it has big courage and can take risks.
So the expected type of output will be the actions that the rabbit can do:
- Runs away: 40%
- Bites one bite of carrot then run: 80%
- Keep eating and don't give a damn about the wolf: 20%
Based on the desired actions, it will give its decision: which action to take. But that's future works, now I'm concentrating on how to produce that list of actions.
I read the chapter 5, book Artificial Intelligence for Games, Ian Millington and I found the Rete algorithm, which allows match a rule sets to a given database - in my case, the database will be the combination of the NPC's world view and inner state. It seems suit well with my needs, but after making a search, I can see very few (actually, zero) projects that use this algorithm.
Is it so heavy and slow for computer games? Or does it have any more drawbacks that can't be widely used?