summaryrefslogtreecommitdiff
path: root/src/velocity.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/velocity.h')
-rw-r--r--src/velocity.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/velocity.h b/src/velocity.h
new file mode 100644
index 0000000..3c48949
--- /dev/null
+++ b/src/velocity.h
@@ -0,0 +1,21 @@
+#ifndef VELOCITY_H
+#define VELOCITY_H
+
+#include "acceleration.h"
+
+class Velocity {
+ private:
+ float dx;
+ float dy;
+ public:
+ Velocity();
+ Velocity(const float dx, const float dy);
+ void setDx(const float dx);
+ void setDy(const float dy);
+ float getDx();
+ float getDy();
+ void addVelocity(Velocity &vel);
+ void update(Acceleration &acc);
+};
+
+#endif