Tactics: Western Philosophers Vs. Musicians  0.12
A turn-based tactical game combining rules and gameplay elements inspired by Final Fantasy Tactics and the Mayfair Exponential Game System. Unlike most games of this type, motion is in full, grid-less 3D.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
IAIWrapperObject.h
Go to the documentation of this file.
1 // Copyright (C) 2006-2010 Dylan Blair
3 //
4 // email: dblair@alumni.cs.utexas.edu
5 //
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
10 //
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
15 //
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 
21 #ifndef IAI_WRAPPER_OBJECT_H
22 #define IAI_WRAPPER_OBJECT_H
23 
24 #include "IObject.h"
25 #include "../FSM_LIB/AIWrapper.h"
26 
27 namespace OpenSkyNet {
28  namespace Core {
30  class CORE_DLL AIWrapperObject : public Object, private AI::Wrapper {
31  public:
32  static inline AI::FSM** getGlobalFSMs() { return AI::g_fSMs; }
33 
34  virtual void init(AI::LOGIC_IDS logicId_, AI::FSM_IDS fSMId_, AI::State* state_) { AI::Wrapper::init(logicId_,fSMId_,state_); }
35  virtual void init(AI::LOGIC_IDS logicId_, AI::FSM_IDS fSMId_, AI::State* state_, AI::KB* kB_) { AI::Wrapper::init(logicId_,fSMId_,state_,kB_); }
36 
37  virtual bool performLogic(bool includeGlobalKB_=false) { return AI::Wrapper::performLogic(includeGlobalKB_); }
38 
39  virtual const AI::State* getCurrentState() const { return AI::Wrapper::getCurrentState(); }
40 
41  virtual AI::KB* getKB() { return AI::Wrapper::getKB(); }
42 
44  virtual void doAction() = 0;
45  };
46  }
47 }
48 
49 #endif //IAI_WRAPPER_OBJECT_H
virtual AI::KB * getKB()
Definition: IAIWrapperObject.h:41
virtual void init(AI::LOGIC_IDS logicId_, AI::FSM_IDS fSMId_, AI::State *state_)
Definition: IAIWrapperObject.h:34
FSM * g_fSMs[FSM_MAX]
Definition: AIManager.cpp:13
Definition: IAIWrapperObject.h:30
Definition: AIFSM.h:74
virtual void init(AI::LOGIC_IDS logicId_, AI::FSM_IDS fSMId_, AI::State *state_, AI::KB *kB_)
Definition: IAIWrapperObject.h:35
Definition: AIKB.h:33
virtual void init(LOGIC_IDS logicId_, FSM_IDS fSMId_, State *state_)
Definition: AIWrapper.cpp:30
virtual const State * getCurrentState() const
Definition: AIWrapper.h:90
Definition: AIWrapper.h:40
LOGIC_IDS
Definition: AIConsts.h:32
#define CORE_DLL
Definition: CCoreDLL.h:57
FSM_IDS
Definition: AIConsts.h:28
virtual bool performLogic(bool includeGlobalKB_=false)
returns true if state changed, false otherwise
Definition: IAIWrapperObject.h:37
Definition: IObject.h:36
Definition: AIFSM.h:42
virtual KB * getKB()
Definition: AIWrapper.h:149
static AI::FSM ** getGlobalFSMs()
Definition: IAIWrapperObject.h:32
virtual const AI::State * getCurrentState() const
Definition: IAIWrapperObject.h:39
virtual bool performLogic(bool includeGlobalKB_=false)
returns true if state changed, false otherwise
Definition: AIWrapper.cpp:55