Fuzzy Logic
Fuzzy logic algorithm is where the state membership has a float range and not made up of 0 and 1's, what I mean by this is the state is a number between the 0 and 1, so for example 0.5. You're probably thinking, what does this mean? Well to make it simpler, in a shooting game the AI as well as the player character will have a health bar, below is an example of Fuzzy logic...
From my example you can see the life of an AI character in a game, now "No Health 0%" is obviously when the AI character is dead. "Full Health 100%" is when the AI is at full health and had no damage to it, but that's not the segment we are interested in Fuzzy logic. What we are interested in is the AI's health bar at 67%, this is the in-between of 0 and 1.
Now the next part of Fuzzy logic is the actual reaction of the AI in the time of even the health bar drops below a certain point, Now the developer could then implement code so when the health bar drops below a certain point the AI character will flea the scene or attack. The AI use decision tree's (4.4 Decision Tree) to make it's next move, an example of this is shown below...
"enabling an AI opponent to assess threats and for classification, for example by ranking players and NPCs in terms of health or power using fuzzy variables"(10)
Pirovano makes the exact point that using Fuzzy logic, a game can separate a classification of AI. Ranking how good one AI is to another, in a game the boss of a level will be harder to defeat that a ground soldier in the game, this is also used to acknowledge the longer heath that the boss AI will have. It's a perfect example of Fuzzy logic and displays what the algorithm is all about.
No comments:
Post a Comment