1 #ifndef SCRIPTABLE_CONTROLLER_H 2 #define SCRIPTABLE_CONTROLLER_H 122 std::list<std::unique_ptr<ScriptableControllerAPI> >
apis_;
139 #endif // SCRIPTABLE_CONTROLLER_H Everything in Orxonox that has a health attribute is a Pawn.
Definition: Pawn.h:56
Runs a scripts on a per-level basis and handles the connection to orxonox.
Definition: scriptable_controller.h:31
void source(const std::string &filename)
Reads the content of a file and executes the commands in it line by line.
Definition: ConsoleCommandCompilation.cc:167
void pawnKilled(Pawn *pawn)
Called when a Pawn is killed.
Definition: scriptable_controller.cc:81
void setPlayer(PlayerInfo *player)
Set the player object of the current game.
Definition: scriptable_controller.cc:60
void printLuaError(lua_State *lua)
Prints a human readable error message if a lua error occurs.
Definition: scriptable_controller.cc:150
::std::string string
Definition: gtest-port.h:756
MobileEntity * getMobileEntityByID(std::string id) const
Convert an ID to a MobileEntity pointer.
Definition: scriptable_controller.cc:124
std::list< std::unique_ptr< ScriptableControllerAPI > > apis_
Definition: scriptable_controller.h:122
std::map< std::string, MobileEntity * > mobileEntities_
Definition: scriptable_controller.h:125
std::map< std::string, Pawn * > pawns_
Definition: scriptable_controller.h:126
WorldEntity * getWorldEntityByID(std::string id) const
Convert an ID to a WorldEntity pointer.
Definition: scriptable_controller.cc:115
void registerWorldEntity(std::string id, WorldEntity *entity)
Register a WorldEntity to the ScriptableController.
Definition: scriptable_controller.cc:65
The WorldEntity represents everything that can be put in a Scene at a certain location.
Definition: WorldEntity.h:72
int runScript(const std::string &file_path)
Run a lua script.
Definition: scriptable_controller.cc:12
std::map< std::string, ControllableEntity * > controllabelEntities_
Definition: scriptable_controller.h:128
The MobileEntity is a derived class from orxonox::WorldEntity and orxonox::Tickable.
Definition: MobileEntity.h:53
Declaration of the Timer class, used to call functions after a given time-interval.
Die Wagnis Klasse hat die folgenden Aufgaben:
Definition: ApplicationPaths.cc:66
void registerPawn(std::string id, Pawn *pawn)
Register a Pawn to the ScriptableController.
Definition: scriptable_controller.cc:75
Pawn * getPawnByID(std::string id) const
Convert an ID to a Pawt pointer.
Definition: scriptable_controller.cc:133
Defines several very important macros used to register objects, register classes, and to work with id...
void pawnHit(Pawn *target, Pawn *source, double new_health, double new_shield)
Called when a Pawn is hit.
Definition: scriptable_controller.cc:99
void registerMobileEntity(std::string id, MobileEntity *entity)
Register a MobileEntity to the ScriptableController.
Definition: scriptable_controller.cc:70
std::map< Pawn *, std::string > pawnsReverse_
Definition: scriptable_controller.h:127
The Scripts' code is executed through lua.
Definition: PlayerInfo.h:39
PlayerInfo * player_
Definition: scriptable_controller.h:123
std::map< std::string, WorldEntity * > worldEntities_
Definition: scriptable_controller.h:124