Game Development Reference
In-Depth Information
The RetreatState will try to get away from a target for a set amount of time. After
this, it will return to PatrolState , forgetting any fears it might previously have had.
All of our states will extend an abstract class called AIState , which we will also create
in this recipe. This class in turn extends AbstractControl .
Worth noting is that all AI decision making and actions are handled from within the states.
The states only relies on the AI control class to supply it with sensing updates (although
this could also be handled by the states themselves).
Search WWH ::




Custom Search