My Project
AIModuleNPC.h
1 #pragma once
2 #include "AIBase.h"
3 
4 namespace ParaEngine
5 {
6  /* forward declarition */
7  class CBipedObject;
8  class CFaceTrackingCtrler;
9  class CFollowCtrler;
10  class CMovieCtrler;
11  class CSequenceCtler;
12 
14  class CAIModuleNPC : public CAIBase
15  {
16  public:
17  virtual AIObjectType GetType(){return NPC;};
18 
19  CAIModuleNPC(CBipedObject* pBiped);
20  CAIModuleNPC(void);
21  virtual ~CAIModuleNPC(void);
22 
23  public:
26  void EnableFaceTracking(bool bFaceTracking);
27  bool IsFaceTrackingEnabled();
28  CFaceTrackingCtrler* GetFaceController();
29 
33  void FollowBiped(const std::string& sName);
34  bool IsFollowEnabled();
35  CFollowCtrler* GetFollowController();
36 
40  void EnableMovieControler(bool bEnable);
41  bool IsMovieControlerEnabled();
44 
48  void EnableSequenceControler(bool bEnable);
49  bool IsSequenceControlerEnabled();
52 
57  virtual void FrameMove(float fDeltaTime);
58  private:
59  CFaceTrackingCtrler* m_pFaceTrackingCtrler;
60  CFollowCtrler* m_pFollowCtrler;
61  CMovieCtrler* m_pMovieCtrler;
62  CSequenceCtler* m_pSequenceCtrler;
63  };
64 
65 }
NPC AI module: it is just an aggregation of AI controllers.
Definition: AIModuleNPC.h:14
different physics engine has different winding order.
Definition: EventBinding.h:32
base class never used directly
Definition: AIBase.h:15
CMovieCtrler * GetMovieController()
return the movie controller.
Definition: AIModuleNPC.cpp:97
a movie controller it will control the biped to follow a path defined in a movie file or record the b...
Definition: MovieCtrlers.h:12
void EnableSequenceControler(bool bEnable)
enable or disable a sequence controller.
Definition: AIModuleNPC.cpp:102
a facing tracking controller it will allow the biped to always face to a given target or another bipe...
Definition: FaceTrackingCtrler.h:12
base class for all AI objects
Definition: AIBase.h:9
CSequenceCtler * GetSequenceController()
return the sequence controller.
Definition: AIModuleNPC.cpp:114
virtual void FrameMove(float fDeltaTime)
a virtual function which is called every frame to process the controller.
Definition: AIModuleNPC.cpp:124
void EnableMovieControler(bool bEnable)
enable or disable a movie controller.
Definition: AIModuleNPC.cpp:79
A sequence controller is a biped controller which moves the biped according to some predefined sequen...
Definition: SequenceCtler.h:11
void EnableFaceTracking(bool bFaceTracking)
enable face tracking
Definition: AIModuleNPC.cpp:37
a follow controller it will follow a given target or another biped.
Definition: BipedController.h:70
void FollowBiped(const std::string &sName)
enable the follow controller to follow a named biped within its perceptive radius.
Definition: AIModuleNPC.cpp:56
It can be used to represent biped object(like human, re spawning monsters) in the scene without inher...
Definition: BipedObject.h:60
AIObjectType
Definition: AIBase.h:12