15 #ifndef PIE_NOON_CONTROLLER_H_
16 #define PIE_NOON_CONTROLLER_H_
24 static const CharacterId kNoCharacter = -1;
38 explicit Controller(ControllerType controller_type = kTypeUndefined)
42 character_id_(kNoCharacter),
43 controller_type_(controller_type) {}
48 virtual void AdvanceFrame(WorldTime delta_time) = 0;
50 ControllerType controller_type()
const {
return controller_type_; }
53 uint32_t is_down()
const {
return is_down_; }
54 uint32_t went_down()
const {
return went_down_; }
55 uint32_t went_up()
const {
return went_up_; }
58 void SetLogicalInputs(uint32_t bitmap,
bool set);
60 CharacterId character_id()
const {
return character_id_; }
61 void set_character_id(CharacterId new_id) { character_id_ = new_id; }
63 CharacterId target_id()
const {
return target_id_; }
64 void set_target_id(CharacterId new_id) { target_id_ = new_id; }
67 void ClearAllLogicalInputs();
74 CharacterId character_id_;
75 CharacterId target_id_;
76 ControllerType controller_type_;
82 #endif // PIE_NOON_CONTROLLER_H_
Definition: controller.h:26