Implementation of ITreeLoader
that gets its data from a lua script.
More...
#include <LUATreeLoader.h>
Public Member Functions | |
LUATreeLoader (const IAIFactory &aiFactory) | |
bool | init (const std::string &luaString) |
this will initialize the loader once with all the defined behaviours from the given lua string. | |
Public Member Functions inherited from ai::ITreeLoader | |
ITreeLoader (const IAIFactory &aiFactory) | |
void | shutdown () |
const IAIFactory & | getAIFactory () const |
void | getTrees (std::vector< std::string > &trees) const |
Fill the given vector with the loaded behaviour tree names. | |
bool | addTree (const std::string &name, const TreeNodePtr &root) |
Register a new TreeNode as behaviour tree with the specified name . More... | |
TreeNodePtr | load (const std::string &name) |
Loads on particular behaviour tree. | |
void | setError (const char *msg,...) __attribute__((format(printf |
void std::string | getError () const |
Gives access to the last error state of the ITreeLoader . | |
Additional Inherited Members | |
Protected Types inherited from ai::ITreeLoader | |
typedef std::map< std::string, TreeNodePtr > | TreeMap |
Protected Member Functions inherited from ai::ITreeLoader | |
void | resetError () |
Protected Attributes inherited from ai::ITreeLoader | |
const IAIFactory & | _aiFactory |
TreeMap | _treeMap |
ReadWriteLock | _lock = {"treeloader"} |
Implementation of ITreeLoader
that gets its data from a lua script.