--- /dev/null
+#ifndef ORBI_CONTROLLER_H_
+#define ORBI_CONTROLLER_H_
+
+namespace orbi {
+
+class Entity;
+
+class Controller {
+
+public:
+ explicit Controller(Entity * = nullptr);
+
+ void Control(Entity &ent) { e = &ent; }
+ void Relinquish() { e = nullptr; }
+
+ bool Controlling() const { return e; }
+ const Entity &Controlled() const { return *e; }
+
+ void Update(float delta);
+
+public:
+ void MoveLeft();
+ void StopLeft();
+ void MoveRight();
+ void StopRight();
+
+ void StartJump();
+ void StopJump();
+
+private:
+ Entity *e;
+
+ int moving;
+ float moveAcc;
+ float moveTerm;
+
+ bool jumping;
+ float jumpVel;
+
+};
+
+}
+
+#endif