]> git.localhorst.tv Git - blank.git/blob - src/ui/PlayerController.hpp
8d9e5a37247c3ca0622b70dd11cdb5cc0218a4ad
[blank.git] / src / ui / PlayerController.hpp
1 #ifndef BLANK_UI_PLAYERCONTROLLER_HPP_
2 #define BLANK_UI_PLAYERCONTROLLER_HPP_
3
4 #include <glm/glm.hpp>
5
6
7 namespace blank {
8
9 struct PlayerController {
10
11         /// set desired direction of movement
12         /// the magnitude (clamped to [0..1]) can be used to attenuate target velocity
13         virtual void SetMovement(const glm::vec3 &) = 0;
14         /// turn the controlled entity's head by given pitch and yaw deltas
15         virtual void TurnHead(float pitch, float yaw) = 0;
16
17         /// start doing primary action
18         /// what exactly this means depends on the active item
19         virtual void StartPrimaryAction() = 0;
20         /// stop doing primary action
21         virtual void StopPrimaryAction() = 0;
22         // etc
23         virtual void StartSecondaryAction() = 0;
24         virtual void StopSecondaryAction() = 0;
25         virtual void StartTertiaryAction() = 0;
26         virtual void StopTertiaryAction() = 0;
27
28         /// set the item at given inventory slot as active
29         virtual void SelectInventory(int) = 0;
30
31 };
32
33 }
34
35 #endif