fysxasteroids/asteroids/Controller.h

37 lines
844 B
C
Raw Permalink Normal View History

2010-04-05 23:38:59 +02:00
#ifndef _CONTROLLER_H
#define _CONTROLLER_H
#include "Engine.h"
#include "ControllerBase.h"
namespace asteroids {
/** \brief All possible controller states for an Entity
*
* These are used by the controller to update the current state of an Entity
* (e.g. EntityPhysicState).
*/
enum EntityControllerKeyState {
EntityKeyStateForward = 0,
EntityKeyStateTurnLeft,
EntityKeyStateTurnRight,
EntityKeyStateLast
};
class Controller : public Engine::ControllerBase {
public:
Controller () {};
void ResetPlayerEntity ();
2011-01-02 18:25:20 +01:00
void ResetLevel();
2010-04-05 23:38:59 +02:00
protected:
/** \brief Set up basic keybindings */
virtual int OnInit (int argc, char* argv[]);
/** \brief Registers the commands of the cnotroller */
virtual void OnRegisterCommands ();
virtual bool OnReceiveEvent (const Engine::EventBasePtr &event);
2010-04-05 23:38:59 +02:00
};
}
#endif // _CONTROLLER_H